pub struct Onnx {}Expand description
Parses ONNX protobuf models into a teeny-core [Graph].
Implementations§
Source§impl Onnx
impl Onnx
Sourcepub fn from_path(path: impl AsRef<Path>) -> Result<Graph>
pub fn from_path(path: impl AsRef<Path>) -> Result<Graph>
Reads and parses the .onnx file at path.
Sourcepub fn from_reader(reader: &mut impl Read) -> Result<Graph>
pub fn from_reader(reader: &mut impl Read) -> Result<Graph>
Parses an ONNX model (ModelProto, protobuf binary format) from reader into a Graph.
Errors if the bytes aren’t valid ONNX protobuf, the model has no graph, or the graph uses an op this crate doesn’t support yet.
Auto Trait Implementations§
impl Freeze for Onnx
impl RefUnwindSafe for Onnx
impl Send for Onnx
impl Sync for Onnx
impl Unpin for Onnx
impl UnsafeUnpin for Onnx
impl UnwindSafe for Onnx
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