Skip to content

Commit

Permalink
Clean up overrides for refcats.
Browse files Browse the repository at this point in the history
- Set the obs-package default for photometry to the_monster, override
  in ImSim, ComCamSim, and (for now?) LATISS.
- Don't include a comment that just repeats the file name.
- Don't set 'connections.data'; it's defined by a template that
  includes 'connections.refCatalog'.
  • Loading branch information
TallJimbo committed Oct 24, 2024
1 parent 8a6286b commit fbcf8eb
Show file tree
Hide file tree
Showing 25 changed files with 39 additions and 64 deletions.
1 change: 1 addition & 0 deletions config/analysisToolsPhotometricCatalogMatch.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
config.connections.refCatalog = "the_monster_20240904"
1 change: 1 addition & 0 deletions config/analysisToolsPhotometricCatalogMatchVisit.py
Original file line number Diff line number Diff line change
@@ -0,0 +1 @@
config.connections.refCatalog = "the_monster_20240904"
4 changes: 0 additions & 4 deletions config/comCam/analysisToolsPhotometricCatalogMatch.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
"""Overrides for PhotometricCatalogMatchTask"""

import os.path

configDir = os.path.dirname(__file__)
config.referenceCatalogLoader.refObjLoader.load(os.path.join(configDir, "filterMap.py"))
config.referenceCatalogLoader.doApplyColorTerms = False

config.connections.refCatalog = "the_monster_20240904"
4 changes: 0 additions & 4 deletions config/comCam/analysisToolsPhotometricCatalogMatchVisit.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,5 @@
"""Overrides for PhotometricCatalogMatchTask"""

import os.path

configDir = os.path.dirname(__file__)
config.referenceCatalogLoader.refObjLoader.load(os.path.join(configDir, "filterMap.py"))

config.connections.refCatalog = "the_monster_20240904"
config.referenceCatalogLoader.doApplyColorTerms = False
3 changes: 0 additions & 3 deletions config/comCam/measureCoaddSources.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
"""comCam-specific overrides for MeasureMergedCoaddSourcesTask"""

import os.path

config.match.refObjLoader.load(os.path.join(os.path.dirname(__file__), "filterMap.py"))
config.connections.refCat = "the_monster_20240904"
2 changes: 0 additions & 2 deletions config/comCamSim/analysisToolsPhotometricCatalogMatch.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
"""comCamSim-specific overrides for PhotometricCatalogMatchTask"""

import os.path

configDir = os.path.dirname(__file__)
Expand Down
Original file line number Diff line number Diff line change
@@ -1,9 +1,7 @@
"""comCamSim-specific overrides for PhotometricCatalogMatchVisitTask"""

import os.path

configDir = os.path.dirname(__file__)
config.referenceCatalogLoader.refObjLoader.load(os.path.join(configDir, "filterMap.py"))
config.referenceCatalogLoader.doApplyColorTerms = False

config.connections.refCatalog = "uw_stars_20240524"
config.referenceCatalogLoader.doApplyColorTerms = False
2 changes: 0 additions & 2 deletions config/comCamSim/measureCoaddSources.py
Original file line number Diff line number Diff line change
@@ -1,5 +1,3 @@
"""comCamSim-specific overrides for MeasureMergedCoaddSourcesTask"""

import os.path

config.match.refObjLoader.load(os.path.join(os.path.dirname(__file__), "filterMap.py"))
Expand Down
4 changes: 1 addition & 3 deletions config/comCamSim/refCatObjectPhotometricAnalysisTask.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
"""Overrides for RefCatObjectPhotometricAnalysisTask"""

config.connections.outputName = "objectTable_tract_uw_stars_20240524_match_photom"
config.connections.refCatalog = "uw_stars_20240524"
config.connections.outputName = "objectTable_tract_uw_stars_20240524_match_photom"
5 changes: 2 additions & 3 deletions config/comCamSim/refCatSourcePhotometricAnalysisTask.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
"""comCamSim-specific overrides for RefCatSourcePhotometricAnalysisTask"""

config.connections.data = "sourceTable_visit_uw_stars_20240524_photoMatch"
config.connections.refCatalog = "uw_stars_20240524"
config.connections.outputName = "sourceTable_visit_uw_stars_20240524_match_photom"
2 changes: 1 addition & 1 deletion config/imsim/analysisToolsPhotometricCatalogMatch.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@

configDir = os.path.dirname(__file__)
config.referenceCatalogLoader.refObjLoader.load(os.path.join(configDir, "filterMap.py"))

config.referenceCatalogLoader.doApplyColorTerms = False
config.connections.refCatalog = "cal_ref_cat_2_2"
2 changes: 1 addition & 1 deletion config/imsim/analysisToolsPhotometricCatalogMatchVisit.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,5 +2,5 @@

configDir = os.path.dirname(__file__)
config.referenceCatalogLoader.refObjLoader.load(os.path.join(configDir, "filterMap.py"))

config.referenceCatalogLoader.doApplyColorTerms = False
config.connections.refCatalog = "cal_ref_cat_2_2"
26 changes: 1 addition & 25 deletions config/imsim/measureCoaddSources.py
Original file line number Diff line number Diff line change
@@ -1,28 +1,4 @@
# This file is part of obs_lsst.
#
# Developed for the LSST Data Management System.
# This product includes software developed by the LSST Project
# (http://www.lsst.org).
# See the COPYRIGHT file at the top-level directory of this distribution
# for details of code ownership.
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the LSST License Statement and
# the GNU General Public License along with this program. If not,
# see <http://www.lsstcorp.org/LegalNotices/>.

"""imSim-specific overrides for MeasureMergedCoaddSourcesTask"""

