pub trait ModelTraitConst {
// Required method
fn as_raw_Model(&self) -> *const c_void;
// Provided methods
fn predict(
&self,
frame: &impl ToInputArray,
outs: &mut impl ToOutputArray,
) -> Result<()> { ... }
fn get_network_(&self) -> Result<Net> { ... }
}
Expand description
Constant methods for crate::dnn::Model
Required Methods§
fn as_raw_Model(&self) -> *const c_void
Provided Methods§
Sourcefn predict(
&self,
frame: &impl ToInputArray,
outs: &mut impl ToOutputArray,
) -> Result<()>
fn predict( &self, frame: &impl ToInputArray, outs: &mut impl ToOutputArray, ) -> Result<()>
Given the @p input frame, create input blob, run net and return the output @p blobs.
§Parameters
- frame: The input image.
- outs:[out] Allocated output blobs, which will store results of the computation.
fn get_network_(&self) -> Result<Net>
Dyn Compatibility§
This trait is not dyn compatible.
In older versions of Rust, dyn compatibility was called "object safety", so this trait is not object safe.