From e74cbebfa50078381fedc1bf75373e8969e8887a Mon Sep 17 00:00:00 2001 From: Jared Duffey Date: Thu, 18 Apr 2024 16:17:10 -0400 Subject: [PATCH] Changed AttributeMatrix tuple_shape to a readonly attribute * Removed AttributeMatrix __len__ since it conflicts with BaseGroup * Removed binding for base group with no function name Signed-off-by: Jared Duffey --- src/Plugins/SimplnxCore/wrapping/python/simplnxpy.cpp | 5 +---- 1 file changed, 1 insertion(+), 4 deletions(-) diff --git a/src/Plugins/SimplnxCore/wrapping/python/simplnxpy.cpp b/src/Plugins/SimplnxCore/wrapping/python/simplnxpy.cpp index bac7dee5ca..f109126baa 100644 --- a/src/Plugins/SimplnxCore/wrapping/python/simplnxpy.cpp +++ b/src/Plugins/SimplnxCore/wrapping/python/simplnxpy.cpp @@ -836,12 +836,9 @@ PYBIND11_MODULE(simplnx, mod) py::class_> attributeMatrix(mod, "AttributeMatrix"); attributeMatrix.def("resize_tuples", &AttributeMatrix::resizeTuples, "Resize the tuples with the given shape"); - attributeMatrix.def("tuple_shape", &AttributeMatrix::getShape, "Returns the Tuple dimensions of the AttributeMatrix"); - attributeMatrix.def("__len__", &AttributeMatrix::getNumTuples, "Returns the total number of tuples"); + attributeMatrix.def_property_readonly("tuple_shape", &AttributeMatrix::getShape, "Returns the Tuple dimensions of the AttributeMatrix"); attributeMatrix.def_property_readonly("size", &AttributeMatrix::getNumTuples, "Returns the total number of tuples"); - baseGroup.def("", &BaseGroup::getSize); - py::class_> iArray(mod, "IArray"); iArray.def_property_readonly("tuple_shape", &IArray::getTupleShape); iArray.def_property_readonly("component_shape", &IArray::getComponentShape);