Glob pattern for measurement groups
RATIONALE:
Provide users with a nice way to enable/disable counters in measurement groups, using the counter names rather than Python code.
As of today, selecting BPM or ROI counters for a camera is painful when using the .
syntax because we are strict on the rules with .counters
, .counter_groups
(which is
good), but it is not so convenient with the counter name (with :
) because there is
no way to select multiple counters.
So, if someone wants to select all BPM counters she can do:
mg.enable("pilatus.counter_groups.bpm") # considered too long to type
Or:
# not convenient at all
mg.enable("pilatus:bpm_x")
mg.enable("pilatus:bpm_y")
...
PROPOSAL:
- the possibility to use wildcards (thanks to
glob
module) forMeasurementGroup
names- e.g.
.enable("pilatus:bpm*")
for example to enablepilatus:bpm_x
,pilatus:bpm_y
, etc
- e.g.
RELATED QUESTIONS:
- it is also possible to enable/disable counters using the counter objects themselves, or the controllers themselves (to make it short: things with
.counters
) ; what do you think of only accepting strings instead ?- It would require extra
"
when typing
- It would require extra
- what do you think of not accepting the
.
syntax anymore ? - what about providing a nice user interface to enable/disable counters in the measurement groups using a dialog ?
- solves the typing problem for users, ok for programs to call
.enable()/.disable()
- solves the typing problem for users, ok for programs to call