[−][src]Type Definition tract_core::model::InferenceModel
type InferenceModel = Model<TensorFact>;
A model with partially types and shapes, as produced by parsing ONNX or Tensorflow graphs.
Methods
impl InferenceModel
[src]
pub fn analyse_one(&mut self, id: usize) -> TractResult<()>
[src]
Analyse one node of the graph.
pub fn analyse(&mut self, obstinate: bool) -> TractResult<()>
[src]
Analyse all nodes of the graph.
Will stop on first error unless obstinate
is true
.
pub fn missing_type_shape(&self) -> TractResult<Vec<OutletId>>
[src]
List OutletId with incomplete type information.
Will stop on first error unless obstinate
is true
.
pub fn into_typed(self) -> TractResult<TypedModel>
[src]
Attempt full analyse and conversion to TypedModel.
pub fn into_normalized(self) -> TractResult<NormalizedModel>
[src]
Attempt full analyse, decluttering and conversion to NormalizedModel.
pub fn into_optimized(self) -> TractResult<TypedModel>
[src]
Attempt full analyse, decluttering and mapping to optimized operations.
This will work even if the network can not be normalized.
Trait Implementations
impl ModelDslConst for InferenceModel
[src]
fn add_const(
&mut self,
name: impl Into<String>,
v: impl IntoArcTensor
) -> TractResult<usize>
[src]
&mut self,
name: impl Into<String>,
v: impl IntoArcTensor
) -> TractResult<usize>
fn plug_const(
&mut self,
inlet: InletId,
name: impl Into<String>,
v: impl IntoArcTensor
) -> TractResult<()>
[src]
&mut self,
inlet: InletId,
name: impl Into<String>,
v: impl IntoArcTensor
) -> TractResult<()>
impl ModelDslInfer for InferenceModel
[src]
fn add_source_default(&mut self, name: impl Into<String>) -> TractResult<usize>
[src]
fn add_node_default(
&mut self,
name: impl Into<String>,
op: impl Into<Box<dyn Op>>
) -> TractResult<usize>
[src]
&mut self,
name: impl Into<String>,
op: impl Into<Box<dyn Op>>
) -> TractResult<usize>
fn chain_default(
&mut self,
name: impl Into<String>,
op: impl Into<Box<dyn Op>>
) -> TractResult<usize>
[src]
&mut self,
name: impl Into<String>,
op: impl Into<Box<dyn Op>>
) -> TractResult<usize>