[−][src]Struct tract_hir::ops::array::Pad
Fields
pads: Vec<(usize, usize)>mode: PadModeImplementations
impl Pad[src]
Trait Implementations
impl Clone for Pad[src]
impl Debug for Pad[src]
impl Default for Pad[src]
impl DynHash for Pad
impl EvalOp for Pad[src]
pub fn is_stateless(&self) -> bool[src]
pub fn eval(
&self,
inputs: SmallVec<[Arc<Tensor>; 4]>
) -> Result<SmallVec<[Arc<Tensor>; 4]>, Error>[src]
&self,
inputs: SmallVec<[Arc<Tensor>; 4]>
) -> Result<SmallVec<[Arc<Tensor>; 4]>, Error>
fn state(
&self,
session: &mut SessionState,
node_id: usize
) -> Result<Option<Box<dyn OpState + 'static>>, Error>[src]
&self,
session: &mut SessionState,
node_id: usize
) -> Result<Option<Box<dyn OpState + 'static>>, Error>
impl Hash for Pad[src]
pub fn hash<__H>(&self, state: &mut __H) where
__H: Hasher, [src]
__H: Hasher,
fn hash_slice<H>(data: &[Self], state: &mut H) where
H: Hasher, 1.3.0[src]
H: Hasher,
impl InferenceRulesOp for Pad[src]
fn rules<'r, 'p: 'r, 's: 'r>(
&'s self,
s: &mut Solver<'r>,
inputs: &'p [TensorProxy],
outputs: &'p [TensorProxy]
) -> InferenceResult[src]
&'s self,
s: &mut Solver<'r>,
inputs: &'p [TensorProxy],
outputs: &'p [TensorProxy]
) -> InferenceResult
fn as_op(&self) -> &dyn Op[src]
fn as_op_mut(&mut self) -> &mut dyn Op[src]
fn to_typed(
&self,
_source: &InferenceModel,
node: &InferenceNode,
target: &mut TypedModel,
mapping: &HashMap<OutletId, OutletId>
) -> TractResult<TVec<OutletId>>[src]
&self,
_source: &InferenceModel,
node: &InferenceNode,
target: &mut TypedModel,
mapping: &HashMap<OutletId, OutletId>
) -> TractResult<TVec<OutletId>>
fn nboutputs(&self) -> TractResult<usize>[src]
fn incorporate(
&self,
model: &InferenceModel,
node: &InferenceNode
) -> TractResult<Option<InferenceModelPatch>>[src]
&self,
model: &InferenceModel,
node: &InferenceNode
) -> TractResult<Option<InferenceModelPatch>>
impl Op for Pad[src]
pub fn name(&self) -> Cow<'_, str>[src]
pub fn info(&self) -> Result<Vec<String>, Error>[src]
pub fn op_families(&self) -> &'static [&'static str]ⓘ[src]
pub fn as_typed(&self) -> Option<&(dyn TypedOp + 'static)>[src]
fn validation(&self) -> Validation[src]
fn same_as(&self, _other: &(dyn Op + 'static)) -> bool[src]
impl TypedOp for Pad[src]
pub fn as_op(&self) -> &(dyn Op + 'static)[src]
pub fn as_op_mut(&mut self) -> &mut (dyn Op + 'static)[src]
pub fn output_facts(
&self,
inputs: &[&TypedFact]
) -> Result<SmallVec<[TypedFact; 4]>, Error>[src]
&self,
inputs: &[&TypedFact]
) -> Result<SmallVec<[TypedFact; 4]>, Error>
pub fn declutter(
&self,
model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>
) -> Result<Option<ModelPatch<TypedFact, Box<dyn TypedOp + 'static>>>, Error>[src]
&self,
model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>
) -> Result<Option<ModelPatch<TypedFact, Box<dyn TypedOp + 'static>>>, Error>
fn invariants(
&self,
model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>
) -> Result<Invariants, Error>[src]
&self,
model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>
) -> Result<Invariants, Error>
fn fuse(
&self,
_model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
_node: &Node<TypedFact, Box<dyn TypedOp + 'static>>
) -> Result<Option<ModelPatch<TypedFact, Box<dyn TypedOp + 'static>>>, Error>[src]
&self,
_model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
_node: &Node<TypedFact, Box<dyn TypedOp + 'static>>
) -> Result<Option<ModelPatch<TypedFact, Box<dyn TypedOp + 'static>>>, Error>
fn cost(
&self,
_inputs: &[&TypedFact]
) -> Result<SmallVec<[(Cost, TDim); 4]>, Error>[src]
&self,
_inputs: &[&TypedFact]
) -> Result<SmallVec<[(Cost, TDim); 4]>, Error>
fn suggested_axis_changes(
&self
) -> Result<SmallVec<[(InOut, AxisOp); 4]>, Error>[src]
&self
) -> Result<SmallVec<[(InOut, AxisOp); 4]>, Error>
fn change_axes(
&self,
model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>,
io: InOut,
change: &AxisOp
) -> Result<Option<AxisChangeConsequence>, Error>[src]
&self,
model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>,
io: InOut,
change: &AxisOp
) -> Result<Option<AxisChangeConsequence>, Error>
fn slice_output(
&self,
model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>,
patch: &mut ModelPatch<TypedFact, Box<dyn TypedOp + 'static>>,
output_slot: usize,
axis: usize,
start: usize,
end: usize
) -> Result<Option<OutletId>, Error>[src]
&self,
model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>,
patch: &mut ModelPatch<TypedFact, Box<dyn TypedOp + 'static>>,
output_slot: usize,
axis: usize,
start: usize,
end: usize
) -> Result<Option<OutletId>, Error>
fn quantize(
&self,
model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>,
dt: DatumType,
scale: f32,
zero_point: i32
) -> Result<Option<Box<dyn TypedOp + 'static>>, Error>[src]
&self,
model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>,
dt: DatumType,
scale: f32,
zero_point: i32
) -> Result<Option<Box<dyn TypedOp + 'static>>, Error>
fn concretize_dims(
&self,
source: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>,
target: &mut Graph<TypedFact, Box<dyn TypedOp + 'static>>,
mapping: &HashMap<OutletId, OutletId, RandomState>,
values: &SymbolValues
) -> Result<SmallVec<[OutletId; 4]>, Error>[src]
&self,
source: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>,
target: &mut Graph<TypedFact, Box<dyn TypedOp + 'static>>,
mapping: &HashMap<OutletId, OutletId, RandomState>,
values: &SymbolValues
) -> Result<SmallVec<[OutletId; 4]>, Error>
fn codegen(
&self,
model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>
) -> Result<Option<ModelPatch<TypedFact, Box<dyn TypedOp + 'static>>>, Error>[src]
&self,
model: &Graph<TypedFact, Box<dyn TypedOp + 'static>>,
node: &Node<TypedFact, Box<dyn TypedOp + 'static>>
) -> Result<Option<ModelPatch<TypedFact, Box<dyn TypedOp + 'static>>>, Error>
fn nested_model_multipliers(
&self,
inputs: &[&TypedFact]
) -> Vec<(Cow<'_, str>, f64)>ⓘ[src]
&self,
inputs: &[&TypedFact]
) -> Vec<(Cow<'_, str>, f64)>ⓘ
Auto Trait Implementations
impl RefUnwindSafe for Pad
impl Send for Pad
impl Sync for Pad
impl Unpin for Pad
impl UnwindSafe for Pad
Blanket Implementations
impl<T> Any for T where
T: 'static + ?Sized, [src]
T: 'static + ?Sized,
impl<T> Borrow<T> for T where
T: ?Sized, [src]
T: ?Sized,
pub fn borrow(&self) -> &TⓘNotable traits for &'_ mut W
impl<'_, W> Write for &'_ mut W where
W: Write + ?Sized, impl<'_, R> Read for &'_ mut R where
R: Read + ?Sized, impl<'_, F> Future for &'_ mut F where
F: Unpin + Future + ?Sized, type Output = <F as Future>::Output;impl<'_, I> Iterator for &'_ mut I where
I: Iterator + ?Sized, type Item = <I as Iterator>::Item;[src]
Notable traits for &'_ mut W
impl<'_, W> Write for &'_ mut W where
W: Write + ?Sized, impl<'_, R> Read for &'_ mut R where
R: Read + ?Sized, impl<'_, F> Future for &'_ mut F where
F: Unpin + Future + ?Sized, type Output = <F as Future>::Output;impl<'_, I> Iterator for &'_ mut I where
I: Iterator + ?Sized, type Item = <I as Iterator>::Item;impl<T> BorrowMut<T> for T where
T: ?Sized, [src]
T: ?Sized,
pub fn borrow_mut(&mut self) -> &mut TⓘNotable traits for &'_ mut W
impl<'_, W> Write for &'_ mut W where
W: Write + ?Sized, impl<'_, R> Read for &'_ mut R where
R: Read + ?Sized, impl<'_, F> Future for &'_ mut F where
F: Unpin + Future + ?Sized, type Output = <F as Future>::Output;impl<'_, I> Iterator for &'_ mut I where
I: Iterator + ?Sized, type Item = <I as Iterator>::Item;[src]
Notable traits for &'_ mut W
impl<'_, W> Write for &'_ mut W where
W: Write + ?Sized, impl<'_, R> Read for &'_ mut R where
R: Read + ?Sized, impl<'_, F> Future for &'_ mut F where
F: Unpin + Future + ?Sized, type Output = <F as Future>::Output;impl<'_, I> Iterator for &'_ mut I where
I: Iterator + ?Sized, type Item = <I as Iterator>::Item;impl<T> Downcast for T where
T: Any,
T: Any,
pub fn into_any(self: Box<T>) -> Box<dyn Any + 'static>ⓘNotable traits for Box<W>
impl<W> Write for Box<W> where
W: Write + ?Sized, impl<R> Read for Box<R> where
R: Read + ?Sized, impl<I> Iterator for Box<I> where
I: Iterator + ?Sized, type Item = <I as Iterator>::Item;impl<F> Future for Box<F> where
F: Unpin + Future + ?Sized, type Output = <F as Future>::Output;
Notable traits for Box<W>
impl<W> Write for Box<W> where
W: Write + ?Sized, impl<R> Read for Box<R> where
R: Read + ?Sized, impl<I> Iterator for Box<I> where
I: Iterator + ?Sized, type Item = <I as Iterator>::Item;impl<F> Future for Box<F> where
F: Unpin + Future + ?Sized, type Output = <F as Future>::Output;pub fn into_any_rc(self: Rc<T>) -> Rc<dyn Any + 'static>
pub fn as_any(&self) -> &(dyn Any + 'static)
pub fn as_any_mut(&mut self) -> &mut (dyn Any + 'static)
impl<T> DowncastSync for T where
T: Send + Sync + Any,
T: Send + Sync + Any,
impl<T> DynClone for T where
T: Clone, [src]
T: Clone,
pub fn __clone_box(&self, Private) -> *mut ()[src]
impl<T> From<T> for T[src]
impl<T, U> Into<U> for T where
U: From<T>, [src]
U: From<T>,
impl<T> ToOwned for T where
T: Clone, [src]
T: Clone,
type Owned = T
The resulting type after obtaining ownership.
pub fn to_owned(&self) -> T[src]
pub fn clone_into(&self, target: &mut T)[src]
impl<T, U> TryFrom<U> for T where
U: Into<T>, [src]
U: Into<T>,
type Error = Infallible
The type returned in the event of a conversion error.
pub fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>[src]
impl<T, U> TryInto<U> for T where
U: TryFrom<T>, [src]
U: TryFrom<T>,