Uploaded image for project: 'Data Management'
  1. Data Management
  2. DM-13185

jointcal's astrometry fitter can fail without jointcal realizing it

    Details

      Description

      jointcal's astrometry fitter can produce a fit that is unusably bad without doing more than printing a warning. The code in question is in the function inversePolyTransfo which is defined in Gtransfo.cc. If the chi squared is too large a warning is printed but the fit is returned, and often the fit is unusably bad. Here are two examples, from test_jointcal_decam.py. A valid fit:

      jointcal INFO: Updating WCS for visit: 176837, ccd: 11
      chi2/npairs=0.149949; degree=1; chi2=374.873; npairs=2500
      chi2/npairs=0.0042684; degree=2; chi2=10.671; npairs=2500
      chi2/npairs=9.26813e-09; degree=3; chi2=2.31703e-05; npairs=2500
      Succeeded with degree=3
      

      And an unusably bad fit:

      chi2/npairs=82870.5; degree=1; chi2=2.07176e+08; npairs=2500
      chi2/npairs=56864.8; degree=2; chi2=1.42162e+08; npairs=2500
      chi2/npairs=44173.5; degree=3; chi2=1.10434e+08; npairs=2500
      chi2/npairs=41297.2; degree=4; chi2=1.03243e+08; npairs=2500
      chi2/npairs=40668.9; degree=5; chi2=1.01672e+08; npairs=2500
      chi2/npairs=40430.1; degree=6; chi2=1.01075e+08; npairs=2500
      chi2/npairs=39672.8; degree=7; chi2=9.91819e+07; npairs=2500
      chi2/npairs=39097.8; degree=8; chi2=9.77446e+07; npairs=2500
      chi2/npairs=202334; degree=9; chi2=5.05836e+08; npairs=2500
      Failed with degree=10
      

      That function should return an empty unique_ptr if the fit fails (based on the code calling it, not the documentation). The question is: can the function always return an empty pointer if the chi squared is too large, or is it possible for the fit to be "poor, but usable", in which case the necessary code will be trickier. I hope it is the former, as that makes the code easier to understand and trivial to fix.

        Attachments

          Activity

            People

            • Assignee:
              Parejkoj John Parejko
              Reporter:
              rowen Russell Owen
              Watchers:
              Dominique Boutigny, Jim Bosch, Russell Owen
            • Votes:
              0 Vote for this issue
              Watchers:
              3 Start watching this issue

              Dates

              • Created:
                Updated:

                Summary Panel