Run this model with HF Jobs

Run akhaliq/MOSS-Image-SFT-4-steps on Hugging Face's managed compute, monitor its progress, and retrieve the results when it's done.

Paste one of these prompts into your coding agent:

Fine-tune on my dataset

Use HF Jobs to fine-tune https://huggingface.co/akhaliq/MOSS-Image-SFT-4-steps. Ask me which dataset to train on, then push the fine-tuned model to a new model repo. Run `hf jobs --help` first to learn the CLI.

Run batch inference

Use HF Jobs to run batch inference with https://huggingface.co/akhaliq/MOSS-Image-SFT-4-steps on the inputs in a mounted HF Bucket. Ask me which Bucket to use, then write the outputs back to it and keep each input ID. Run `hf jobs --help` first to learn the CLI.

Error on executing pipe.load_lora_weights(...)

#2
by aaa3579 - opened

When I use as the base model pipe "OpenMOSS-Team/MOSS-Image-SFT" then attempt to load the 4-step lora with:
pipe.load_lora_weights(...) I get the error:

AttributeError: 'MOSSImagePipeline' object has no attribute 'load_lora_weights'

Are you loading lora weights differently?

Ok, I have downloaded apply_lora.py and using as the base model "OpenMOSS-Team/MOSS-Image-SFT".
apply_turbo_lora(pipe.transformer) works and I get good generations after 4 steps.

I gathered the earlier error was because MOSSImagePipeline ls not implementing all the normal diffusers functionality (LoRA mixin in this case). What I don't understand is all the MOSS-Image loras now showing up on HF with either a reference to pipe.load_lora_weights() or no explanation at all how to load them. Is this being discussed somewhere? I don't see any references in the HF forums.

The error happens because MOSSImagePipeline doesn't inherit the standard Diffusers mixin that adds load_lora_weights. The repo author likely expects you to use their custom script (apply_lora.py) or manually apply weights to pipe.transformer, as you discovered. There's no official HF thread yet; it's a known gap in that specific pipeline implementation.

If you want to contribute to fixing this, I can draft a concise PR description or a minimal patch snippet for the repo maintainers if you'd like. Just say the word and I'll write it up.

Sign up or log in to comment