Uploaded image for project: 'DRP 2-D Pipeline'
  1. DRP 2-D Pipeline
  2. PIPE2D-1515

subtractSky1d mishandles a length mismatch between pfsArm and pfsConfig

    XMLWordPrintable

    Details

    • Type: Bug
    • Status: Open (View Workflow)
    • Priority: Normal
    • Resolution: Unresolved
    • Affects Version/s: None
    • Fix Version/s: None
    • Component/s: None
    • Labels:

      Description

      After

      from pfs.drp.stella.subtractSky1d import subtractSky1d
      
      fiberId = 1443
      dataId=dict(visit=110478, spectrograph=3, arm='r')
      
      pfsConfig = butler.get("pfsConfig", dataId)
      
      pfsArm = butler.get("pfsArm", dataId)
      sky1d = butler.get("sky1d", dataId)
      
      pfsConfig = pfsConfig.select(fiberId=fiberId)
      

      a subtractSky1d(pfsArm, pfsConfig, sky1d) call does the wrong thing. Looking at the code, the first line is

      sky = sky1d(spectra.wavelength, pfsConfig.select(fiberId=spectra.fiberId))
      

      which returns a (600, 4176) array with only the first row set so the fiberId in the pfsConfig is not (in general) sky-subtracted.

      The correct behaviour isn't obvious, an exception on the mismatch would be reasonable, or only sky subtract the fibres in the pfsConfig.

        Attachments

          Activity

            People

            • Assignee:
              Unassigned
              Reporter:
              rhl rhl
            • Votes:
              0 Vote for this issue
              Watchers:
              1 Start watching this issue

              Dates

              • Created:
                Updated: