feat: Use the git version of mnn-rs with a patch to local

This commit is contained in:
uttarayan21
2025-07-17 21:49:50 +05:30
parent dc43fd319a
commit c751654799
3 changed files with 15 additions and 8 deletions

View File

@@ -93,7 +93,7 @@ impl FaceDetection {
model.set_session_mode(mnn::SessionMode::Release);
let bc = mnn::BackendConfig::default().with_memory_mode(mnn::MemoryMode::High);
let sc = mnn::ScheduleConfig::new()
.with_type(mnn::ForwardType::CPU)
.with_type(mnn::ForwardType::CoreML)
.with_backend_config(bc);
tracing::info!("Creating session handle for face detection model");
let handle = mnn_sync::SessionHandle::new(model, sc)
@@ -103,6 +103,7 @@ impl FaceDetection {
}
pub fn detect_faces(&self, image: ndarray::Array3<u8>) -> Result<FaceDetectionModelOutput> {
#[rustfmt::skip]
use ::tap::*;
let output = self
.handle