pub fn as_slice_mut<D: Datum>(&mut self) -> TractResult<&mut [D]> {
        let datum_size = ::std::mem::size_of::<D>();
        unsafe {
            Ok(std::slice::from_raw_parts_mut::<D>(
                self.as_ptr_mut()?,
                self.data.len() / datum_size,
            ))
        }
    }
/// Access the data as a mutable slice.
Access the data as a mutable slice.
Access the data as a mutable slice .
pub fn as_slice_mut<D: Datum>(&mut self) -> TractResult<&mut [D]> {
        let datum_size = ::std::mem::size_of::<D>();
        unsafe {
            Ok(std::slice::from_raw_parts_mut::<D>(
                self.as_ptr_mut()?,
                self.data.len() / datum_size,
            ))
        }
    }
pub fn as_slice_mut < D : Datum > ( & mut self ) -> TractResult < & mut [ D ] > { let datum_size = :: std :: mem :: size_of :: < D > ( ) ; unsafe { Ok ( std :: slice :: from_raw_parts_mut :: < D > ( self . as_ptr_mut ( ) ? , self . data . len ( ) / datum_size , ) ) } }
Access the data as a mutable slice.
Access the data as a mutable slice .
&mut self
&mut self