suggestions for multiple weeks timetable (not the 120 days custom version)

Started by GEA_user, June 21, 2018, 01:24:16 PM

Previous topic - Next topic

0 Members and 1 Guest are viewing this topic.

GEA_user

Hi,
I'm a french new user (with poor english, sorry) of FET.
I propose a return of experience and some suggestions.

My context :
an institute of a french university;
2 years of students with 6 groups and 2 subgroups each (24 subgroups in total);
6 hours per day and 5 days per week;
2 kinds of teachers : 20 "normal" teachers of the university and 40 "external" teachers  with few hours (between 1 and 6 hours per day);
16 differents weeks of  activities, the 60 subjects in total are not active in same time.
For example the subject S1 for the group 1.A with the teacher T1 will be week 1 to week 5, the subject S2 for the group 1A with the teacher T2 will be week 3 to 11,  and so on...
The difficulty appears with the teachers who need the same position an a week for the same activity and this for all the weeks of the activity.


My way to realise timetables :
My first idea was to use the 120 days per week custom version but I had two problems :
- I read the help and understood the idea of subactivity but I didn't find a simply way to import my repartition of activity/subactivity for each one.
- The not available time for teachers is very fastidious to translate in this version. Because a real available time, for example day1 hour4 must be duplicate by 16 : day1 of week1 hour4, day1 of week2 hour4, ... day1 of week16 hour4.

My second idea appears more efficient :
I used the normal version of FET an generate a « special week »  with a great part of all the activities for all the weeks.
It permits to place all the activities for all the teachers who need a « locked » timetable for each week.
This « special week » is clearly not optimal (and could be impossible to generate if there were too much activities) but in my situation it's possible, according to not optimized solution for teachers and students.
All activities had tags for each week they appears.

After generating that « special week », I save the file and the timetable and create each real week :
I open the « special week » file, save as week number xxx file, began by inactivating all activities and then activating the activities of the week number xxx  and finally optimmizing step by step the constraints of this week number xxx.
And this for all the 16 weeks.


My suggestions/wishs :

The most difficults :
- can have a real multi-week version of FET. For my context the 120 days per week had, at less, the 2 problems I explain in « my first idea ».
Probably less difficult :
- I'm very interested by an import functionality with subactivities and more overall an import functionnality with more options.
- In my use of FET I have a lot of active/inactive activities to change, I would be more easy if the possibility of check box for « active » exist in the activities dialog windows.
And finally probably the most interessing :
the possibility of using tags in the constraints, for example to activate/inactivate lock, permanents lock, available time for teachers /students, and so on...

I hope my text is comprehensive.
Thancks you for reading.

Liviu Lalescu

Hello,

Welcome to the forum!

I have read your post. I think we should adopt the use of 'the max-150-days-per-week' variant. Your tricks to use the official version are not exploiting the full capacity of FET.

About your suggestions (in exactly your reversed order :) ):

- By 'tags to constraints' do you mean making them active/inactive? In the all time/space constraints there are buttons for this feature.

- The check box for activate/deactivate an (sub)activity exists in the modify (sub)activity dialog. I could however make a custom version for you, to have two buttons activate and deactivate in the (sub)activities dialogs. I would not like to add this in the official version, because there would be two places to activate/deactivate activities in the program.

- There is available an import of (sub)activities from CSV files. An import of the constraints is not available, but we could derive something for a few constraints.

- The most important: I really recommend you to use the 'max-150-days-per-week' version. We can derive a better way to import your activities. The min+max days between components constraints and the same starting hour constraints are made exactly to allow the same position on a week for the same activity for all the weeks of this activity. There is available import of activities from CSV files, and also you can see the .fet XML structure of the input file. It is not complicated. We could make a program to write such a file. Also, for the not available constraints for teachers: we could either make an import, or modify a bit the interface, so that you only add a constraint for the first week and FET will consider it for all the 16 weeks.

