Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

DM-47165: Update astrom/photoCal for early ComCam data. #569

Merged
merged 1 commit into from
Oct 27, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions config/comCam/calibrate.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,3 +3,10 @@
obsConfigDir = os.path.join(os.path.dirname(__file__))
config.photoRefObjLoader.load(os.path.join(obsConfigDir, "filterMap.py"))
config.connections.astromRefCat = "the_monster_20240904"

# Loosen maxOffset to account for early pointing model inaccuracy.
config.astrometry.matcher.maxOffsetPix=800
config.astromRefObjLoader.pixelMargin=800

# Loosened for early ComCam with large PSFs.
config.photoCal.match.sourceSelection.doUnresolved = False
7 changes: 7 additions & 0 deletions config/comCam/calibrateImage.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,3 +22,10 @@
config.photometry.photoCatName = "the_monster_20240904"

config.compute_summary_stats.load(os.path.join(config_dir, "computeExposureSummaryStats.py"))

# Loosen maxOffset to account for early pointing model inaccuracy.
config.astrometry.matcher.maxOffsetPix=800
config.astrometry_ref_loader.pixelMargin=800

# Loosened for early ComCam with large PSFs.
config.photometry.match.sourceSelection.doUnresolved = False
16 changes: 13 additions & 3 deletions config/comCam/filterMap.py
Original file line number Diff line number Diff line change
@@ -1,9 +1,13 @@
# Mapping of camera filter name: reference catalog filter name
# Mapping of camera band to reference catalog filter name
# This file is appropriate for the_monster


# This includes mappings for both filter and band, because photoCalTask
# switches between the two depending on whether color term corrections are
# enabled. Once that is fixed, this should be keyed by band as per RFC-976.
for source, target in [
# update left hand column with the filter names once we know them
("empty", "white"),
("empty", "monster_SynthLSST_r"),
("white", "monster_SynthLSST_r"),
("u_02", "monster_SynthLSST_u"),
("u_05", "monster_SynthLSST_u"),
("u_06", "monster_SynthLSST_u"),
Expand All @@ -14,5 +18,11 @@
("z_02", "monster_SynthLSST_z"),
("z_03", "monster_SynthLSST_z"),
("y_04", "monster_SynthLSST_y"),
("u", "monster_SynthLSST_u"),
("g", "monster_SynthLSST_g"),
("r", "monster_SynthLSST_r"),
("i", "monster_SynthLSST_i"),
("z", "monster_SynthLSST_z"),
("y", "monster_SynthLSST_y"),
]:
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think for the time being we want to have both here, or we can fix this when we fix the photoCal code which is fundamentally broken because it uses band if colorTerms are off and uses filter if colorTerms are on and that's insane. I think the RFC was about cleaning that up, but it's definitely wrong at the moment (by definition). If we want to calibrate empty/white the lines should be:

    ("empty", "monster_SynthLSST_r"),
    ("white", "monster_SynthLSST_r"),

(One for filter, the other for band).

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

And if we are never photocalibrating empty those can be left off.

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Ok thanks, I'll add all-of-the-mappings for now and I left a note with your explanation why and the RFC.

config.filterMap[source] = target
Loading