Huashu Design
alchaincyf · Skill
Turns a one-line request in your AI agent into a finished design: a launch animation, a clickable app prototype, an editable slide deck, an infographic or a se…
Splits an image into the main object and its background at high resolution, from a 2024 research project on dichotomous image segmentation. For developers, image editors and computer vision researchers.
BiRefNet by ZhengPeng7 is a kit in the Developer category, listed by Mindket. It is free. This is version 1, last updated on . Download it on this page, a zip of its files. Nothing in it runs by itself.
pip install -U huggingface_hub hf download ZhengPeng7/BiRefNet
BiRefNet is an image segmentation model that separates a main object from the rest of a picture, working at high resolution. This repository is the official implementation of a 2024 paper that uses a bilateral reference for dichotomous segmentation. It has 221M parameters.
Developers and researchers who need clean object masks from images. The page also points to a GitHub repository with the code, documentation and a model zoo.
| Industry | Who uses it | How they use it | Example |
|---|---|---|---|
| Computer vision | Researchers | Study high-resolution dichotomous segmentation | Run the model on the project's sample images and compare masks |
| Image editing | Editors and tool builders | Cut a subject out of its background | Build a feature that isolates the main object in a photo |
| Software | App developers | Add object masks to an app | Load the model through transformers and call it on uploaded images |
| Machine learning | Practitioners | Evaluate or fine-tune a segmentation model | Use the evaluation notebook the card links |
You can skip it if you need to label many object classes in a scene. This model makes a two-way split of object and background.
| Use case | Who | What they get back |
|---|---|---|
| Object cutout | Editors | A mask separating the main object from the background |
| Research comparison | Researchers | A reference model for dichotomous segmentation |
| App feature | Developers | Masks produced from images in your own code |
You need Python and the packages the project lists.
pip install -U huggingface_hub hf download ZhengPeng7/BiRefNet
The simplest route uses the code and weights hosted on Hugging Face, loaded through transformers. The card notes the hosted code may lag the latest version.
# Load BiRefNet with weights
from transformers import AutoModelForImageSegmentation
birefnet = AutoModelForImageSegmentation.from_pretrained('ZhengPeng7/BiRefNet', trust_remote_code=True)The other route takes the newest code from GitHub and the weights from Hugging Face. You clone the repository first, then load as below.
# Use codes locally
from models.birefnet import BiRefNet
# Load weights from Hugging Face Models
birefnet = BiRefNet.from_pretrained('ZhengPeng7/BiRefNet')You load the model with the first snippet and pass it a photo of a product on a cluttered table. It gives back a mask that marks the product as the object and the rest as background.
Segmentation means deciding, pixel by pixel, what belongs to the main object. A first small step is to load the model with the transformers snippet and try it on one clear photo.
The model comes from work on high-resolution dichotomous image segmentation with a bilateral reference. The weights are about 441 MB in F16 and 221M parameters, small enough for a single GPU or a patient CPU. The card offers two loading paths, trading convenience of hosted code against always having the newest code from GitHub.
Splits an image into the main object and its background at high resolution, from a 2024 research project on dichotomous image segmentation. For developers, image editors and computer vision researchers.
Made by ZhengPeng7 on Hugging Face. These notes are Mindket's, written from its model page and model card; the model's own files and license are on Hugging Face.
What it is: BiRefNet is an image segmentation model that separates a main object from the rest of a picture, working at high resolution. This repository is the official implementation of a 2024 paper that uses a bilateral reference for dichotomous segmentation. It has 221M parameters.
Who it suits: Developers and researchers who need clean object masks from images. The page also points to a GitHub repository with the code, documentation and a model zoo.
Industry | Who uses it | How they use it | Example
Computer vision | Researchers | Study high-resolution dichotomous segmentation | Run the model on the project's sample images and compare masks
Image editing | Editors and tool builders | Cut a subject out of its background | Build a feature that isolates the main object in a photo
Software | App developers | Add object masks to an app | Load the model through transformers and call it on uploaded images
Machine learning | Practitioners | Evaluate or fine-tune a segmentation model | Use the evaluation notebook the card links
You can skip it if you need to label many object classes in a scene. This model makes a two-way split of object and background.
Where to use it:
Use case | Who | What they get back
Object cutout | Editors | A mask separating the main object from the background
Research comparison | Researchers | A reference model for dichotomous segmentation
App feature | Developers | Masks produced from images in your own code
How to set it up: You need Python and the packages the project lists.
pip install -U huggingface_hub
hf download ZhengPeng7/BiRefNet
How to use it: The simplest route uses the code and weights hosted on Hugging Face, loaded through transformers. The card notes the hosted code may lag the latest version.
# Load BiRefNet with weights
from transformers import AutoModelForImageSegmentation
birefnet = AutoModelForImageSegmentation.from_pretrained('ZhengPeng7/BiRefNet', trust_remote_code=True)
The other route takes the newest code from GitHub and the weights from Hugging Face. You clone the repository first, then load as below.
# Use codes locally
from models.birefnet import BiRefNet
# Load weights from Hugging Face Models
birefnet = BiRefNet.from_pretrained('ZhengPeng7/BiRefNet')
Example: You load the model with the first snippet and pass it a photo of a product on a cluttered table. It gives back a mask that marks the product as the object and the rest as background.
For newcomers and experts: Segmentation means deciding, pixel by pixel, what belongs to the main object. A first small step is to load the model with the transformers snippet and try it on one clear photo.
The model comes from work on high-resolution dichotomous image segmentation with a bilateral reference. The weights are about 441 MB in F16 and 221M parameters, small enough for a single GPU or a patient CPU. The card offers two loading paths, trading convenience of hosted code against always having the newest code from GitHub.
Install the requirements
Load the model from Hugging Face
Pass in an image
Get an object and background mask
Good to know:
Download its files with Hugging Face's command line:
pip install -U huggingface_hub
hf download ZhengPeng7/BiRefNet
Then follow the usage in its model card. Nothing in this kit runs by itself.
README.md 5 KB
Listed Hugging Face models in the same category that share the most tags with this one.
| Product | Downloads, last 30 days | Likes | Parameters | License | Last change |
|---|---|---|---|---|---|
| BiRefNet by ZhengPeng7 This page | 1,005,130 | 675 | 221M | mit | |
| VGGT-1BShares model_hub_mixin · pytorch_model_hub_mixin · safetensors | 646,177 | 158 | 1.3B | cc-by-nc-4.0 | |
| DiT-Wikiart-SmallShares model_hub_mixin · pytorch_model_hub_mixin · safetensors | 75 | 2 | 22M | mit | |
| Koharu Layout HighResShares image-segmentation · safetensors | 125 | 5 | 46.6M | apache-2.0 | |
| all-MiniLM-L6-v2Shares transformers · safetensors | 174,740,184 | 6,104 | 22.7M | apache-2.0 | |
| bge-small-en-v1.5Shares transformers · safetensors | 45,750,548 | 671 | 33.4M | mit |
Posts and comments that name this project on Hacker News, Bluesky, X, Reddit, Facebook and YouTube, found by a weekly search and on Trendshift. Mindket doesn’t write or check them. Open one to read it where it was posted.
alchaincyf · Skill
Turns a one-line request in your AI agent into a finished design: a launch animation, a clickable app prototype, an editable slide deck, an infographic or a se…
op7418 · Skill
Skill that makes single-file HTML slide decks, slide illustrations and platform covers in two visual styles, with a presenter mode for rehearsal. For speakers…
alirezarezvani · Skill
Adds 411 ready-made skills for Claude Code and other coding agents, grouped by role from engineering and product to marketing, finance and compliance. Installs…
block · Kit
Self-hostable workspace where people and AI agents share the same rooms, built on a Nostr relay that logs every action as a signed event. For teams that want t…
backnotprop · Kit
Opens your AI coding agent's plans, specs and code changes in a browser so you can annotate or comment on them and send the feedback straight back to the agent.
alibaba · Kit
Reviews Git changes with an AI agent that reads files and searches the codebase, then writes comments tied to exact lines. It suits developers who want automat…