Struct caffe2_operator::SimpleNet
source · pub struct SimpleNet { /* private fields */ }
Expand description
| This is the very basic structure you | need to run a network - all it does is simply | to run everything in sequence. | | If you want more fancy control such as | a DAG-like execution, check out other | better net implementations. |
Implementations§
source§impl SimpleNet
impl SimpleNet
pub fn new(net_def: &Arc<NetDef>, ws: *mut Workspace) -> Self
pub fn supports_async(&mut self) -> bool
sourcepub fn get_operators(&self) -> Vec<OperatorStorage>
pub fn get_operators(&self) -> Vec<OperatorStorage>
| This returns a list of pointers to objects | stored in unique_ptrs. | | Used by Observers. | | Think carefully before using. |
pub fn run(&mut self) -> bool
pub fn run_async(&mut self) -> bool
pub fn test_benchmark( &mut self, warmup_runs: i32, main_runs: i32, run_individual: bool ) -> Vec<f32>
Auto Trait Implementations§
impl !RefUnwindSafe for SimpleNet
impl !Send for SimpleNet
impl !Sync for SimpleNet
impl Unpin for SimpleNet
impl !UnwindSafe for SimpleNet
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.