MCPcopy Create free account
hub / github.com/apache/arrow / from_buffer

Method from_buffer

cpp/gdb_arrow.py:769–774  ·  view source on GitHub ↗
(cls, buf, offset, length)

Source from the content-addressed store, hash-verified

767
768 @classmethod
769 def from_buffer(cls, buf, offset, length):
770 assert isinstance(buf, Buffer)
771 byte_offset, bit_offset = divmod(offset, 8)
772 byte_length = math.ceil(length + offset / 8) - byte_offset
773 return cls(buf.bytes_view(byte_offset, byte_length),
774 bit_offset, length)
775
776
777class MappedView(Sequence):

Callers 5

test_non_cpu_bufferFunction · 0.45
viewMethod · 0.45
from_bufferMethod · 0.45
_null_bitmapMethod · 0.45

Calls 1

bytes_viewMethod · 0.80

Tested by 2

test_non_cpu_bufferFunction · 0.36