Open maxnoe opened 4 years ago
Maybe also using pandas eval or numexpr directly for this like in the feature generation is a good idea
Wouldn't this be a use case for pandas query? https://pandas.pydata.org/pandas-docs/stable/reference/api/pandas.DataFrame.query.html#pandas.DataFrame.query
How would the configuration syntax for the logical or conditions look like anyway? I think the current syntax might be to limited for that. We could (if we go with eval/query) go for something like:
selection:
- intensity > 50
- num_islands < 5
- width > 0 and width < 10
- telescope == 'LST' or telescope == 'MST'
- run == 1 or run == 5
This way every line equals one boolean expression and all of them are joined with a logical and.
But maybe there is a better, backwards compatible way?
[x] Allow ranges, e.g. like
[ ] Allow logical or / not