Skip to content

Commit

Permalink
Merge pull request #183 from lsst/tickets/DM-46991
Browse files Browse the repository at this point in the history
DM-46991: switch to calibrateImage
  • Loading branch information
TallJimbo authored Nov 26, 2024
2 parents 869d593 + 65bac0b commit ef1aa0a
Show file tree
Hide file tree
Showing 21 changed files with 156 additions and 164 deletions.
2 changes: 1 addition & 1 deletion bps/clustering/DRP-recalibrated.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,7 +12,7 @@
clusterAlgorithm: lsst.ctrl.bps.quantum_clustering_funcs.dimension_clustering
cluster:
visit_detector:
pipetasks: isr,inject_exposure,characterizeImage,calibrate,inject_visit,writePreSourceTable,transformPreSourceTable
pipetasks: isr,inject_exposure,calibrateImage,inject_visit,transformPreSourceTable
dimensions: visit,detector
equalDimensions: visit:exposure

Expand Down
2 changes: 1 addition & 1 deletion bps/clustering/LSSTCam-imSim/DRP-DC2-clustering.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
clusterAlgorithm: lsst.ctrl.bps.quantum_clustering_funcs.dimension_clustering
cluster:
visit_detector:
pipetasks: isr,inject_exposure,characterizeImage,calibrate,inject_visit,writeSourceTable,transformSourceTable
pipetasks: isr,inject_exposure,calibrateImage,inject_visit,transformSourceTable
dimensions: visit,detector
equalDimensions: visit:exposure

Expand Down
4 changes: 1 addition & 3 deletions pipelines/HSC/DRP-Prod.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -16,9 +16,7 @@ subsets:
step1:
subset:
- isr
- characterizeImage
- calibrate
- writePreSourceTable
- calibrateImage
- transformPreSourceTable
- analyzeAmpOffsetMetadata
description: |
Expand Down
6 changes: 2 additions & 4 deletions pipelines/HSC/DRP-RC2.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -81,12 +81,10 @@ subsets:
step1:
subset:
- isr
- characterizeImage
- calibrate
- writePreSourceTable
- calibrateImage
- transformPreSourceTable
- analyzeAmpOffsetMetadata
- analyzeCalibrateMetadata
- analyzeCalibrateImageMetadata
description: |
Per-detector tasks that can be run together to start the DRP pipeline.
Expand Down
11 changes: 3 additions & 8 deletions pipelines/HSC/DRP-RC2_subset.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -26,8 +26,7 @@ subsets:
simpleSingleFrame:
subset:
- isr
- characterizeImage
- calibrate
- calibrateImage
description: |
A simplified single frame pipeline to make the quantum graph more readable.
multiVisit:
Expand All @@ -39,9 +38,7 @@ subsets:
singleFrame:
subset:
- isr
- characterizeImage
- calibrate
- writePreSourceTable
- calibrateImage
- transformPreSourceTable
- consolidatePreSourceTable
- consolidateVisitSummary
Expand Down Expand Up @@ -81,9 +78,7 @@ subsets:
nightlyStep1:
subset:
- isr
- characterizeImage
- calibrate
- writePreSourceTable
- calibrateImage
- transformPreSourceTable
description: |
Per-detector tasks that can be run together to start the DRP pipeline.
Expand Down
6 changes: 3 additions & 3 deletions pipelines/HSC/DRP-ci_hsc.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -32,13 +32,13 @@ tasks:
multibandDeblend.useCiLimits: true
# Do not run the deblender on isolated sources
multibandDeblend.processSingles: false
calibrate:
class: lsst.pipe.tasks.calibrate.CalibrateTask
calibrateImage:
class: lsst.pipe.tasks.calibrateImage.CalibrateImageTask
# Significantly limit the number of sources to deblend, which saves time
# in both deblending and measurement
config:
# Only run the deblender on a small subset of blended parents
deblend.useCiLimits: true
star_deblend.useCiLimits: true
writeRecalibratedSourceTable:
class: lsst.pipe.tasks.postprocess.WriteRecalibratedSourceTableTask
config:
Expand Down
4 changes: 1 addition & 3 deletions pipelines/LATISS/DRP.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -119,9 +119,7 @@ subsets:
step1:
subset:
- isr
- characterizeImage
- calibrate
- writePreSourceTable
- calibrateImage
- transformPreSourceTable
description: |
Per-detector tasks that can be run together to start the DRP pipeline.
Expand Down
6 changes: 3 additions & 3 deletions pipelines/LSSTCam-imSim/DRP-ci_imsim.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -18,13 +18,13 @@ tasks:
multibandDeblend.useCiLimits: true
# Do not run the deblender on isolated sources
multibandDeblend.processSingles: false
calibrate:
class: lsst.pipe.tasks.calibrate.CalibrateTask
calibrateImage:
class: lsst.pipe.tasks.calibrateImage.CalibrateImageTask
# Significantly limit the number of sources to deblend, which saves time
# in both deblending and measurement
config:
# Only run the deblender on a small subset of blended parents
deblend.useCiLimits: true
star_deblend.useCiLimits: true
catalogMatchVisit:
class: lsst.analysis.tools.tasks.astrometricCatalogMatch.AstrometricCatalogMatchVisitTask
config:
Expand Down
39 changes: 3 additions & 36 deletions pipelines/LSSTCam/quickLook.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -22,47 +22,14 @@ tasks:
doDefect: false
doDark: false
doFlat: false