GEA_user

Hi,
thancks you for your welcome, .. and for your software !
with "tags to constraints" I want to activate or inactivate a package of constraints, the currently buttons in all constraints need a treatment constraint after constraint with a lots of clicks in global.
My need with check box had the same philosophy : activate or inactivate a package of activities, some activities with subactivities and some without (2 hours per week for subsject S1 between week 1 to week 5 and 1 hour per week for subject S2 between week 2 to 10 for example)
I currently use the check box in the sub-activitie dialog window but it's longer that using the activitie dialog window with filter an "one-click"
I'm interrested by an import of fines subactivities from CSV files but I don't find explanantions for that. I know how to import a 4 hours activity splited in 2+1+1 hours subactivities but I don't know how to import this 4 hours/week activity splited in 2+1+1 and splited betwen weeks 1 to 5. Using the export possibility witch seem overwrite the subactivities repartition so I thought it was impossible.
The most important :
the 'max-150-days-per-week' version seems better and I saw the min+max days between components constraints and the same starting hour constraints are made exactly to allow the same position on a week but how to set these constraints automatically for all "my" activities (currently I have 265 activities with, for each, a split by week or not and a repartition in my 16 weeks). I didn't look in the .fet xml file.
I have an other reason not using this custom version , the gestion of "specials cases" like teacher T1 is not available on day 1 in week 3 or all students are not available on day 3 of the week 4 (witch impose sometime to shift the repartition week 1 to week 5 in week1 to week 6 except 4 for example).

Yours propositions for :
a better way to import your activities
We could make a program to write such a file
we could either make an import, or modify a bit the interface, so that you only add a constraint for the first week and FET will consider it for all the 16 weeks
Are very enticing for me.
Thancks you for your propositions and your reactivity !!


Liviu Lalescu

Quote from: GEA_user on June 21, 2018, 10:32:34 PM
Hi,
thancks you for your welcome, .. and for your software !
with "tags to constraints" I want to activate or inactivate a package of constraints, the currently buttons in all constraints need a treatment constraint after constraint with a lots of clicks in global.
My need with check box had the same philosophy : activate or inactivate a package of activities, some activities with subactivities and some without (2 hours per week for subsject S1 between week 1 to week 5 and 1 hour per week for subject S2 between week 2 to 10 for example)
I currently use the check box in the sub-activitie dialog window but it's longer that using the activitie dialog window with filter an "one-click"
I'm interrested by an import of fines subactivities from CSV files but I don't find explanantions for that. I know how to import a 4 hours activity splited in 2+1+1 hours subactivities but I don't know how to import this 4 hours/week activity splited in 2+1+1 and splited betwen weeks 1 to 5. Using the export possibility witch seem overwrite the subactivities repartition so I thought it was impossible.
The most important :
the 'max-150-days-per-week' version seems better and I saw the min+max days between components constraints and the same starting hour constraints are made exactly to allow the same position on a week but how to set these constraints automatically for all "my" activities (currently I have 265 activities with, for each, a split by week or not and a repartition in my 16 weeks). I didn't look in the .fet xml file.
I have an other reason not using this custom version , the gestion of "specials cases" like teacher T1 is not available on day 1 in week 3 or all students are not available on day 3 of the week 4 (witch impose sometime to shift the repartition week 1 to week 5 in week1 to week 6 except 4 for example).

Yours propositions for :
a better way to import your activities
We could make a program to write such a file
we could either make an import, or modify a bit the interface, so that you only add a constraint for the first week and FET will consider it for all the 16 weeks
Are very enticing for me.
Thancks you for your propositions and your reactivity !!

Please forgive me for answering so late, I am preparing a new FET release and doing some changes. Also in the future please forgive me if I will answer slowly.

Indeed, for constraints is difficult. Unfortunately, it would be indeed difficult to add a list of tags (strings). If you really are interested into this, let me know. But I hope we won't need this.

