flystem-usls/examples/fastsam
Jamjamjon a0d410b46d
Dev (#1)
* Update imageproc crates

* Add top-p method for sampling

* Add SVTR for text recognition & bug fix
2024-04-06 16:16:53 +08:00
..
README.md Initial 2024-03-29 15:54:24 +08:00
demo.jpg Initial 2024-03-29 15:54:24 +08:00
main.rs Dev (#1) 2024-04-06 16:16:53 +08:00

README.md

Quick Start

cargo run -r --example fastsam

Or you can manully

1.Donwload or export ONNX Model

  • Export

    pip install -U ultralytics
    yolo export model=FastSAM-s.pt format=onnx simplify dynamic
    
  • Download

    FastSAM-s-dyn-f16

2. Specify the ONNX model path in main.rs

let options = Options::default()
    .with_model("../models/FastSAM-s-dyn-f16.onnx")    // <= modify this
    .with_saveout("FastSAM")
    .with_profile(false);
let mut model = YOLO::new(&options)?;

3. Then, run

cargo run -r --example fastsam

Results