pub struct CastDescriptor {
pub numel: i32,
pub input_element: ElementKind,
pub output_element: ElementKind,
}Expand description
Descriptor for a dtype cast.
numel is the total number of elements (both input and output have
the same number — cast doesn’t change shape). input_element must
match TIn::KIND and output_element must match TOut::KIND at
select time.
Fields§
§numel: i32Number of elements in both input and output.
input_element: ElementKindInput element type.
output_element: ElementKindOutput element type.
Trait Implementations§
Source§impl Clone for CastDescriptor
impl Clone for CastDescriptor
Source§fn clone(&self) -> CastDescriptor
fn clone(&self) -> CastDescriptor
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 moreimpl Copy for CastDescriptor
Auto Trait Implementations§
impl Freeze for CastDescriptor
impl RefUnwindSafe for CastDescriptor
impl Send for CastDescriptor
impl Sync for CastDescriptor
impl Unpin for CastDescriptor
impl UnsafeUnpin for CastDescriptor
impl UnwindSafe for CastDescriptor
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