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

Correct difference photometry for reference flux #91

Open
wants to merge 1 commit into
base: main
Choose a base branch
from

Conversation

dmitryduev
Copy link
Collaborator

This PR implements corrections to the (difference) alert photometry if flux is present in the reference image.

Also fixes a bug in flux sign computation based on candidate.isdiffpos.

See https://github.com/dmitryduev/kowalski-archived/blob/master/kowalski/server.py#L1603

@dmitryduev
Copy link
Collaborator Author

@profjsb could you please accept the invite to K repo? I would appreciate a review of this PR from you!

Copy link
Collaborator

@profjsb profjsb left a comment

Choose a reason for hiding this comment

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

Looks good but it would be useful to also include tests for the scenarios where there is reference flux (ie. stellar host). It might also be a good idea to try out a known transient atop faint hosts and make sure that the resultant light curve is acceptable to the constituents of that science.

Would suggest adding a flag the alt data field in the SP posting for photometric points that have had the reference DC level added in (like {diff_flux: False})

@dmitryduev dmitryduev self-assigned this Mar 17, 2021
@dmitryduev
Copy link
Collaborator Author

dmitryduev commented Mar 30, 2021

@profjsb suggested: add a new column to Photometry in SP, call it is_diff (which defaults to True? yes for ZTF alert data, but otherwise I'd leave it nullable) or something. Make SP display only the is_diff data for now. Let K then post (potentially) two sets of points: one with difference photometry and the other with reference-flux-corrected photometry (if such a correction was applied).

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.

2 participants