Instructions to use OpenMOSS-Team/MOSS-Image-SFT with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Diffusers
How to use OpenMOSS-Team/MOSS-Image-SFT with Diffusers:
pip install -U diffusers transformers accelerate
import torch from diffusers import DiffusionPipeline # switch to "mps" for apple devices pipe = DiffusionPipeline.from_pretrained("OpenMOSS-Team/MOSS-Image-SFT", 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
- Local Apps Settings
- Draw Things
- DiffusionBee
The remote pipeline uses flaot64 / doubles breaks the pipeline on MPS and NPU/XPU's
#5
by Vargol - opened
Are the uses of float64 on line 236
https://huggingface.co/OpenMOSS-Team/MOSS-Image-SFT/blob/main/pipeline_moss_image.py#L236
and the double() call on the next line, 237,
really necessary ? MacOS's Metal/MPS and many XPU NPU's do not support float64 and thus the pipeline breaks.
I'm currently yarding a version where the float64 has been modified to float32, and the double() call removed but my Mac is really slow so will take some time to do 50 steps π
