Hugging Face's logo Hugging Face
  • Models
  • Datasets
  • Spaces
  • Buckets new
  • Docs
  • Enterprise
  • Pricing
    • Website
      • Tasks
      • HuggingChat
      • Collections
      • Languages
      • Organizations
    • Community
      • Blog
      • Posts
      • Daily Papers
      • Hardware
      • Learn
      • Discord
      • Forum
      • GitHub
    • Solutions
      • Team & Enterprise
      • Hugging Face PRO
      • Enterprise Support
      • Inference Providers
      • Inference Endpoints
      • Storage Buckets

  • Log In
  • Sign Up

feyninc
/
multimatte

nobg
Safetensors
model_hub_mixin
nobg-sam3
promptable
bbox
pytorch_model_hub_mixin
Model card Files Files and versions
xet
Community
1

Instructions to use feyninc/multimatte with libraries, inference providers, notebooks, and local apps. Follow these links to get started.

  • Libraries
  • nobg

    How to use feyninc/multimatte with nobg:

    pip install nobg
    # Option 1: use via the predict method
    
    from nobg import AutoModel, AutoProcessor
    
    model = AutoModel.from_pretrained("feyninc/multimatte").eval()
    processor = AutoProcessor.from_pretrained("feyninc/multimatte")
    
    cutout = model.predict(processor, "image.jpg", "prompt")
    # Option 2: use the model and processor directly
    
    import torch
    from loadimg import load_img
    from nobg import AutoModel, AutoProcessor
    
    model = AutoModel.from_pretrained("feyninc/multimatte").eval()
    processor = AutoProcessor.from_pretrained("feyninc/multimatte")
    
    image = load_img("image.jpg").convert("RGB")
    inputs = processor(image, return_tensors="pt")
    
    with torch.no_grad():
        outputs = model(pixel_values=inputs["pixel_values"])
    
    alpha = processor.post_process_alpha_matting(outputs, target_sizes=[(image.height, image.width)])[0]
    processor.cutout(image, alpha).save("output.png")
  • Notebooks
  • Google Colab
  • Kaggle
multimatte
3.37 GB
Ctrl+K
Ctrl+K
  • 1 contributor
History: 10 commits
not-lain's picture
not-lain
Update README.md
7481698 verified 1 day ago
  • .gitattributes
    1.52 kB
    initial commit 23 days ago
  • README.md
    7.57 kB
    Update README.md 1 day ago
  • config.json
    925 Bytes
    Update config.json 16 days ago
  • model.safetensors
    3.36 GB
    xet
    Push model using huggingface_hub. 23 days ago
  • processor_config.json
    698 Bytes
    Upload processor 22 days ago
  • tokenizer.json
    3.64 MB
    Upload processor 23 days ago
  • tokenizer_config.json
    467 Bytes
    Upload processor 22 days ago