This commit is contained in:
Jamjamjon
2024-04-14 18:11:09 +08:00
committed by GitHub
parent a717b98f7b
commit c05836f02e
6 changed files with 4 additions and 9 deletions

View File

@ -12,7 +12,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macOS-latest]
os: [ubuntu-latest, macOS-latest, windows-latest]
rust: [stable]
steps:
- uses: actions/checkout@v2
@ -31,7 +31,7 @@ jobs:
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, macOS-latest]
os: [ubuntu-latest, macOS-latest, windows-latest]
rust: [stable]
steps:
- uses: actions/checkout@v2

View File

@ -35,7 +35,6 @@ ureq = { version = "2.9.1", default-features = true, features = [
] }
walkdir = { version = "2.5.0" }
tokenizers = { version = "0.15.2" }
usearch = { version = "2.10.4" }
rayon = "1.10.0"
indicatif = "0.17.8"
image = "0.25.1"

View File

@ -4,7 +4,6 @@ fn main() -> Result<(), Box<dyn std::error::Error>> {
// build model
let options = Options::default()
.with_model("../models/dinov2-s14-dyn-f16.onnx")
// .with_model("../models/dinov2-b14-dyn.onnx")
.with_i00((1, 1, 1).into())
.with_i02((224, 224, 224).into())
.with_i03((224, 224, 224).into());

View File

@ -46,8 +46,8 @@ pub struct Options {
pub apply_nms: bool,
pub tokenizer: Option<String>,
pub vocab: Option<String>,
pub names: Option<Vec<String>>, // class names
pub names2: Option<Vec<String>>, // could be keypoints names
pub names: Option<Vec<String>>, // names
pub names2: Option<Vec<String>>, // names2, could be keypoints names
pub anchors_first: bool, // otuput format: [bs, anchors/na, pos+nc+nm]
pub min_width: Option<f32>,
pub min_height: Option<f32>,

View File

@ -5,7 +5,6 @@ use std::io::{Read, Write};
use std::path::{Path, PathBuf};
pub fn auto_load<P: AsRef<Path>>(src: P) -> Result<String> {
// check if input file exists
let src = src.as_ref();
let p = if src.is_file() {
src.into()

View File

@ -153,8 +153,6 @@ impl YOLO {
let mut ys = Vec::new();
for (idx, anchor) in preds.axis_iter(Axis(0)).enumerate() {
// [b, 4 + nc + nm, na]
// input image
let width_original = xs0[idx].width() as f32;
let height_original = xs0[idx].height() as f32;
let ratio = (self.width() as f32 / width_original)