# Using anyFilterMapsToThis requires manually blanking filterMap

XMLWordPrintable

#### Details

• Type: Story
• Status: Won't Fix
• Resolution: Done
• Fix Version/s: None
• Component/s:
• Labels:
None
• Team:
• Urgent?:
No

#### Description

 config.astromRefObjLoader.anyFilterMapsToThis = 'phot_g_mean' config.astromRefObjLoader.filterMap = {} 

The 2nd line, or something like it, is required for the task to run, otherwise I get an error saying

  File "/software/lsstsw/stack_20210813/stack/miniconda3-py38_4.9.2-0.7.0/Linux64/pex_config/gc9a196ae7d+3b73b15e11/python/lsst/pex/config/configurableField.py", line 371, in validate  value.validate()  File "/home/mfl/lsst/meas_algorithms/python/lsst/meas/algorithms/loadReferenceObjects.py", line 228, in validate  raise pexConfig.FieldValidationError(LoadReferenceObjectsConfig.anyFilterMapsToThis, lsst.pex.config.config.FieldValidationError: Field 'astromRefObjLoader.anyFilterMapsToThis' failed validation: filterMap and anyFilterMapsToThis are mutually exclusive For more information see the Field definition at:  File meas/algorithms/loadReferenceObjects.py:199 (LoadReferenceObjectsConfig) and the Config definition at:  File meas/algorithms/loadIndexedReferenceObjects.py:34 () 

#### Activity

Hide
John Parejko added a comment -

This is intended behavior: there is no way for the code to know which of those configs (filterMap or anyFilterMapsToThis) the user meant to be used if both of them are set.

Show
John Parejko added a comment - This is intended behavior: there is no way for the code to know which of those configs (filterMap or anyFilterMapsToThis) the user meant to be used if both of them are set.

#### People

Assignee:
John Parejko
Reporter:
Merlin Fisher-Levine
Watchers:
John Parejko, Merlin Fisher-Levine