You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Sometimes a negative flux is saved in the database as aperphot result. This gives an error downstream as in:
2023-10-10 20:42:11 - iop4lib.telescopes.cahat220 [cahat220.py:343] - DEBUG - Computing relative polarimetry for <AstroSource S4 0954+65 4>. 2023-10-10 20:42:11 - iop4lib.telescopes.cahat220 [cahat220.py:417] - WARNING - polarimetry_group=[ReducedFit.objects.get(id=52269), ReducedFit.objects.get(id=52272), ReducedFit.objects.get(id=52271), ReducedFit.objects.get(id=52270)]: negative flux mean encountered while relative polarimetry for astrosource=AstroSource.objects.get(name='S4 0954+65 4') ??!! It will be nan, but maybe we should look into th
is...
Traceback (most recent call last):
File "/home/vhega/miniconda3/envs/iop4/bin/iop4", line 8, in <module>
sys.exit(main())
File "/home/vhega/iop4/iop4lib/iop4.py", line 195, in main
process_epochs(epochs_to_process, args.force_rebuild, check_remote_list=~args.skip_remote_file_list)
File "/home/vhega/iop4/iop4lib/iop4.py", line 65, in process_epochs
epoch.compute_relative_polarimetry()
File "/home/vhega/iop4/iop4lib/db/epoch.py", line 674, in compute_relative_polarimetry
return list(map(f, clusters_L))
File "/home/vhega/iop4/iop4lib/db/epoch.py", line 672, in <lambda>
f = lambda x: Telescope.by_name(self.telescope).compute_relative_polarimetry(x, *args, **kwargs)
File "/home/vhega/iop4/iop4lib/telescopes/cahat220.py", line 419, in compute_relative_polarimetry
mag_inst = -2.5 * math.log10(flux_mean)
ValueError: math domain error
(iop4) vhega@quasar:~$
Also, this error is not catched anywhere and breaks the pipeline execution.
iop4 was stopping when flux_counts < 0 encountered
decided i is better to continue after the error so no good data is lost
changed math.log10 to np.log10 so it continues, returning nans instead of errors
debugging still necessary to be sure about the origin of these errors
we keep issue #24 open for this reason
Sometimes a negative flux is saved in the database as aperphot result. This gives an error downstream as in:
Also, this error is not catched anywhere and breaks the pipeline execution.
Ocurrences (IOP4 version main @ d9d65f2).
CAHA-T220/2023-10-09/caf-20231010-03:36:55-sci-agui.fit
.The text was updated successfully, but these errors were encountered: