pub struct VariableShapeTensorBatchView<'a, T>{ /* private fields */ }Expand description
Column-level zero-copy view over arrow.variable_shape_tensor storage.
Implementations§
Source§impl<'a, T> VariableShapeTensorBatchView<'a, T>
impl<'a, T> VariableShapeTensorBatchView<'a, T>
Sourcepub fn nulls(&self) -> Option<&'a NullBuffer>
pub fn nulls(&self) -> Option<&'a NullBuffer>
Returns the optional outer-row validity bitmap.
Sourcepub fn dimensions(&self) -> usize
pub fn dimensions(&self) -> usize
Returns the tensor rank encoded for each row.
Sourcepub fn uniform_shape(&self) -> Option<&[Option<i32>]>
pub fn uniform_shape(&self) -> Option<&[Option<i32>]>
Returns the optional uniform-shape metadata.
Sourcepub fn data_offsets(&self) -> &[i32]
pub fn data_offsets(&self) -> &[i32]
Returns the raw Arrow list offsets for packed row data.
Sourcepub fn values(&self) -> &'a [T::Native]
pub fn values(&self) -> &'a [T::Native]
Returns the packed primitive values buffer for the whole batch.
Sourcepub fn shape_values(&self) -> &[i32]
pub fn shape_values(&self) -> &[i32]
Returns the packed shape buffer for the whole batch.
Sourcepub fn row(
&self,
index: usize,
) -> Result<VariableShapeTensorRowView<'a, T::Native>, NdarrowError>
pub fn row( &self, index: usize, ) -> Result<VariableShapeTensorRowView<'a, T::Native>, NdarrowError>
Returns a validated row view at index.
§Errors
Returns an error if index is out of bounds or the row metadata is
structurally invalid.
Sourcepub fn iter(&self) -> VariableShapeTensorIter<'a, T> ⓘ
pub fn iter(&self) -> VariableShapeTensorIter<'a, T> ⓘ
Returns the per-row iterator convenience view for this batch.
Trait Implementations§
Source§impl<T> Clone for VariableShapeTensorBatchView<'_, T>
impl<T> Clone for VariableShapeTensorBatchView<'_, T>
Source§impl<'a, T> IntoIterator for &'a VariableShapeTensorBatchView<'a, T>
impl<'a, T> IntoIterator for &'a VariableShapeTensorBatchView<'a, T>
Auto Trait Implementations§
impl<'a, T> Freeze for VariableShapeTensorBatchView<'a, T>
impl<'a, T> !RefUnwindSafe for VariableShapeTensorBatchView<'a, T>
impl<'a, T> Send for VariableShapeTensorBatchView<'a, T>
impl<'a, T> Sync for VariableShapeTensorBatchView<'a, T>
impl<'a, T> Unpin for VariableShapeTensorBatchView<'a, T>
impl<'a, T> UnsafeUnpin for VariableShapeTensorBatchView<'a, T>
impl<'a, T> !UnwindSafe for VariableShapeTensorBatchView<'a, T>
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more