Trait ModelTraitConst

Source
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§

Provided Methods§

Source

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.
Source

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.

Implementors§

Source§

impl ModelTraitConst for BoxedRef<'_, ClassificationModel>

Source§

impl ModelTraitConst for BoxedRef<'_, DetectionModel>

Source§

impl ModelTraitConst for BoxedRef<'_, KeypointsModel>

Source§

impl ModelTraitConst for BoxedRef<'_, Model>

Source§

impl ModelTraitConst for BoxedRef<'_, SegmentationModel>

Source§

impl ModelTraitConst for BoxedRef<'_, TextDetectionModel>

Source§

impl ModelTraitConst for BoxedRef<'_, TextDetectionModel_DB>

Source§

impl ModelTraitConst for BoxedRef<'_, TextDetectionModel_EAST>

Source§

impl ModelTraitConst for BoxedRef<'_, TextRecognitionModel>

Source§

impl ModelTraitConst for BoxedRefMut<'_, ClassificationModel>

Source§

impl ModelTraitConst for BoxedRefMut<'_, DetectionModel>

Source§

impl ModelTraitConst for BoxedRefMut<'_, KeypointsModel>

Source§

impl ModelTraitConst for BoxedRefMut<'_, Model>

Source§

impl ModelTraitConst for BoxedRefMut<'_, SegmentationModel>

Source§

impl ModelTraitConst for BoxedRefMut<'_, TextDetectionModel>

Source§

impl ModelTraitConst for BoxedRefMut<'_, TextDetectionModel_DB>

Source§

impl ModelTraitConst for BoxedRefMut<'_, TextDetectionModel_EAST>

Source§

impl ModelTraitConst for BoxedRefMut<'_, TextRecognitionModel>

Source§

impl ModelTraitConst for ClassificationModel

Source§

impl ModelTraitConst for DetectionModel

Source§

impl ModelTraitConst for KeypointsModel

Source§

impl ModelTraitConst for Model

Source§

impl ModelTraitConst for SegmentationModel

Source§

impl ModelTraitConst for TextDetectionModel

Source§

impl ModelTraitConst for TextDetectionModel_DB

Source§

impl ModelTraitConst for TextDetectionModel_EAST

Source§

impl ModelTraitConst for TextRecognitionModel