Struct caffe2op_slice::SliceOp
source · pub struct SliceOp<Context> { /* private fields */ }
Expand description
| Produces a slice of the input tensor.
|
| - Currently, only slicing in a single
| dimension is supported.
|
| - Start and end indices are either passed
| as two 1D input tensors or using the starts
| and ends
arguments.
|
| - If a negative value is passed for any
| of the start or end indices, it represents
| |value| - 1 elements before the end of
| that dimension. End indices are non-inclusive
| unless negative (end index
|
| -1 means up to and including the last
| element).
|
| Github Links:
|
| - https://github.com/pytorch/pytorch/blob/master/caffe2/operators/slice_op.cc
|
Implementations§
Auto Trait Implementations§
impl<Context> !RefUnwindSafe for SliceOp<Context>
impl<Context> !Send for SliceOp<Context>
impl<Context> !Sync for SliceOp<Context>
impl<Context> Unpin for SliceOp<Context>where Context: Unpin,
impl<Context> !UnwindSafe for SliceOp<Context>
Blanket Implementations§
§impl<T> Pointable for T
impl<T> Pointable for T
§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere SS: SubsetOf<SP>,
§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self
from the equivalent element of its
superset. Read more§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self
is actually part of its subset T
(and can be converted to it).§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset
but without any property checks. Always succeeds.§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self
to the equivalent element of its superset.