Skip to content
ModelListedExternal
Download

BEN2 ONNX

If you haven't already, you can install the Transformers.js JavaScript library from NPM using: npm i @huggingface/transformers

KindOtherBase modelPramaLLC/BEN2VersionRevision 75eb62bBgrade

Model source

Kind
Other
File size
198–209 MB
Base model
PramaLLC/BEN2
Version
vRevision 75eb62b
Updated
Oct 9, 2026
Downloads
25
Source
Hugging Face

Source description

Usage (Transformers.js)

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

npm i @huggingface/transformers

Example: Remove background of an image

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

const segmenter = await pipeline('background-removal', 'onnx-community/BEN2-ONNX');
const url = 'https://huggingface.co/datasets/Xenova/transformers.js-docs/resolve/main/woman-with-afro_medium.jpg';
const output = await segmenter(url);
output[0].save('mask.png');
// You can also use `output[0].toCanvas()` or `await output[0].toBlob()` if you would like to access the output without saving.
InputOutput
inputoutput

Sources

1 source
Hugging FacePrimaryVersion 75eb62bc12f6a1b8d33d3effa31d99cb71d0e8c2
huggingface.co/square-zero-labs/BEN2-ONNX/tree/75eb62bc12f6a1b8d33d3effa31d99cb71d0e8c2

Verified Oct 9

Model artifacts

4 artifacts

onnx/model_fp16_768.onnx

onnx · 198 MB · SHA-256 abe60727f1ba…615b · Hugging Face

Download

onnx/model_fp16_v2.onnx

onnx · 209 MB · SHA-256 484b0300dea7…b162 · Hugging Face

Download

onnx/model_fp16_v3.onnx

onnx · 209 MB · SHA-256 31b9264d290b…9845 · Hugging Face

Download

onnx/model_fp16.onnx

onnx · 209 MB · SHA-256 dfdc25f421f3…edf1 · Hugging Face

Download

Source excerpts

3 excerpts

--- license: mit base_model: - PramaLLC/BEN2 pipeline_tag: image-segmentation library_name: transformers.js tags: - background-removal --- ## 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**: Remove background of an image ```js import { pipeline } from '@huggingface/transformers'; const segmenter = await pipeline('background-removal', 'onnx-community/BEN2-ONNX'); const url = 'https://huggingface.co/datasets/Xenova/transformers.js-docs/resolve/main/woman-with-afro_medium.jpg'; const output = await segmenter(url); output[0].save('mask.png'); // You can also use `output[0].toCanvas()` or `await output[0].toBlob()` if you would like to access the output without saving. ``` | Input| Output | |--------|--------| | ![input](https://github.com/user-attachments/assets/e39c66b3-a3cd-4fcb-846f-899fbe95cbf5) | ![output](https://github.com/user-attachments/assets/90d4507e-74e0-4a75-9fc4-2c9d6d3cfaa5) |

Source context: 25 downloads · 1 likes · Pipeline image-segmentation · Library transformers.js · Repo square-zero-labs/BEN2-ONNX

Source context: 649 downloads · 0 likes · Pipeline image-segmentation · Library transformers.js · Repo square-zero-labs/BEN2-ONNX