Closed sarlinpe closed 5 months ago
The getter of def_readwrite returns a const reference, which makes numpy arrrays non-writeable. This makes it impossible to write:
def_readwrite
p = pycolmap.Point3D(xyz=...) ... p.xyz += 1
This PR transparently makes def_readwrite return a non-const reference for some extended classes py::class_ext_.
py::class_ext_
You are such a pybind11 guru. How did you achieve so deep techs of manipulating pybind11?
I spent too much time reading the pybind source code 😅
The getter of
def_readwrite
returns a const reference, which makes numpy arrrays non-writeable. This makes it impossible to write:This PR transparently makes
def_readwrite
return a non-const reference for some extended classespy::class_ext_
.