import os.path

config.match.refObjLoader.load(os.path.join(os.path.dirname(__file__), "filterMap.py"))
config.connections.refCat = "cal_ref_cat"
config.connections.refCat = "cal_ref_cat_2_2"
2 changes: 2 additions & 0 deletions config/imsim/refCatObjectPhotometricAnalysisTask.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
config.connections.refCatalog = "cal_ref_cat_2_2"
config.connections.outputName = "objectTable_tract_cal_ref_cat_2_2_match_photom"
2 changes: 2 additions & 0 deletions config/imsim/refCatSourcePhotometricAnalysisTask.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
config.connections.refCatalog = "cal_ref_cat_2_2"
config.connections.outputName = "sourceTable_visit_cal_ref_cat_2_2_match_photom"
1 change: 1 addition & 0 deletions config/latiss/analysisToolsPhotometricCatalogMatch.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,6 +6,7 @@
config.referenceCatalogLoader.doApplyColorTerms = True
config.referenceCatalogLoader.colorterms.load(os.path.join(OBS_CONFIG_DIR, "colorterms.py"))

config.connections.refCatalog = "atlas_refcat2_20220201"
config.filterNames = ["SDSSg_65mm~empty",
"SDSSr_65mm~empty",
"SDSSi_65mm~empty",
Expand Down
9 changes: 9 additions & 0 deletions config/latiss/analysisToolsPhotometricCatalogMatchVisit.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,9 @@
import os.path

OBS_CONFIG_DIR = os.path.dirname(__file__)

config.referenceCatalogLoader.refObjLoader.load(os.path.join(OBS_CONFIG_DIR, "filterMap.py"))
config.referenceCatalogLoader.doApplyColorTerms = True
config.referenceCatalogLoader.colorterms.load(os.path.join(OBS_CONFIG_DIR, "colorterms.py"))

config.connections.refCatalog = "atlas_refcat2_20220201"
4 changes: 2 additions & 2 deletions config/latiss/refCatObjectPhotometricAnalysisTask.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,5 +6,5 @@
objectConfig.load(os.path.join(os.path.dirname(__file__), "transformObjectCatalog.py"))
config.bands = objectConfig.outputBands

config.connections.refCatalog = "the_monster_20240904"
config.connections.outputName = "objectTable_tract_the_monster_20240904_match_photom"
config.connections.refCatalog = "atlas_refcat2_20220201"
config.connections.outputName = "objectTable_tract_atlas_refcat2_20220201_match_photom"
10 changes: 10 additions & 0 deletions config/latiss/refCatSourcePhotometricAnalysisTask.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,10 @@
import os.path
from lsst.pipe.tasks.postprocess import TransformObjectCatalogConfig

# By default loop over all the same bands that are present in the Object Table
objectConfig = TransformObjectCatalogConfig()
objectConfig.load(os.path.join(os.path.dirname(__file__), "transformObjectCatalog.py"))
config.bands = objectConfig.outputBands

config.connections.refCatalog = "atlas_refcat2_20220201"
config.connections.outputName = "sourceTable_visit_atlas_refcat2_20220201_match_photom"
2 changes: 0 additions & 2 deletions config/lsstCam/analysisToolsPhotometricCatalogMatch.py
Original file line number Diff line number Diff line change
Expand Up @@ -5,5 +5,3 @@
configDir = os.path.dirname(__file__)
config.referenceCatalogLoader.refObjLoader.load(os.path.join(configDir, "filterMap.py"))
config.referenceCatalogLoader.doApplyColorTerms = False

config.connections.refCatalog = "atlas_refcat2_20220201"
2 changes: 0 additions & 2 deletions config/lsstCam/analysisToolsPhotometricCatalogMatchVisit.py
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,4 @@

configDir = os.path.dirname(__file__)
config.referenceCatalogLoader.refObjLoader.load(os.path.join(configDir, "filterMap.py"))

config.connections.refCatalog = "atlas_refcat2_20220201"
config.referenceCatalogLoader.doApplyColorTerms = False
3 changes: 0 additions & 3 deletions config/lsstCam/measureCoaddSources.py
Original file line number Diff line number Diff line change
@@ -1,6 +1,3 @@
"""LSSTCam-specific overrides for MeasureMergedCoaddSourcesTask"""

import os.path

config.match.refObjLoader.load(os.path.join(os.path.dirname(__file__), "filterMap.py"))
config.connections.refCat = "atlas_refcat2_20220201"
2 changes: 1 addition & 1 deletion config/measureCoaddSources.py
Original file line number Diff line number Diff line change
Expand Up @@ -29,5 +29,5 @@
config.load(os.path.join(os.path.dirname(__file__), "cmodel.py"))

config.doWriteMatchesDenormalized = True

config.connections.refCat = "the_monster_20240904"
config.measurement.plugins.names |= ["base_InputCount"]
2 changes: 2 additions & 0 deletions config/refCatObjectPhotometricAnalysisTask.py
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
config.connections.refCatalog = "the_monster_20240904"
config.connections.outputName = "objectTable_tract_the_monster_20240904_match_photom"
4 changes: 1 addition & 3 deletions config/refCatSourcePhotometricAnalysisTask.py
Original file line number Diff line number Diff line change
@@ -1,4 +1,2 @@
"""Overrides for RefCatSourcePhotometricAnalysisTask"""

config.connections.data = "sourceTable_visit_the_monster_20240904_match_photom"
config.connections.refCatalog = "the_monster_20240904"
config.connections.outputName = "sourceTable_visit_the_monster_20240904_match_photom"

0 comments on commit fbcf8eb

Please sign in to comment.