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

Fix SpanPixelIterator for pybind11

    Details

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

      Description

      For some reason the pybind11 wrappers for Span cannot use the standard pybind11::make_iterator function for its iterator. This lead Jim Bosch to find that:

      A different discussion with @pschella led me to look up the iterator category for SpanPixelIterator, and it is indeed incorrectly set to random_access_iterator rather than either input_iterator or forward_iterator (I haven't thought hard enough about this particular case to figure out which it ought to be yet). I'm not certain fixing that will fix the problem; pybind11 would have to have different implementations for different iterator categories (presumably as an optimization) for this to matter, but it could be what's going wrong. In any case, our code should be fixed, and it'd be worth seeing if that allows py::make_iterator to work properly.

      Fix this.

        Attachments

          Container Issues

            Activity

              People

              • Assignee:
                Unassigned
                Reporter:
                pschella Pim Schellart [X] (Inactive)
                Watchers:
                Jim Bosch, Krzysztof Findeisen, Pim Schellart [X] (Inactive), Tim Jenness
              • Votes:
                0 Vote for this issue
                Watchers:
                4 Start watching this issue

                Dates

                • Created:
                  Updated:

                  Summary Panel