Skip to content

Commit

Permalink
Merge pull request #166 from lsst/tickets/DM-12933
Browse files Browse the repository at this point in the history
DM-12933: Write variance scaling to Exposure metadata, not Task metadata
  • Loading branch information
TallJimbo committed Dec 7, 2017
2 parents 4464a26 + 5e52f5d commit f7234cf
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions python/lsst/pipe/tasks/multiBand.py
Original file line number Diff line number Diff line change
Expand Up @@ -282,7 +282,8 @@ def runDetection(self, exposure, idFactory):
using \ref scaleVariance. Then invoke the \ref SourceDetectionTask_ "detection" subtask to
detect sources.
\param[in] exposure: Exposure on which to detect
\param[in,out] exposure: Exposure on which to detect (may be backround-subtracted and scaled,
depending on configuration).
\param[in] idFactory: IdFactory to set source identifiers
\return a pipe.base.Struct with fields
Expand All @@ -291,7 +292,7 @@ def runDetection(self, exposure, idFactory):
"""
if self.config.doScaleVariance:
varScale = scaleVariance(exposure.getMaskedImage(), self.config.mask, log=self.log)
self.metadata.add("variance_scale", varScale)
exposure.getMetadata().add("variance_scale", varScale)
backgrounds = afwMath.BackgroundList()
if self.config.doInsertFakes:
self.insertFakes.run(exposure, background=backgrounds)
Expand Down

0 comments on commit f7234cf

Please sign in to comment.