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

meas_astrom update for pytest and SIP test can fail if tests run all in one process

    Details

    • Type: Bug
    • Status: Done
    • Resolution: Done
    • Fix Version/s: None
    • Component/s: meas_astrom
    • Labels:
      None
    • Templates:
    • Team:
      Alert Production

      Description

      When running the meas_astrom test suite with nose the following error occurs:

      ======================================================================
      ERROR: testBigXy0 (createWcsWithSip.CreateWcsWithSipCase)
      ----------------------------------------------------------------------
      Traceback (most recent call last):
        File "/Users/timj/work/lsstsw/src/meas_astrom/tests/createWcsWithSip.py", line 81, in testBigXy0
          res = self.astrom.determineWcs2(cat, bbox=bbox)
        File "/Users/timj/work/lsstsw/src/meas_astrom/python/lsst/meas/astrom/anetBasicAstrometry.py", line 436, in determineWcs2
          wcs,qa = self.getBlindWcsSolution(sourceCat, **kwargs)
        File "/Users/timj/work/lsstsw/src/meas_astrom/python/lsst/meas/astrom/anetBasicAstrometry.py", line 524, in getBlindWcsSolution
          raise RuntimeError("Unable to match sources with catalog.")
      RuntimeError: Unable to match sources with catalog.
      -------------------- >> begin captured stdout << ---------------------
      Catalog size 186
       
      --------------------- >> end captured stdout << ----------------------
       
      ======================================================================
      ERROR: testLinearXDistort (createWcsWithSip.CreateWcsWithSipCase)
      ----------------------------------------------------------------------
      Traceback (most recent call last):
        File "/Users/timj/work/lsstsw/src/meas_astrom/tests/createWcsWithSip.py", line 98, in testLinearXDistort
          self.singleTestInstance(self.filename, distort.linearXDistort)
        File "/Users/timj/work/lsstsw/src/meas_astrom/tests/createWcsWithSip.py", line 109, in singleTestInstance
          cat = self.loadCatalogue(self.filename)
        File "/Users/timj/work/lsstsw/src/meas_astrom/tests/createWcsWithSip.py", line 165, in loadCatalogue
          res = self.astrom.determineWcs2(cat, bbox=bbox)
        File "/Users/timj/work/lsstsw/src/meas_astrom/python/lsst/meas/astrom/anetBasicAstrometry.py", line 436, in determineWcs2
          wcs,qa = self.getBlindWcsSolution(sourceCat, **kwargs)
        File "/Users/timj/work/lsstsw/src/meas_astrom/python/lsst/meas/astrom/anetBasicAstrometry.py", line 524, in getBlindWcsSolution
          raise RuntimeError("Unable to match sources with catalog.")
      RuntimeError: Unable to match sources with catalog.
      -------------------- >> begin captured stdout << ---------------------
      linearXDistort
       
      --------------------- >> end captured stdout << ----------------------
       
      ======================================================================
      ERROR: testLinearYDistort (createWcsWithSip.CreateWcsWithSipCase)
      ----------------------------------------------------------------------
      Traceback (most recent call last):
        File "/Users/timj/work/lsstsw/src/meas_astrom/tests/createWcsWithSip.py", line 102, in testLinearYDistort
          self.singleTestInstance(self.filename, distort.linearYDistort)
        File "/Users/timj/work/lsstsw/src/meas_astrom/tests/createWcsWithSip.py", line 109, in singleTestInstance
          cat = self.loadCatalogue(self.filename)
        File "/Users/timj/work/lsstsw/src/meas_astrom/tests/createWcsWithSip.py", line 165, in loadCatalogue
          res = self.astrom.determineWcs2(cat, bbox=bbox)
        File "/Users/timj/work/lsstsw/src/meas_astrom/python/lsst/meas/astrom/anetBasicAstrometry.py", line 436, in determineWcs2
          wcs,qa = self.getBlindWcsSolution(sourceCat, **kwargs)
        File "/Users/timj/work/lsstsw/src/meas_astrom/python/lsst/meas/astrom/anetBasicAstrometry.py", line 524, in getBlindWcsSolution
          raise RuntimeError("Unable to match sources with catalog.")
      RuntimeError: Unable to match sources with catalog.
      -------------------- >> begin captured stdout << ---------------------
      linearYDistort
       
      --------------------- >> end captured stdout << ----------------------
       
      ======================================================================
      ERROR: testQuadraticDistort (createWcsWithSip.CreateWcsWithSipCase)
      ----------------------------------------------------------------------
      Traceback (most recent call last):
        File "/Users/timj/work/lsstsw/src/meas_astrom/tests/createWcsWithSip.py", line 106, in testQuadraticDistort
          self.singleTestInstance(self.filename, distort.linearYDistort)
        File "/Users/timj/work/lsstsw/src/meas_astrom/tests/createWcsWithSip.py", line 109, in singleTestInstance
          cat = self.loadCatalogue(self.filename)
        File "/Users/timj/work/lsstsw/src/meas_astrom/tests/createWcsWithSip.py", line 165, in loadCatalogue
          res = self.astrom.determineWcs2(cat, bbox=bbox)
        File "/Users/timj/work/lsstsw/src/meas_astrom/python/lsst/meas/astrom/anetBasicAstrometry.py", line 436, in determineWcs2
          wcs,qa = self.getBlindWcsSolution(sourceCat, **kwargs)
        File "/Users/timj/work/lsstsw/src/meas_astrom/python/lsst/meas/astrom/anetBasicAstrometry.py", line 524, in getBlindWcsSolution
          raise RuntimeError("Unable to match sources with catalog.")
      RuntimeError: Unable to match sources with catalog.
      -------------------- >> begin captured stdout << ---------------------
      linearQuadraticDistort
       
      --------------------- >> end captured stdout << ----------------------
       
      ----------------------------------------------------------------------
      Ran 77 tests in 96.588s
       
      FAILED (SKIP=10, errors=4)
      

      (This requires the corresponding patches from the DM-3901 ticket branch to have been applied).

      Running in subprocess with:

      nosetests --processes=4 --process-timeout=240 tests/*.py
      

      leads to all tests passing. As does running just the createWcsWithSip.py test on its own with nose.

        Attachments

          Container Issues

            Issue Links

              Activity

                People

                • Assignee:
                  rowen Russell Owen
                  Reporter:
                  tjenness Tim Jenness
                  Reviewers:
                  Fred Moolekamp
                  Watchers:
                  Fred Moolekamp, John Swinbank, Lauren MacArthur, Pim Schellart [X] (Inactive), Russell Owen, Simon Krughoff, Tim Jenness
                • Votes:
                  0 Vote for this issue
                  Watchers:
                  7 Start watching this issue

                  Dates

                  • Created:
                    Updated:
                    Resolved:

                    Summary Panel