On Saturday, January 6, 2018 at 12:02:18 AM UTC, Rob Gaddi wrote:
> I'd like to create a native Python object that exposes the buffer
> protocol. Basically, something with a ._data member which is a
> bytearray that I can still readinto, make directly into a numpy array, etc.
>
> I can do it by
On 01/05/2018 04:27 PM, Ben Finney wrote:
Rob Gaddi writes:
I'd like to create a native Python object that exposes the buffer
protocol. Basically, something with a ._data member which is a
bytearray that I can still readinto, make directly into a numpy array,
etc.
The “etc.” seems pretty im
Rob Gaddi writes:
> I'd like to create a native Python object that exposes the buffer
> protocol. Basically, something with a ._data member which is a
> bytearray that I can still readinto, make directly into a numpy array,
> etc.
The “etc.” seems pretty important, there. You want the behaviour
On Saturday, January 6, 2018 at 12:02:18 AM UTC, Rob Gaddi wrote:
> I'd like to create a native Python object that exposes the buffer
> protocol. Basically, something with a ._data member which is a
> bytearray that I can still readinto, make directly into a numpy array, etc.
>
> I can do it by
I'd like to create a native Python object that exposes the buffer
protocol. Basically, something with a ._data member which is a
bytearray that I can still readinto, make directly into a numpy array, etc.
I can do it by inheriting the entire thing from bytearray directly, but
that gives me a