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-39858: Integrate new CalibrateImageTask with AP pipeline #147

Merged
merged 2 commits into from Aug 21, 2023

Conversation

parejkoj
Copy link
Contributor

No description provided.

Copy link
Member

@kfindeisen kfindeisen left a comment

Choose a reason for hiding this comment

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

The DM-31047 hacks appear to have been cargo-culted as-is, despite the fact that, as a task introduced after RFC-775, calibrateImage shouldn't have any DRP bias in its obs_ configs. Then again, I can't find any configs for it in obs_lsst... what's going on?

Would it be better to put all the possibilities in the same ingredients files, and then have separate XCalibrateImage.yaml for the instrument-specific ones? Suggestions, please!

Sorry, but even after looking at the changes, I still don't understand this question. What are the "possibilities" you mention?

Copy link
Member

Choose a reason for hiding this comment

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

Does this really belong in ap_verify, and not in obs_lsst? Since this is a new task, there's no reason we can't make the config RFC-775-compliant from the beginning.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Great, that's just what I was hoping to hear! I wasn't sure if we wanted to fix everything at once, or if we could migrate things one at a time. I'll happily move it over to obs_lsst (because it really is the generic settings you always want for imsim).

pipelines/LsstCamImSim/ApPipeCalibrateImage.yaml Outdated Show resolved Hide resolved
pipelines/LsstCamImSim/ProcessCcdCalibrateImage.yaml Outdated Show resolved Hide resolved
pipelines/_ingredients/ApPipeCalibrateImage.yaml Outdated Show resolved Hide resolved
# blow away all the configs that are set in this file.
# To update a pipeline config prior to DM-35504, you MUST put it in either,
# e.g., $AP_PIPE_DIR/config/$CAMERA/someTask.py, or in a camera-specific,
# pipeline, e.g., $AP_PIPE_DIR/pipelines/$CAMERA/ApTemplate.yaml.
Copy link
Member

Choose a reason for hiding this comment

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

Suggested change
# pipeline, e.g., $AP_PIPE_DIR/pipelines/$CAMERA/ApTemplate.yaml.
# pipeline, e.g., $AP_PIPE_DIR/pipelines/$CAMERA/ApTemplateCalibrateImage.yaml.

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Just to check: this warning re: DM-35504 still applies here? If we're adding a CalibrateImage override file to obs_lsst/config/imsim (which we want, because they're very specific to imsim), does follow the spirit comment given here, go against it, or is it orthogonal to this?

Copy link
Member

Choose a reason for hiding this comment

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

Yes, it still applies. The comment is about the pipeline as a whole, and we still have to hack around some overrides for e.g. makeWarp.

pipelines/_ingredients/ApTemplateCalibrateImage.yaml Outdated Show resolved Hide resolved
pipelines/_ingredients/ProcessCcdCalibrateImage.yaml Outdated Show resolved Hide resolved
@kfindeisen
Copy link
Member

Also, I just noticed that the commit message mentions ap_verify.py, which is not an ap_pipe thing. 😉

@parejkoj
Copy link
Contributor Author

Would it be better to put all the possibilities in the same ingredients files, and then have separate XCalibrateImage.yaml for the instrument-specific ones? Suggestions, please!

Sorry, but even after looking at the changes, I still don't understand this question. What are the "possibilities" you mention?

For example, I could include this line in the ingredients file:

  calibrateImage: lsst.pipe.tasks.calibrateImage.CalibrateImageTask

and then in the old files exclude it while the new files exclude characterizeImage/calibrate. I don't know that that actually gains us anything, since the ProcessCcd file isn't very complicated to begin with, but it was another possible approach I considered.

@parejkoj
Copy link
Contributor Author

Also, I just noticed that the commit message mentions ap_verify.py, which is not an ap_pipe thing. 😉

I wrote it that way because ap_verify is the way we're going to start testing the new task. I can reword it to take out that reference?

@kfindeisen
Copy link
Member

kfindeisen commented Aug 15, 2023

For example, I could include this line in the ingredients file:

calibrateImage: lsst.pipe.tasks.calibrateImage.CalibrateImageTask

and then in the old files exclude it while the new files exclude characterizeImage/calibrate. I don't know that that actually gains us anything, since the ProcessCcd file isn't very complicated to begin with, but it was another possible approach I considered.

Got it. No, I'd rather not; part of my argument on DM-40210 was that the _ingredients pipeline is the first reference for "what does this pipeline do, anyway?", and having mutually exclusive tasks there would just make things confusing again.

These ISR overrides were either already set in obs_lsst (the two
booleans), or have been set there (`connections.newBFKernel`) on this
ticket.
@parejkoj parejkoj force-pushed the tickets/DM-39858 branch 4 times, most recently from 9da947d to 44f205d Compare August 16, 2023 00:54
Copy link
Member

@kfindeisen kfindeisen left a comment

Choose a reason for hiding this comment

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

Looks much better; main outstanding request is for forward-compatibility with future ProcessCcd.yaml.

pipelines/DarkEnergyCamera/ApPipeCalibrateImage.yaml Outdated Show resolved Hide resolved
@@ -40,6 +40,8 @@ tasks:
assembleStaticSkyModel.doSelectVisits: True
connections.outputCoaddName: parameters.coaddName

# TODO DM-40389: Remove this entire block once we are using calibrateImage in
# the base _ingredients/ApTemplate.yaml.
Copy link
Member

Choose a reason for hiding this comment

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

This block is redefining the singleFrameAp subset after the single-frame tasks are spliced in from HyperSuprimeCam/ProcessCcd.yaml. Why would it become obsolete once that's implemented using calibrateImage?

Copy link
Contributor Author

Choose a reason for hiding this comment

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

Because those single frame tasks in HyperSuprimeCam/ProcessCcd.yaml will be gone: they're overriding tasks that will no longer exist.

pipelines/HyperSuprimeCam/ProcessCcd.yaml Outdated Show resolved Hide resolved
This setup lets us run both the old (characterizeImage+calibrate) and new
(calibrateImage) pipelines as separate runs, so that we can directly compare
the new and old versions.
@parejkoj parejkoj merged commit 06c608b into main Aug 21, 2023
2 checks passed
@parejkoj parejkoj deleted the tickets/DM-39858 branch August 21, 2023 23:39
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

None yet

2 participants