For activities, you can add activity tags to them and in the tags dialog activate/deactivate all the activities for this tag.

Hmm, indeed, importing activities from CSV in the custom 150-days version is not good. I can try to derive you an import for these activities. Send me your file. 2+1+1 in the first week, in the second week, ..., in the 5th week? So 20 hours in total?

How to set the constraints - indeed, we need to derive an automatic way from your input file. Send me your input file, so I can have a look. I will try.

Gestion of "special cases": indeed, this might be very tricky, but I am willing to give it a try. I am not sure it is possible, but I will look in my code.

GEA_user

Hello,
Quote
Please forgive me for answering so late, I am preparing a new FET release and doing some changes. Also in the future please forgive me if I will answer slowly.
24 hours to have a response is widely acceptable, I don't forget it's me who need help not the reverse.  ;). And the fact that FET is a free software !
QuoteIndeed, for constraints is difficult. Unfortunately, it would be indeed difficult to add a list of tags (strings). If you really are interested into this, let me know. But I hope we won't need this.
I understand it's very difficult to add tags on constraints, I will work without.
QuoteFor activities, you can add activity tags to them and in the tags dialog activate/deactivate all the activities for this tag.
I know how to use tags for activate/deactivate activities with the same subactivities but since I didn't find an automatic way to import repartition weeks with different repartition subactivities I used tags to says "different week" and for this different week I deactivate step after step the subactivities whitch don't appear in this different week.
for example the teacher X have subject S1 with the group A for all the 16 weeks with 2+1+1 subactivities except week 12 with 2+1 and 13 with 2 and 14 with 1 and without in week 15 (total 54)
The teacher Y have the same subject S1 with the group B  for all the 16 weeks with 2+1+1 subactivities except week 14 without and except week 15 and 16 with 1 (same total 54)
And I have this kind of different repartition for all my activities (265 in total).

I will send you by email my files (not confidentials but not publics) with the repartition table, a sophisticated spreadsheet file, an FET files ( my "special week" and few weeks with specificies).

Thancks you for the time spent in my situation!





GEA_user

Hello Liviu,
It's with a touch of nostalgia that I'm returning to the task of designing a course schedule. The last time I used FET was over seven years ago! :o
While I may have forgotten a bit about FET, it has come a long way since then! :)

My needs haven't fundamentally changed:
- It's still a 16-real week university schedule.
- There are still two types of teachers: "regular" teachers and "external" teachers, with both types having activities spread over several weeks—sometimes keeping the same time slot, sometimes not. Some activities take place several times per real week in certain weeks and only once per real week in other weeks.

The custom version you designed for me back then helped me a lot, but today I don't know which of those features have been integrated into the official FET version.

In the README.GEA below:
2018-09-21
From Anthony Siaudeau:

TODO (too difficult for now) -> 1) Is there a possibility to have tags to constraints (for example to activate/inactivate a group of constraints with one click) ?

DONE -> 2) Is there a possibility to activate/inactivate activities with one click in the activities windows ?

Check boxes for active/inactive in the activities dialogs and in the all time/space constraints.

The dialogs of constraints of type:
   - max days per week for teacher
   - max gaps per day for a teacher
   - max gaps per week for a teacher
   - max span per day for a teacher
   - min hours daily for a teacher
   - max gaps per day for a students set
   - max gaps per week for a students set
are enhanced.


2018-11-25:

The modified dialogs are improved, by putting the last line with the "Close" button (as requested by Anthony Siaudeau).


2018-11-26:

There were introduced weights names for the constraints allowing less than 100.0% weight.
Warning: The locking constraints might work incorrectly if you give them weights names instead of a real number.



Point 1) does not appear to be implemented in the official FET version.
Point 2) regarding activate/inactivate appears to be implemented in the official FET version; it seems likely that the improvements to the mentioned constraints have been effective since then.
Point 2018-11-25 appears to be obsolete.
Point 2018-11-26 appears not to be implemented.

