Hugging Face's logo Hugging Face
  • Models
  • Datasets
  • Spaces
  • Buckets new
  • Docs
  • Enterprise
  • Pricing

  • Log In
  • Sign Up

mastari
/
BiRefNet-patched

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
Model card Files Files and versions
xet
Community

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)
    # Load model directly
    from transformers import AutoModelForImageSegmentation
    model = AutoModelForImageSegmentation.from_pretrained("mastari/BiRefNet-patched", trust_remote_code=True, dtype="auto")
  • Notebooks
  • Google Colab
  • Kaggle
BiRefNet-patched
445 MB
Ctrl+K
Ctrl+K
  • 1 contributor
History: 3 commits
mastari's picture
mastari
wow
2792e1a 6 months ago
  • .gitattributes
    1.52 kB
    Rebuilt repo cleanly with fresh model under LFS 7 months ago
  • .gitignore
    1.91 kB
    wow 6 months ago
  • BiRefNet_config.py
    298 Bytes
    wow 6 months ago
  • README.md
    9.97 kB
    Rebuilt repo cleanly with fresh model under LFS 7 months ago
  • birefnet.py
    92.2 kB
    Rebuilt repo cleanly with fresh model under LFS 7 months ago
  • config.json
    405 Bytes
    Rebuilt repo cleanly with fresh model under LFS 7 months ago
  • handler.py
    7.68 kB
    wow 6 months ago
  • model.safetensors
    444 MB
    xet
    Rebuilt repo cleanly with fresh model under LFS 7 months ago
  • requirements.txt
    149 Bytes
    Rebuilt repo cleanly with fresh model under LFS 7 months ago