Struct surrealml_core::storage::surml_file::SurMlFile
source · pub struct SurMlFile {
pub header: Header,
pub model: Vec<u8>,
}
Expand description
The SurMlFile
struct represents the entire surml
file.
§Fields
header
- The header of thesurml
file containing data such as key bindings for inputs and normalisers.model
- The PyTorch model in C.
Fields§
§header: Header
§model: Vec<u8>
Implementations§
source§impl SurMlFile
impl SurMlFile
sourcepub fn from_bytes(bytes: Vec<u8>) -> Result<Self, SurrealError>
pub fn from_bytes(bytes: Vec<u8>) -> Result<Self, SurrealError>
sourcepub fn from_file(file_path: &str) -> Result<Self, SurrealError>
pub fn from_file(file_path: &str) -> Result<Self, SurrealError>
Auto Trait Implementations§
impl Freeze for SurMlFile
impl RefUnwindSafe for SurMlFile
impl Send for SurMlFile
impl Sync for SurMlFile
impl Unpin for SurMlFile
impl UnwindSafe for SurMlFile
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