Downloads · 30 days
688
43% of all-time downloads
onnx-community/rtdetr_r50vd
rtdetr_r50vd is a object detection model from onnx-community. Use it when you need objects located in an image. It is set up for transformers.js.
https://huggingface.co/PekingU/rtdetrr50vd with ONNX weights to be compatible with Transformers.js.
Downloads · 30 days
688
43% of all-time downloads
All-time downloads
1.6K
Public
Repo size
2.1 GB
Likes
2
Public
Click a slice to open those files.
.onnx692 MB · 100%
From the Hugging Face model README
https://huggingface.co/PekingU/rtdetr_r50vd with ONNX weights to be compatible with Transformers.js.
[!IMPORTANT] NOTE: RT-DETR support is experimental and requires you to install Transformers.js v3 from source.
If you haven't already, you can install the Transformers.js JavaScript library from GitHub using:
npm install xenova/transformers.js#v3
Example: Perform object-detection with onnx-community/rtdetr_r50vd.
import { pipeline } from '@xenova/transformers';
const detector = await pipeline('object-detection', 'onnx-community/rtdetr_r50vd');
const img = 'https://huggingface.co/datasets/Xenova/transformers.js-docs/resolve/main/cats.jpg';
const output = await detector(img, { threshold: 0.9 });
// [{
// score: 0.9720445871353149,
// label: 'cat',
// box: { xmin: 14, ymin: 54, xmax: 319, ymax: 472 }
// },
// ...
// {
// score: 0.9795005917549133,
// label: 'sofa',
// box: { xmin: 0, ymin: 0, xmax: 640, ymax: 472 }
// }]
Note: Having a separate repo for ONNX weights is intended to be a temporary solution until WebML gains more traction. If you would like to make your models web-ready, we recommend converting to ONNX using 🤗 Optimum and structuring your repo like this one (with ONNX weights located in a subfolder named onnx).