# TO DO: Replace with calibrateImage in a way that we can use the
# preSources downstream.
characterizeImage:
class: lsst.pipe.tasks.characterizeImage.CharacterizeImageTask
config:
doApCorr: false
doDeblend: false
calibrate:
class: lsst.pipe.tasks.calibrate.CalibrateTask
config:
python: |
config.measurement.plugins.names = ['base_CircularApertureFlux',
'base_PsfFlux',
'base_LocalBackground',
'base_SdssCentroid',
'base_SdssShape',
'base_Variance',
'base_Jacobian',
'base_PixelFlags',
'base_GaussianFlux',
'base_SkyCoord',
'base_FPPosition',
'base_ClassificationSizeExtendedness',
'base_CompensatedTophatFlux',
]
config.measurement.slots.shape = "base_SdssShape"
config.measurement.slots.psfShape = "base_SdssShape_psf"
config.measurement.plugins['base_PixelFlags'].masksFpAnywhere.remove('STREAK')
config.measurement.plugins['base_PixelFlags'].masksFpCenter.remove('STREAK')
config.doApCorr = False
config.doDeblend = False
config.astrometry.sourceSelector["science"].doRequirePrimary = False
config.astrometry.sourceSelector["science"].doIsolated = False
calibrateImage:
class: lsst.pipe.tasks.calibrateImage.CalibrateImageTask
# TO DO: DM-41189 Get pipeline that will attach an atool here from lauren

Check warning on line 27 in pipelines/LSSTCam/quickLook.yaml

View workflow job for this annotation

GitHub Actions / call-workflow / yamllint

27:7 [comments-indentation] comment not indented like content
subsets:
step1:
subset:
- isr
- characterizeImage
- calibrate
- calibrateImage
# TO DO: configure and add writePreSourceTable, transformPreSourceTable
description: |
Per-detector tasks that can be run together
Expand Down
4 changes: 1 addition & 3 deletions pipelines/LSSTComCamSim/DRP.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -7,9 +7,7 @@ subsets:
step1:
subset:
- isr
- characterizeImage
- calibrate
- writePreSourceTable
- calibrateImage
- transformPreSourceTable
description: |
Per-detector tasks that can be run together to start the DRP pipeline.
Expand Down
17 changes: 5 additions & 12 deletions pipelines/LSSTComCamSim/nightly-validation.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -15,15 +15,8 @@ tasks:
connections.data: preSourceTable_visit
connections.inputName: preSourceTable_visit
connections.outputName: preSourceTableCore
calibrate:
class: lsst.pipe.tasks.calibrate.CalibrateTask
config:
python: |
from lsst.analysis.tools.tasks import CalexpSummaryAnalysisTask
config.createSummaryMetrics.retarget(CalexpSummaryAnalysisTask)
from lsst.analysis.tools.atools import CalexpSummaryMetrics
config.createSummaryMetrics.atools.calexpSummaryMetrics = CalexpSummaryMetrics
doCreateSummaryMetrics: true
calibrateImage:
class: lsst.pipe.tasks.calibrateImage.CalibrateImageTask
updateVisitSummary:
class: lsst.drp.tasks.update_visit_summary.UpdateVisitSummaryTask
config:
Expand All @@ -36,10 +29,10 @@ subsets:
step1:
subset:
- isr
- characterizeImage
- calibrate
- writePreSourceTable
- calibrateImage
- transformPreSourceTable
- calexpSummary
- analyzeCalibrateImageMetadata
description: |
Detector level tasks. TO DO: requests include synthetic source injection,
subtractImages, detectAndMeasureDiaSources.
Expand Down
38 changes: 4 additions & 34 deletions pipelines/LSSTComCamSim/quickLook.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -12,45 +12,15 @@ tasks:
doBrighterFatter: false
# TO DO: Replace with calibrateImage in a way that we can use the
# preSources downstream.
characterizeImage:
class: lsst.pipe.tasks.characterizeImage.CharacterizeImageTask
config:
doApCorr: false
doDeblend: false
calibrate:
class: lsst.pipe.tasks.calibrate.CalibrateTask
config:
python: |
config.measurement.plugins.names = ['base_CircularApertureFlux',
'base_PsfFlux',
'base_LocalBackground',
'base_SdssCentroid',
'base_SdssShape',
'base_Variance',
'base_Jacobian',
'base_PixelFlags',
'base_GaussianFlux',
'base_SkyCoord',
'base_FPPosition',
'base_ClassificationSizeExtendedness',
'base_CompensatedTophatFlux',
]
config.measurement.slots.shape = "base_SdssShape"
config.measurement.slots.psfShape = "base_SdssShape_psf"
config.measurement.plugins['base_PixelFlags'].masksFpAnywhere.remove('STREAK')
config.measurement.plugins['base_PixelFlags'].masksFpCenter.remove('STREAK')
config.doApCorr = False
config.doDeblend = False
config.astrometry.sourceSelector["science"].doRequirePrimary = False
config.astrometry.sourceSelector["science"].doIsolated = False
calibrateImage:
class: lsst.pipe.tasks.calibrateImage.CalibrateImageTask
# TO DO: DM-41189 Get pipeline that will attach an atool here from lauren

