I recently stumbled on this kickass python extension package, Brian Hears that will solve all my coding issues. Problem is, some of the functions return memory addresses instead of expected results. For example:
>>> Parameterize(source, 256, 128)
Out[1]: <Parameterize.Parameterize at 0xda445f8>
I’ve never seen this before (and don’t know its proper name); however, the internet tells me that it’s a representation of the memory address of where my result is stored.
I’m really just interested in the result itself. How does one usually go about extracting the actual data from the address in python, or rather the numpy array that the function should (or at least i think it should) return?
Thanks in advance.
EDIT: Added name and link of package
It is returning an object. You should do
and then get your results from the object attributes/properties. You can use python’s self-documentation (
dir(p),help(p)(as pointed out in other answers + comments)) to get python to tell you what attributes/methods your object has.What it is printing out is the default string representation of your object, this is it’s type and location.