A RetroSearch Logo

Home - News ( United States | United Kingdom | Italy | Germany ) - Football scores

Search Query:

Showing content from https://arrow.apache.org/docs/python/generated/pyarrow.Buffer.html below:

pyarrow.Buffer — Apache Arrow v20.0.0

pyarrow.Buffer#
class pyarrow.Buffer#

Bases: _Weakrefable

The base class for all Arrow buffers.

A buffer represents a contiguous memory area. Many buffers will own their memory, though not all of them do.

__init__(*args, **kwargs)#

Methods

Attributes

address#

The buffer’s address, as an integer.

The returned address may point to CPU or device memory. Use is_cpu() to disambiguate.

device#

The device where the buffer resides.

Returns:
Device
device_type#

The device type where the buffer resides.

Returns:
DeviceAllocationType
equals(self, Buffer other)#

Determine if two buffers contain exactly the same data.

Parameters:
otherBuffer
Returns:
are_equalbool

True if buffer contents and size are equal

hex(self)#

Compute hexadecimal representation of the buffer.

Returns:
: bytes
is_cpu#

Whether the buffer is CPU-accessible.

is_mutable#

Whether the buffer is mutable.

memory_manager#

The memory manager associated with the buffer.

Returns:
MemoryManager
parent#
size#

The buffer size in bytes.

slice(self, offset=0, length=None)#

Slice this buffer. Memory is not copied.

You can also use the Python slice notation buffer[start:stop].

Parameters:
offsetint, default 0

Offset from start of buffer to slice.

lengthint, default None

Length of slice (default is until end of Buffer starting from offset).

Returns:
slicedBuffer

A logical view over this buffer.

to_pybytes(self)#

Return this buffer as a Python bytes object. Memory is copied.


RetroSearch is an open source project built by @garambo | Open a GitHub Issue

Search and Browse the WWW like it's 1997 | Search results from DuckDuckGo

HTML: 3.2 | Encoding: UTF-8 | Version: 0.7.4