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

With pybind11 it is easy to make statisticsControl fail badly

    Details

    • Type: Bug
    • Status: To Do
    • Resolution: Unresolved
    • Fix Version/s: None
    • Component/s: afw

      Description

      The following example fails with a bad allocation error. It should fail with a type error. I have no idea what it is trying to do (e.g. which overload of statisticsStack it is trying to call):

      import lsst.afw.image as afwImage
      import lsst.afw.math as afwMath
       
      target = afwImage.MaskedImageF(10, 10)
      image0 = afwImage.MaskedImageF(10, 10)
      image1 = afwImage.MaskedImageF(10, 10)
      flags = 128  # afwMath.MEANCLIP succeeds; 128 should be a type error
      afwMath.statisticsStack(target, [image0, image1], flags)
      

        Attachments

          Issue Links

            Activity

            Hide
            rowen Russell Owen added a comment -

            This is still a problem with pybind11 2.1.0 (DM-9927 branch)

            Show
            rowen Russell Owen added a comment - This is still a problem with pybind11 2.1.0 ( DM-9927 branch)
            Hide
            rowen Russell Owen added a comment -

            This may be an instance of DM-8580, in which case the workaround given there might be applicable.

            Show
            rowen Russell Owen added a comment - This may be an instance of DM-8580 , in which case the workaround given there might be applicable.

              People

              • Assignee:
                Unassigned
                Reporter:
                rowen Russell Owen
                Watchers:
                Jim Bosch, John Swinbank, Paul Price, Pim Schellart [X] (Inactive), Russell Owen
              • Votes:
                0 Vote for this issue
                Watchers:
                5 Start watching this issue

                Dates

                • Created:
                  Updated:

                  Summary Panel