I don't know if anyone has since expressed a need for the two unintegrated points. Here's why I consider them interesting:
- The ability to tag some constraints allows for creating groups of constraints by priority level or by topic (for example, some constraints are created to address the issue of a holiday in real week or a real week with very few activities (typically the last of the 16 real weeks). Being able to filter these constraints using a tag would allow them to be disabled with a single click, enabling the generation of an initial schedule without worrying about them, and then reactivating them once a satisfactory initial schedule has been established.
- The ability to assign names to constraint weights follows a similar logic: the ability to manage increasingly stringent requirements on constraints with just a few clicks by increasing the weight of a specific group of constraints (though perhaps this is a misguided way of understanding constraint weights).


That said, I wonder if it might not be a good idea after all to use the official FET (which includes the old "FET for 120 days") perhaps in combination with mode Finland.

What had discouraged me from using it back then was the proliferation of activities and sub-activities, as well as the constraints associated with all my specific requirements (teachers with activities during the same time slots in real weeks and teachers with activities during different time slots, managing weeks with very few activities and weeks with holidays, etc.). I was afraid to dive in and end up with unsolvable schedules without really understanding what was causing the issues.
But perhaps it's easier today to import data via CSV, which makes the work less tedious since it's pre-processed using a more suitable spreadsheet-type program?

I look forward to hearing from you, :)
Best regards

Liviu Lalescu

Hello, Anthony, nice to meet you again!  :)

Let me answer in order. If I forget anything, please let me know:

1) In modern FET (7.8.0) you could add a special comment to such constraints, and filter them, and select all the list of constraints and activate/inactivate with a single click.

2) Possible in modern FET (not a check box, but a push button).

2.5) (enhanced dialogs) - I hope no need in modern FET.

2018-11-25) I hope no longer needed in modern FET.

2018-11-26) I hope no longer needed in modern FET: you could add a comment to such constraints, filter them, and select all and changed their weights with a single click.

Yes, indeed, you could try to use the Terms mode.

