# Photometric calibration uses a column "flux" not the specified filter unless a colour term is active

XMLWordPrintable

## Details

• Type: Story
• Status: Done
• Resolution: Done
• Fix Version/s: None
• Component/s:
• Labels:
None
• Story Points:
1
• Sprint:
DRP X16-2, DRP X16-3
• Team:
Data Release Production

## Description

The photometric calibration code uses a field "flux" in the reference catalog to impose a magnitude limit. If a colour term is specified, it uses the primary and secondary filters to calculate the reference magnitude, but if there is no colour term it uses the column labelled "flux" and ignores the filtername.

Please change the code so that "flux" is ignored, and the flux associated with filterName is used.

## Activity

Hide
John Swinbank added a comment - - edited

I think this was resolved as part of DM-1576. See (what I surmise is) the relevant code here, and the changes I have been able to make as part of DM-4125 (push coming up in a moment).

Can you please confirm if this resolves the issue for you?

Show
John Swinbank added a comment - - edited I think this was resolved as part of DM-1576 . See (what I surmise is) the relevant code here , and the changes I have been able to make as part of DM-4125 (push coming up in a moment). Can you please confirm if this resolves the issue for you?
Hide
John Swinbank added a comment -

Robert Lupton – I propose to close this issue as Done. Do you object?

Show
John Swinbank added a comment - Robert Lupton – I propose to close this issue as Done. Do you object?
Hide
Robert Lupton added a comment -

Not proven. If you're confident, sure – but I have no independent evidence for or against the accused.

Show
Robert Lupton added a comment - Not proven. If you're confident, sure – but I have no independent evidence for or against the accused.
Hide
Lauren MacArthur added a comment -

I believe I have confirmed John Swinbank's assertion above that this is no longer an issue by doing the following.

Run processCcd.py using --config calibrate.photoCal.applyColorTerms=False calibrate.photoCal.colorterms.data={} and adding some print statements here:

I get the following:

 log from processCcd.py processCcd.calibrate.photoCal: Not applying color terms because config.applyColorTerms is False 

 Print statements in photoCal.py filtername = i fluxFieldList = ['i_flux'] len(self.config.colorterms.data) = 0 self.config.colorterms.data = {} 

Thus, even though no color term is supplied nor applied, the appropriate flux field is used.
Is this satisfactory proof?

Show
Lauren MacArthur added a comment - I believe I have confirmed John Swinbank 's assertion above that this is no longer an issue by doing the following. Run processCcd.py using --config calibrate.photoCal.applyColorTerms=False calibrate.photoCal.colorterms.data={} and adding some print statements here: https://github.com/lsst/pipe_tasks/blob/master/python/lsst/pipe/tasks/photoCal.py#L526 I get the following: log from processCcd.py processCcd.calibrate.photoCal: Not applying color terms because config.applyColorTerms is False Print statements in photoCal.py filtername = i fluxFieldList = ['i_flux'] len(self.config.colorterms.data) = 0 self.config.colorterms.data = {} Thus, even though no color term is supplied nor applied, the appropriate flux field is used. Is this satisfactory proof?
Hide
Lauren MacArthur added a comment -

John Swinbank, would you mind giving this a look (it appears Robert Lupton is too busy)?

Show
Lauren MacArthur added a comment - John Swinbank , would you mind giving this a look (it appears Robert Lupton is too busy)?
Hide
John Swinbank added a comment -

I pronounce this reviewed. And done.

Show
John Swinbank added a comment - I pronounce this reviewed. And done.
Hide
John Swinbank added a comment -

Thanks Lauren!

Show
John Swinbank added a comment - Thanks Lauren!

## People

• Assignee:
Lauren MacArthur
Reporter:
Robert Lupton
Reviewers:
John Swinbank
Watchers:
John Swinbank, Lauren MacArthur, Robert Lupton