Check warning on line 17 in pipelines/LSSTComCamSim/quickLook.yaml

View workflow job for this annotation

GitHub Actions / call-workflow / yamllint

17:7 [comments-indentation] comment not indented like content
subsets:
step1:
subset:
- isr
- characterizeImage
- calibrate
# TO DO: configure and add writePreSourceTable, transformPreSourceTable
- calibrateImage
# TO DO: configure and add transformPreSourceTable
description: |
Per-detector tasks that can be run together
step2a:
Expand Down
13 changes: 6 additions & 7 deletions pipelines/_ingredients/DECam/DRP.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -34,11 +34,12 @@ tasks:
config:
connections.crosstalkSources: overscanRaw
doCrosstalk: true
calibrate:
class: lsst.pipe.tasks.calibrate.CalibrateTask
calibrateImage:
class: lsst.pipe.tasks.calibrateImage.CalibrateImageTask
# TODO: these should live in obs_decam, probably!
config:
photoCal.match.referenceSelection.magLimit.fluxField: i_flux
photoCal.match.referenceSelection.magLimit.maximum: 22.0
photometry.match.referenceSelection.magLimit.fluxField: i_flux
photometry.match.referenceSelection.magLimit.maximum: 22.0
updateVisitSummary:
class: lsst.drp.tasks.update_visit_summary.UpdateVisitSummaryTask
config:
Expand Down Expand Up @@ -132,10 +133,8 @@ subsets:
step1:
subset:
- isr
- characterizeImage
- calibrate
- calibrateImage
- transformPreSourceTable
- writePreSourceTable
description: |
Per-detector tasks that can be run together to start the DRP pipeline.
Expand Down
20 changes: 13 additions & 7 deletions pipelines/_ingredients/DRP-full.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,6 @@ description:
the 'pipelines' directory (or create a custom one) instead.
imports:
- location: $DRP_PIPE_DIR/pipelines/_ingredients/DRP-minimal-calibration.yaml
exclude:
- writeSourceTable # cannot reconfigure because different dimensions.
tasks:
isr:
class: lsst.ip.isr.IsrTask
Expand All @@ -16,6 +14,14 @@ tasks:
# to compute them for analyzeAmpOffsetMetadata to report on as metrics.
doAmpOffset: true
ampOffset.doApplyAmpOffset: false
calibrateImage:
class: lsst.pipe.tasks.calibrateImage.CalibrateImageTask
config:

connections.stars: preSource
connections.exposure: calexp
connections.background: calexpBackground

skyCorr:
class: lsst.pipe.tasks.skyCorrection.SkyCorrectionTask
isolatedStarAssociation:
Expand All @@ -34,15 +40,16 @@ tasks:
class: lsst.fgcmcal.fgcmFitCycle.FgcmFitCycleTask
fgcmOutputProducts:
class: lsst.fgcmcal.fgcmOutputProducts.FgcmOutputProductsTask
writePreSourceTable:
class: lsst.pipe.tasks.postprocess.WriteSourceTableTask
config:
connections.outputCatalog: preSource
transformPreSourceTable:
class: lsst.pipe.tasks.postprocess.TransformSourceTableTask
config:
functorFile: $PIPE_TASKS_DIR/schemas/PreSource.yaml
connections.inputCatalog: preSource
connections.outputCatalog: preSourceTable
transformSourceTable:
class: lsst.pipe.tasks.postprocess.TransformSourceTableTask
config:
functorFile: $PIPE_TASKS_DIR/schemas/Source.yaml
consolidatePreSourceTable:
class: lsst.pipe.tasks.postprocess.ConsolidateSourceTableTask
config:
Expand Down Expand Up @@ -91,7 +98,6 @@ subsets:
Subset that includes all FGCM tasks.
preSourceTable:
subset:
- writePreSourceTable
- transformPreSourceTable
- consolidatePreSourceTable
description: >
Expand Down
Loading

0 comments on commit ef1aa0a

Please sign in to comment.