-
Type: Task
-
Status: Done (View Workflow)
-
Priority: Normal
-
Resolution: Done
-
Component/s: ets_fiberalloc
-
Labels:None
At the moment, the netflow code allows specifying a uniform observation duration, which is used for all visits in a fiber allocation problem.
Masayuki Tanaka requested to allow specifying individual durations for every visit.
This should be possible, but requires some internal restructuring of the code, since at the moment we simply compute the number of visits that any given science target must be observed, leading to a simple integer constraint per science target. This approach must be replaced with a slightly more complicated set of floating-point constraints, which might (I 'm not sure) increase the solution space for the netflow problem and could therefore increase run times.
I hope to have a tentative implementation ready in two weeks' time.
Please note: this change will most likely break the backwards compatibility of the netflow code, i.e. existing codes using netflow will have to be adjusted slightly to work with the new netflow version which implements this feature.
[Edit:]To be precise, the following function arguments to the {{buildProblem }}function would be affected:
- tvisit: will change from a single float to a lost of floats. We can keep backwards compatibility here by generating the list on the fly if only a single value is provided.
- alreadyObserved: will change from dict {string: int} to a dict {string: float}, and the float will represent the seconds that the target in question has already been observed. This will be much more difficult to implement without breaking backwards compatibility
It would of course also be possible to keep backwards compatibility by accepting either tvisit and alreadyObserved (meaning backwards compatibility mode), or alternatively tvisit_new and alreadyObserved_new (placeholder names), which trigger "modern" mode. This just makes documentation somewhat complicated.