Unfortunately, the CSV import is still primitive.  :(

Liviu.

GEA_user

Thanks for the fast answer,
I just realized how powerful comments are when combined with filters—it's really impressive!
Looking more closely at Terms mode, it seems like I'd need to set 16 periods for my 16 actual weeks; then add constraints like "1 max activities from a set in a term" and "1 min activities from a set in a term" to ensure exactly one activity per real week.
Have I understood this correctly?

I saw that this Terms mode came from this discussion thread: https://lalescu.ro/liviu/fet/forum/index.php?topic=4387.120.
Is there any other documentation I should look at for Terms so I can choose between FET Official and FET Terms?

Liviu Lalescu

You are welcome!

I am not sure I remember correctly the Terms mode, I haven't worked with it in a long time. Yes, I think 16 terms of 5 days per term.

That's the only documentation. You have some examples (examples directory of FET, see the terms directories).

GEA_user

Okay, I'll take a closer look at the documentation for Terms mode.
And if I don't use Terms but FET Official instead, is there any documentation on the topic I've been working on for multiple weeks?
Another question—I thought I understood this wasn't possible, but I'd rather ask explicitly to be sure:  :'(
Is it conceivable to import, at least partially, the constraints associated with a project into a CSV file (to more easily manage the volume of data in a suitable interface like a spreadsheet)?
And if not, are there any tips for handling this more effectively?


Liviu Lalescu

Multiple weeks: you can have any number of days in FET, but the week consists of all days in the Official mode. In the Terms mode it is better for you, I assume.

No, unfortunately, for the CSV import/export. You might see the .fet XML structure of a file and replicate it. Custom development might be possible.

GEA_user

Good evening,
I've started testing the official mode and the Terms mode to better illustrate my problem using a basic example. I've attached the two FET files I created.
 There is a single group of students in a school with 3 teachers: teacher1 who teaches math, teacher 2, who teaches English, and teacher3 who teaches chemistry. There are 6 real weeks of 5 days each, and each day has 7 possible time slots.

teacher1 must teach a total of 8 math classes distributed as follows: 2 in the first real week, then one per real week, and finally 2 in the 6th real week. Over the 6 real weeks, there is the same time slot (same real day and same starting hour) for one class; the remaining two classes take place on other real days in real weeks 1 and 6.
Teacher2 must do exactly the same thing but with English classes,
and finally, Teacher3 must teach a total of 5 chemistry classes: three in week 3 and two in week 4; the time slots are not linked to one another.

Using the official mode, I tried a workaround by counting the real weeks as FET days (i.e., 6 FET days) and the real 7-hour days as FET hours (i.e., 7 × 5 = 35 FET hours, monday_08:00, monday_09:00, ... ,monday_17:00, tuesday_08:00, tuesday_09:00, ... , friday_16:00).
I ran into a problem right away with the constraints of the math class with teacher1: I don't know how to explain to FET that monday_15:00 and monday_16:00 are hours to be followed, but that monday_16:00 and tuesday_08:00 are not.

I tried two approaches for the 8 classes (math and therefore English):
for teacher1, I have two activities, one with 2 sub-activities for the two additional classes and the other with 6 sub-activities, with:
- 2 constraints to ensure the same time slot (starting hour and real day) for the second activity,
- 2 constraints to specify that the first activity must take place in real weeks 1 and 6,
- 2 constraints to specify that the first activity must have the same period (i.e., same real week) as the two corresponding sub-activities of the second activity,
- and finally, 2 constraints to specify that the preceding activities taking place in the same period must be at least 1 day apart.

For teacher2, I have a single activity broken down into 8 sub-activities, but for the rest, the constraints are similar, bringing the total to 8 again.
And 8 constraints for a "simple" course—I think that's a lot when I know I'm going to have to create 18 student groups, 80 teachers, and about 300 courses.

Ultimately, while the Terms mode seems useful in my case, it doesn't fundamentally change the situation, mainly because the idea behind the Terms mode is for FET to choose the right term to place the right activity, whereas in my case I already know which activity should take place during which term. Furthermore, the method of using a single activity rather than two seems more intuitive to me and would likely result in a more readable CSV import of all activities.
Finally, regardless of the version of FET used and whether activities are split into one or two, what I really missed were tags for the FET days (I'm thinking of tags named week1, week2, etc.) to create time constraints based on these tags that are simpler, fewer in number, and more readable than the constraints I used.

But maybe I just used the constraints incorrectly?



Liviu Lalescu

Good morning!

I had a quick look over your files.

In your Official mode, you could add breaks between real days (5 rows of X-s). But I think it is better to have 30 FET days.

To have a pair of activities be on the same real day, you must for each pair add min+max days between them = 5. Well, for min maybe you could add a single constraint for all activities.

To make subactivities be in a certain real week, you could use a few constraints subactivities preferred times, specifying the split index. This way, you don't have to add for each individual activity.

I'll write your suggestion to add tags for days in the list of suggestions.

GEA_user

Hi,
I wasn't familiar with the "break" constraint; that's interesting.
Your idea of using constraints on sub-activities by specifying the index won't work in my case because there's no guarantee that the first sub-activity actually starts in week 1. For example, the chemistry activity with teacher3 is split into five sub-activities but doesn't start until week 3.
However, I will be able to use a CSV import that specifies a tag for each sub-activity indicating the actual week it applies to. It will then be possible to specify preferred time constraints that apply globally to all activities and are based solely on the actual week tags. I've checked, and this significantly reduces the number of constraints per course!

Thank you very much! :)  I'll look into this further for my imports and see how to automatically generate the correct tags.

Liviu Lalescu

Oh, indeed, it is very easy to add a different tag to each subactivity.

You are welcome!  :)