Struct alumina::shape::NodeShape
[−]
[src]
pub struct NodeShape { pub channels: usize, pub spatial_dimensions: SmallVec<[Dimension; 4]>, }
Fields
channels: usize
spatial_dimensions: SmallVec<[Dimension; 4]>
Methods
impl NodeShape
[src]
fn new(channels: usize, higher_dims: &[usize]) -> NodeShape
[src]
fn new_flex(channels: usize, num_higher_dims: usize) -> NodeShape
[src]
Creates a new NodeShape, with higher timensions to be determined at runtime
fn new_flat(size: usize) -> NodeShape
[src]
fn collapse_ranges_to_minimum(&mut self) -> Result<(), ShapeError>
[src]
Should be called and only called by operations prior to propagating shape constraints The higher dimension ranges are collapsed to the lower bound, and all None entries are replaced with the range 0:0
fn flat_size(&self) -> Dimension
[src]
fn force_flat_size(&self) -> Result<usize, ShapeError>
[src]
fn to_data_shape(&self, n: usize) -> Result<DataShape, ShapeError>
[src]
If range upper != lower, lowe will be used.
fn is_fixed(&self) -> bool
[src]
fn rank(&self) -> usize
[src]
fn merge(&self, other: &NodeShape) -> Result<NodeShape, ShapeError>
[src]
Trait Implementations
impl Clone for NodeShape
[src]
fn clone(&self) -> NodeShape
[src]
Returns a copy of the value. Read more
fn clone_from(&mut self, source: &Self)
1.0.0[src]
Performs copy-assignment from source
. Read more