Image Segmentation
BiRefNet
Safetensors
Transformers
background-removal
mask-generation
Dichotomous Image Segmentation
Camouflaged Object Detection
Salient Object Detection
pytorch_model_hub_mixin
model_hub_mixin
custom_code
Instructions to use mastari/BiRefNet-patched with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- BiRefNet
How to use mastari/BiRefNet-patched with BiRefNet:
# Option 1: use with transformers from transformers import AutoModelForImageSegmentation birefnet = AutoModelForImageSegmentation.from_pretrained("mastari/BiRefNet-patched", trust_remote_code=True)# Option 2: use with BiRefNet # Install from https://github.com/ZhengPeng7/BiRefNet from models.birefnet import BiRefNet model = BiRefNet.from_pretrained("mastari/BiRefNet-patched") - Transformers
How to use mastari/BiRefNet-patched with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("image-segmentation", model="mastari/BiRefNet-patched", trust_remote_code=True)# pip install -U transformers accelerate # Load model directly from transformers import AutoModelForImageSegmentation model = AutoModelForImageSegmentation.from_pretrained("mastari/BiRefNet-patched", trust_remote_code=True, device_map="auto") - Notebooks
- Google Colab
- Kaggle
Download model.safetensors from mastari/BiRefNet-patched: direct link, hf CLI and curl.
- Browser
- Download file 444 MB
-
https://huggingface.co/mastari/BiRefNet-patched/resolve/main/model.safetensors
- Command line
-
hf download hf://mastari/BiRefNet-patched/model.safetensors
-
curl -L -o model.safetensors https://huggingface.co/mastari/BiRefNet-patched/resolve/main/model.safetensors
444 MB
- Xet hash:
- 796e4ababf8368833ae155c9063ce8a6bce38bc1b3783682e62c87f789cddcbe
- Size of remote file:
- 444 MB
- SHA256:
- 9ab37426bf4de0567af6b5d21b16151357149139362e6e8992021b8ce356a154
·
Xet efficiently stores Large Files inside Git, intelligently splitting files into unique chunks and accelerating uploads and downloads. More info.