Skip to content
ModelListedExternal
Download

Dinov2 Small

with ONNX weights to be compatible with Transformers.js.

KindOtherBase modelfacebook/dinov2-smallVersionRevision c2bb04a

Model source

Kind
Other
File size
12.3–84.4 MB
Base model
facebook/dinov2-small
Version
vRevision c2bb04a
Updated
Sep 22, 2026
Downloads
18.7K
Source
Hugging Face

Source description

https://huggingface.co/facebook/dinov2-small with ONNX weights to be compatible with Transformers.js.

Usage (Transformers.js)

If you haven't already, you can install the Transformers.js JavaScript library from NPM using:

npm i @huggingface/transformers

Example: Perform image feature extraction.

import { pipeline } from '@huggingface/transformers';

const image_feature_extractor = await pipeline('image-feature-extraction', 'Xenova/dinov2-small');
const url = 'https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/cats.png';
const features = await image_feature_extractor(url);

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).

Sources

1 source
Hugging FacePrimaryVersion c2bb04a51fab207c420665f1946016107bffc701
huggingface.co/Xenova/dinov2-small/tree/c2bb04a51fab207c420665f1946016107bffc701

Verified Sep 9

Model artifacts

7 artifacts

onnx/model_bnb4.onnx

onnx · 13.1 MB · SHA-256 47f1379998d2…26ea · Hugging Face

Download

onnx/model_fp16.onnx

onnx · 42.4 MB · SHA-256 4e9ea6fe106e…cf04 · Hugging Face

Download

onnx/model_q4.onnx

onnx · 14.3 MB · SHA-256 6335b48edfab…77a2 · Hugging Face

Download

onnx/model_q4f16.onnx

onnx · 12.3 MB · SHA-256 c57fc9ad4258…6e12 · Hugging Face

Download

onnx/model_quantized.onnx

onnx · 23.3 MB · SHA-256 3afdc8bc63b5…d917 · Hugging Face

Download

onnx/model_uint8.onnx

onnx · 21.4 MB · SHA-256 6d10d812e130…4312 · Hugging Face

Download

onnx/model.onnx

onnx · 84.4 MB · SHA-256 83141175ec78…79ea · Hugging Face

Download

Source excerpts

2 excerpts

--- base_model: facebook/dinov2-small library_name: transformers.js --- https://huggingface.co/facebook/dinov2-small with ONNX weights to be compatible with Transformers.js. ## Usage (Transformers.js) If you haven't already, you can install the [Transformers.js](https://huggingface.co/docs/transformers.js) JavaScript library from [NPM](https://www.npmjs.com/package/@huggingface/transformers) using: ```bash npm i @huggingface/transformers ``` **Example:** Perform image feature extraction. ```js import { pipeline } from '@huggingface/transformers'; const image_feature_extractor = await pipeline('image-feature-extraction', 'Xenova/dinov2-small'); const url = 'https://huggingface.co/datasets/huggingface/documentation-images/resolve/main/cats.png'; const features = await image_feature_extractor(url); ``` 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](https://huggingface.co/docs/optimum/index) and structuring your repo like this one (with ONNX weights located in a subfolder named `onnx`).

Source context: 18692 downloads · 1 likes · Pipeline image-feature-extraction · Library transformers.js · Repo Xenova/dinov2-small