ONNX Background Remover Model (RMBG-2.0)

This repository contains the ONNX export of the RMBG-2.0 background removal model.

Files

  • model.onnx β†’ Original FP32 model (β‰ˆ1.02 GB)
  • model_int8.onnx β†’ Quantized INT8 model (smaller, faster)
  • quantize.py β†’ Script to quantize FP32 β†’ INT8

Usage

Load Quantized Model

from huggingface_hub import hf_hub_download
import onnxruntime as ort

# Download quantized model
model_path = hf_hub_download("NDPDevloper/onnx", "model_int8.onnx")

# Create ONNXRuntime session
session = ort.InferenceSession(model_path, providers=["CPUExecutionProvider"])
Downloads last month

-

Downloads are not tracked for this model. How to track
Inference Providers NEW
This model isn't deployed by any Inference Provider. πŸ™‹ Ask for provider support