Skip to content

Commit

Permalink
Merge pull request #53 from lsst/tickets/DM-14868
Browse files Browse the repository at this point in the history
Tickets/dm 14868
  • Loading branch information
wmwv committed Dec 20, 2018
2 parents 1ce0f61 + 152d599 commit 62fdbae
Show file tree
Hide file tree
Showing 2 changed files with 29 additions and 9 deletions.
12 changes: 12 additions & 0 deletions config/colorterms.py
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,19 @@

from lsst.pipe.tasks.colorterms import Colorterm, ColortermDict

# 2018-09-04: Michael Wood-Vasey:
# The color terms should translate between the photometric reference catalog
# and the system transmission of MegaCam.
# I've added a set of color terms here for the PS1 reference catalog
# assuming that the PS1 catalog is on the AB system.
config.data = {
"ps1*": ColortermDict(data={
"u": Colorterm(primary="u", secondary="g", c0=0.0, c1=-0.241),
"g": Colorterm(primary="g", secondary="r", c0=0.0, c1=-0.153),
"r": Colorterm(primary="r", secondary="g", c0=0.0, c1=0.024),
"i": Colorterm(primary="i", secondary="r", c0=0.0, c1=0.085),
"z": Colorterm(primary="z", secondary="i", c0=0.0, c1=-0.074),
}),
"e2v": ColortermDict(data={
"u": Colorterm(primary="u", secondary="g", c0=0.0, c1=-0.241),
"g": Colorterm(primary="g", secondary="r", c0=0.0, c1=-0.153),
Expand Down
26 changes: 17 additions & 9 deletions config/processCcd.py
Original file line number Diff line number Diff line change
Expand Up @@ -6,12 +6,15 @@
from lsst.utils import getPackageDir
from lsst.obs.cfht.cfhtIsrTask import CfhtIsrTask

obsConfigDir = os.path.join(getPackageDir("obs_cfht"), "config")
from lsst.meas.algorithms import LoadIndexedReferenceObjectsTask

cfhtConfigDir = os.path.join(getPackageDir("obs_cfht"), "config")
config.calibrate.photoCal.colorterms.load(os.path.join(cfhtConfigDir, 'colorterms.py'))

config.isr.retarget(CfhtIsrTask)
config.isr.load(os.path.join(obsConfigDir, "isr.py"))
config.isr.load(os.path.join(cfhtConfigDir, "isr.py"))

config.calibrate.photoCal.colorterms.load(os.path.join(obsConfigDir, 'colorterms.py'))
config.calibrate.photoCal.colorterms.load(os.path.join(cfhtConfigDir, 'colorterms.py'))

config.charImage.repair.doCosmicRay = True
config.charImage.repair.cosmicray.cond3_fac = 2.5
Expand All @@ -21,18 +24,23 @@
config.charImage.repair.cosmicray.minSigma = 6.0
config.charImage.repair.cosmicray.min_DN = 150.0

# Configuration for AstrometryTask, the default. If the user retargets to
# ANetAstrometryTask, they must update the astrometry.solver.filterMap config
# manually; doing it here is impossible because these overrides are applied
# before any user overrides where retargeting could occur.
# Astrometry
for refObjLoader in (config.calibrate.astromRefObjLoader,
config.calibrate.photoRefObjLoader,
config.charImage.refObjLoader):
config.charImage.refObjLoader,
):
refObjLoader.retarget(LoadIndexedReferenceObjectsTask)
refObjLoader.filterMap = {'i2': 'i'}
refObjLoader.ref_dataset_name = "ps1_pv3_3pi_20170110"

config.calibrate.astrometry.wcsFitter.order = 3
config.calibrate.astrometry.matcher.maxMatchDistArcSec = 5

config.calibrate.photoCal.applyColorTerms = True
config.calibrate.photoCal.photoCatName = "e2v"
config.calibrate.photoCal.photoCatName = "ps1_pv3_3pi_20170110"

# this was the default prior to DM-11521. New default is 2000.
config.calibrate.deblend.maxFootprintSize=0

# Better astrometry matching
config.calibrate.astrometry.matcher.numBrightStars = 150

0 comments on commit 62fdbae

Please sign in to comment.