object_detector 0.5.0

Object detection using ORT and the yoloe-26-seg model. This model can detect multiple objects per image, each having a tag, pixel-level mask, and a boundingbox. It's pretrained, it has a vocabulary of 4000+ objects.
Documentation
use object_detector::{DetectorType, ObjectDetector};
use std::path::Path;

#[tokio::main]
async fn main() -> color_eyre::Result<()> {
    let image_path = Path::new("assets/img/market.jpg");
    let img = image::open(image_path)?;
    let labels = ["lamp", "person"];

    let detector = ObjectDetector::from_hf(DetectorType::Promptable)
        .build()
        .await?;

    println!(
        "Running inference on {} for labels: {:?}...",
        image_path.display(),
        labels
    );
    let results = detector.predict(&img).labels(&labels).call()?;
    for det in results {
        println!("[{:>10}] Score: {:.4}", det.tag, det.score);
    }

    Ok(())
}