Instructions to use ChuuniZ/comfyui-image-models with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use ChuuniZ/comfyui-image-models with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("ChuuniZ/comfyui-image-models", dtype=torch.bfloat16, device_map="cuda") prompt = "Astronaut in a jungle, cold color palette, muted colors, detailed, 8k" image = pipe(prompt).images[0] - Notebooks
- Google Colab
- Kaggle
Upload BiRefNet/RMBG-2.0/BiRefNet_config.py
Browse files
BiRefNet/RMBG-2.0/BiRefNet_config.py
ADDED
|
@@ -0,0 +1,11 @@
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 1 |
+
from transformers import PretrainedConfig
|
| 2 |
+
|
| 3 |
+
class BiRefNetConfig(PretrainedConfig):
|
| 4 |
+
model_type = "SegformerForSemanticSegmentation"
|
| 5 |
+
def __init__(
|
| 6 |
+
self,
|
| 7 |
+
bb_pretrained=False,
|
| 8 |
+
**kwargs
|
| 9 |
+
):
|
| 10 |
+
self.bb_pretrained = bb_pretrained
|
| 11 |
+
super().__init__(**kwargs)
|