pub struct DFVariableShapeTensor { /* private fields */ }Expand description
Defines the extension type logic for the canonical arrow.variable_shape_tensor extension type.
This extension type can be used to store a tensor with
variable shape that can change for each element.
See DFExtensionType for information on DataFusion’s extension type mechanism. See also
VariableShapeTensor for the implementation of arrow-rs, which this type uses internally.
https://arrow.apache.org/docs/format/CanonicalExtensions.html#variable-shape-tensor
Implementations§
Source§impl DFVariableShapeTensor
impl DFVariableShapeTensor
Sourcepub fn try_new(
data_type: &DataType,
metadata: <VariableShapeTensor as ExtensionType>::Metadata,
) -> Result<Self>
pub fn try_new( data_type: &DataType, metadata: <VariableShapeTensor as ExtensionType>::Metadata, ) -> Result<Self>
Creates a new DFVariableShapeTensor, validating that the storage type is compatible with
the extension type.
Trait Implementations§
Source§impl Clone for DFVariableShapeTensor
impl Clone for DFVariableShapeTensor
Source§fn clone(&self) -> DFVariableShapeTensor
fn clone(&self) -> DFVariableShapeTensor
Returns a duplicate of the value. Read more
1.0.0 (const: unstable) · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl DFExtensionType for DFVariableShapeTensor
impl DFExtensionType for DFVariableShapeTensor
Source§fn storage_type(&self) -> DataType
fn storage_type(&self) -> DataType
Returns the underlying storage type.
Source§fn serialize_metadata(&self) -> Option<String>
fn serialize_metadata(&self) -> Option<String>
Returns the serialized metadata.
Source§fn create_array_formatter<'fmt>(
&self,
_array: &'fmt dyn Array,
_options: &FormatOptions<'fmt>,
) -> Result<Option<ArrayFormatter<'fmt>>>
fn create_array_formatter<'fmt>( &self, _array: &'fmt dyn Array, _options: &FormatOptions<'fmt>, ) -> Result<Option<ArrayFormatter<'fmt>>>
Returns an
ArrayFormatter that can format values of this type. Read moreAuto Trait Implementations§
impl Freeze for DFVariableShapeTensor
impl RefUnwindSafe for DFVariableShapeTensor
impl Send for DFVariableShapeTensor
impl Sync for DFVariableShapeTensor
impl Unpin for DFVariableShapeTensor
impl UnsafeUnpin for DFVariableShapeTensor
impl UnwindSafe for DFVariableShapeTensor
Blanket Implementations§
impl<T> Allocation for T
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