Details
-
Type:
Improvement
-
Status: Done
-
Resolution: Done
-
Fix Version/s: None
-
Component/s: meas_algorithms
-
Labels:None
-
Story Points:1
-
Epic Link:
-
Sprint:Science Pipelines DM-W15-4, Science Pipelines DM-S15-1, DRP S17-3
-
Team:Data Release Production
Description
The SourceDetectionTask always adds "flags.negative" to the schema (if provided) but it is only used if config.thresholdParity == "both".
As adding a field to a schema requires that the table passed to the run method have that field this is a significant nuisance when reusing the task. Please change the code to only modify the schema if it's going to set it.
As far as I can tell, the conditions under which flags.negative is set is actually:
schema is not None and (self.config.reEstimateBackground or self.config.thresholdPolarity != "positive"):
This seems like a rather complex condition for the init code to be checking (that is, at the time that flags.negative is added to the schema).