Actual size of a numpy array

Hello,

I have an array and I am trying to get the length or size of it. but when i try to get the length of it by len(array) the size is 2147483647. I believe this is the container size. Is there any way i can get the size of real elements filled the array?

thanks a billion for the help.

Hi,

thanks for mixing ROOT within the Python ecosystem.
stackoverflow.com/questions/1112 … umpy-array

D

Thanks for the response.

Well its my bad cause my object is ‘ROOT.PyIntBuffer’ object so its not a numpy array.

Do you have an idea how to get the actual size of this? Cause length would give me the size of the holder I think.

PyIntBuffer only know size if C++ know. Example: fix array. More example: ROOT array classes. If pointer return, no-one know size. Perhaps but maybe you? What func return int*? Can check func, then use SetSize() to set size if figure out, then len work.

-Dom