[−][src]Trait tract_hir::prelude::ModelDslConst
Extension to add constants to model that tolerates them.
Required methods
fn add_const(
&mut self,
name: impl Into<String>,
v: impl IntoArcTensor
) -> Result<OutletId, TractError>
&mut self,
name: impl Into<String>,
v: impl IntoArcTensor
) -> Result<OutletId, TractError>
Add a constant node to the graph.
Implementors
impl<F, O> ModelDslConst for ModelImpl<F, O> where
F: 'static + Fact + Clone + From<Arc<Tensor>> + Hash,
O: Debug + Display + From<Const> + AsRef<dyn Op + 'static> + AsMut<dyn Op + 'static> + Clone + Hash + 'static,
[src]
F: 'static + Fact + Clone + From<Arc<Tensor>> + Hash,
O: Debug + Display + From<Const> + AsRef<dyn Op + 'static> + AsMut<dyn Op + 'static> + Clone + Hash + 'static,
fn add_const(
&mut self,
name: impl Into<String>,
v: impl IntoArcTensor
) -> Result<OutletId, TractError>
[src]
&mut self,
name: impl Into<String>,
v: impl IntoArcTensor
) -> Result<OutletId, TractError>