Skip to content

Commit

Permalink
Bugfix in ingest
Browse files Browse the repository at this point in the history
  • Loading branch information
rhandberg committed Jun 10, 2021
1 parent 0e7711a commit c75a368
Showing 1 changed file with 5 additions and 1 deletion.
6 changes: 5 additions & 1 deletion run_ingest.py
Original file line number Diff line number Diff line change
Expand Up @@ -518,6 +518,10 @@ def ingest_photometry_from_inbox():
indx_sub = (tab['starid'] == -1)
indx_ref = (tab['starid'] > 0)

frd = float(np.nanmax(tab[indx_ref]['mag']))
if not np.isfinite(frd):
frd = None

phot_summary = {
'fileid_img': fileid_img,
'fileid_phot': fileid,
Expand All @@ -537,7 +541,7 @@ def ingest_photometry_from_inbox():
'seeing': float(tab.meta['seeing'].value),
'references_detected': int(np.sum(indx_ref)),
'used_for_epsf': int(np.sum(tab['used_for_epsf'])),
'faintest_reference_detected': float(np.max(tab[indx_ref]['mag'])),
'faintest_reference_detected': frd,
'pipeline_version': tab.meta['version'],
'latest_version': new_version
}
Expand Down

0 comments on commit c75a368

Please sign in to comment.