Skip to main content

Open source background removal models for image and video matting

Project description

nobg

A library for image and video matting with HuggingFace Hub integration.

Installation

pip install nobg

Usage

AutoModel

Automatically detect and load the correct model architecture from a HuggingFace repo:

from nobg import AutoModel

model = AutoModel.from_pretrained("nobg/BiRefNet")

Load a specific model

from nobg import ANN, GPT2, BiRefNet

model = ANN.from_pretrained("nobg/ann")
model = GPT2.from_pretrained("nobg/gpt2")
model = BiRefNet.from_pretrained("nobg/BiRefNet")

Push to HuggingFace Hub

model.push_to_hub("your-username/model-name")

Citation

@software{nobg,
  title={nobg: Open Source Background Removal Models for Image and Video Matting},
  author={Hichri, Hafedh},
  year={2026},
  url={https://github.com/feyninc/nobg},
  license={MIT},
}

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

nobg-0.1.0rc0.tar.gz (183.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

nobg-0.1.0rc0-py3-none-any.whl (14.8 kB view details)

Uploaded Python 3

File details

Details for the file nobg-0.1.0rc0.tar.gz.

File metadata

  • Download URL: nobg-0.1.0rc0.tar.gz
  • Upload date:
  • Size: 183.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for nobg-0.1.0rc0.tar.gz
Algorithm Hash digest
SHA256 b824e9fc1e7b3c47426fe0a8312dc4ecba5a66e15a1d002e4ccc52403f140681
MD5 5140cd3f73a135dea371a1a0d64e8af4
BLAKE2b-256 9cd20d18e2561bbc44948e270da6524434f6386a0b5a19f9d8063cbd90b89046

See more details on using hashes here.

File details

Details for the file nobg-0.1.0rc0-py3-none-any.whl.

File metadata

  • Download URL: nobg-0.1.0rc0-py3-none-any.whl
  • Upload date:
  • Size: 14.8 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.12

File hashes

Hashes for nobg-0.1.0rc0-py3-none-any.whl
Algorithm Hash digest
SHA256 e110710f94c82e03f102e920e0bc31ce2a9c708c8ecfa32e5962cb8c98bf4ee0
MD5 ffcf52cd73e1def21e0d8497fe79f756
BLAKE2b-256 3ae39203e07df281d56135b7e695274bdaf54f3af511956c3cfd51d68830a266

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page