pub struct ICastLayer { /* private fields */ }Expand description
ICastLayer
A cast layer in a network.
This layer casts a given tensor to the datatype specified by toType.
Implementations§
Source§impl ICastLayer
impl ICastLayer
Sourcepub fn setToType(self: Pin<&mut ICastLayer>, toType: DataType)
pub fn setToType(self: Pin<&mut ICastLayer>, toType: DataType)
Set cast layer output type.
toTypeThe DataType of the output tensor.
Set the output type of the cast layer.
Sourcepub fn getToType(self: &ICastLayer) -> DataType
pub fn getToType(self: &ICastLayer) -> DataType
Return cast layer output type.
toType parameter set during layer creation or by setToType(). The return value is the output type of the cast layer.
Trait Implementations§
Source§impl AsLayer for ICastLayer
impl AsLayer for ICastLayer
Source§impl AsLayerTyped for ICastLayer
impl AsLayerTyped for ICastLayer
Source§impl AsRef<ILayer> for ICastLayer
impl AsRef<ILayer> for ICastLayer
Source§fn as_ref(self: &ICastLayer) -> &ILayer
fn as_ref(self: &ICastLayer) -> &ILayer
Converts this type into a shared reference of the (usually inferred) input type.
Source§impl ExternType for ICastLayer
impl ExternType for ICastLayer
Source§impl MakeCppStorage for ICastLayer
impl MakeCppStorage for ICastLayer
Source§unsafe fn allocate_uninitialized_cpp_storage() -> *mut ICastLayer
unsafe fn allocate_uninitialized_cpp_storage() -> *mut ICastLayer
Allocates heap space for this type in C++ and return a pointer
to that space, but do not initialize that space (i.e. do not
yet call a constructor). Read more
Source§unsafe fn free_uninitialized_cpp_storage(arg0: *mut ICastLayer)
unsafe fn free_uninitialized_cpp_storage(arg0: *mut ICastLayer)
Frees a C++ allocation which has not yet
had a constructor called. Read more
Auto Trait Implementations§
impl !Freeze for ICastLayer
impl !RefUnwindSafe for ICastLayer
impl !Send for ICastLayer
impl !Sync for ICastLayer
impl Unpin for ICastLayer
impl UnsafeUnpin for ICastLayer
impl UnwindSafe for ICastLayer
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