|
Project Information
Featured
Downloads
|
SummaryThis project is about generating instances for Udine Timetabling problems. The code is part of the paper: Lopes and Smith-Miles: Pitfalls in Instance Generation for Udine Timetabling, LION4 2010 bibtex: @conference{LopesMilesLion42010,
author = {Leo Lopes and Kate Smith-Miles}
title = {Pitfalls in Instance Generation for Udine Timetabling},
booktitle = {Proceedings of the LION4 Conference},
year = {2010},
}and is a revision of the generator in Burke, Mareček, Parkes, and Rudová, A supernodal formulation of vertex colouring with applications in course timetabling, Technical Report {NOTTCS-TR-2007-10}, The University of Nottingham, Nottingham, UK. bibtex: @article{Marecek2007TR,
author = {Edmund K. Burke and Jakub Mare{\v c}ek and Andrew J. Parkes and Hana Rudov{\' a}},
title = {A Supernodal Formulation of Vertex Colouring with Applications in Course Timetabling},
journal = {Ann. Oper. Res.},
year = {To appear},
url = {http://arxiv.org/abs/0710.3603}
}Installation and UseYou will need to download and install NetworkX. Once NetworkX is installed, uncompress the generator file, udineGenUtils2.py and the file combinedITC07graphs.pickle onto a directory, change to that directory, and run python. Once in python, the generator works exactly like the original one. From the command line you can also run the code directly, without entering the python interpreter, by passing the number of events and the occupancy as parameters. The output file will be printed on the screen. Make sure python is on your path. Here is an illustration (the ellipsis is added by me): C:\tmp> python udineGenUtils2.py 400 80 Name: Random_400Events_Occupancy80 Courses: 137 Rooms: 20 Days: 5 Periods_per_day: 5 Curricula: 157 Constraints: 464 COURSES: Course001 t00 2 1 295 .... Course137 2 3 Course137 2 4 END. If you have a bash shell (unix command prompt), you can copy the code below (also available at the bottom of udineGenUtils2.py) and paste it into your terminal to run a unit test of the generator on your machine. I will put two versions here: The code below will create about 30MB of files on your machine. It is the unit test used before every release. for events in 20 40 50 70 100 125 150 200 400; do
for occupancy in 30 50 70 80 90; do
for i in `seq 1 100`; do
echo -n ${events} ${occupancy} ${i}", ";
python udineGenUtils2.py ${events} ${occupancy} > ${events}Events${occupancy}PctOccupancy-${i}.ctt;
done
done
doneHere is a shorter test set that runs faster and doesn't write any files out unless there is an error: for events in 20 70 125 400; do
for occupancy in 30 70 90; do
for i in `seq 1 5`; do
echo -n ${events} ${occupancy} ${i}", ";
python udineGenUtils2.py ${events} ${occupancy} > /dev/null;
done
done
done
|