The alpha version of Tsine – High School Timetabling systém consists of two parts – an algorithm, and a GUI.
check the system requirements
unpack the archive with the application into a special directory (eg. /home/Tsine)
run tsineInstallDb.py script (in the application directory) with arguments matching your database configuration (see below)
no matter whether you belive it or not, that's all – you can now run Tsine via tsineGui.py script from the application directory!
Unix-like operating system (may work on Windows as well, not tested yet)
Python >= 2.3 (not tested with previous versions, should work as well)
GTK+ >= 2.6 (not tested with previous versions, should work on GTK+ 2.4.x)
PyGTK >= 2.0
PostgreSQL Python API – part of the PostgreSQL installation
Before running Tsine (either computation or GUI), you need to create tables in the database. This is done by tsineInstallDb.py script, with following options:
-h/--host – hostname for your DB server (default: localhost)
-u/--user – DB username (default: luigi)
-p/--passwd – DB password (default: none)
-d/--db – database name (default: tsine)
-s/--dsn – DSN name (default: localhost)
--table-prefix – prefix used for tables (default: none)
Example run of the installation script – go to the application directory:
./tsineInstallDb.py –host localhost –user luigi –db tsine
After that, Tsine is ready for use.
The algoritm uses simple backtracking, with an evauluation function which count number of cillisions in the timetable, and thus selects the best timetable. It always produces one (the first) of the timetables with the best score.
Users are supposed to execute the algorithm only within GUI (see below), however, it's possible to execute it independently as well, using following notation:
./tsineBruteForce.py [options]
with these options available:
-h/--host – hostname for your DB server (default: localhost)
-u/--user – DB username (default: luigi)
-p/--passwd – DB password (default: none)
-d/--db – database name (default: tsine)
-s/--dsn – DSN name (default: localhost)
--table-prefix – prefix used for tables (default: none)
--config-file – configuration file (unused in alpha version)
The GUI allows user to interact with the computations in an easier way – it allows to display current best result, set constraints on timetables (move the items to fixed positions, as well as release them to free scheduling), and manage computations.
To run GUI, you need to install Tsine database tables first (see above, Installation instructions). The GUI itself has no command-line parameters, you can run it according to this example:
./tsineGui.py
To start the computation, configure database connection information via Main menu->Edit->Preferences menu option.
The properties you have to set are the following:
database hostname
database username
database password
database name
data file path (path to the XML file with school data)
optional table name prefix (if you want to run multiple tsine instances within single database)

After setting database properties, it's time to run computation itself. Multiple computations may run at the same time, even (in future versions) using different algorithms. To run a new computation, go to the Computations („Výpočty“ in Czech) tab and press „New computation“ button. This shows you a list of available algorithms (computation types). To start a computation, press „Execute“.

To view results for a particular computation, select the Results („Výsledky“) tab, and the computation ID in the drop-down list. The information about current best result for selected computation will be displayed.
To schedule timetable item on a fixed position in the timetable (on fixed room, day and hour), select the item in the results list, and press the Move („Přesunout“) button on the Results toolbar.

A dialog window shall pop up, so that you'll be able to select fixed room, day and hour for specified item. You can press „Save“ („Ulozit“) to schedule the item, or „Delete“ („Vymazat“) to unschedule the item from a fixed place you set earlier. You can set the constraint on either a single computation (the one selected in the drop-down menu in the „Results“ tab) or on all computations (eitheir currently running or those to be run in the future).
After making any changes to the constraints, you can press „Reload“ to see, how the changes were reflected by the computation.
To view school configuration (eg. students, teachers available etc.), select the „Data“ tab, which allows you to view lists of the items in the configuration.
Results of a timetable can be saved in a simple XML file. To save the result of the computation selected in the „Results“ tab, press „Save“ button, either on the „Results“ tab, or in the main menu.