#
## Model Introduction
This model is trained using the [Civision/model training](https://modelscope.ai/civision/modelTraining) environment and computing resources provided by ModelScope.
* Model Type: LoRA
* Base Model: [briaai/Fibo-2.0-dev](https://modelscope.ai/models/briaai/Fibo-2.0-dev)
* Training Code: [DiffSynth-Studio](https://github.com/modelscope/DiffSynth-Studio)
* Data amount:57
* Total training steps:6000
* License: Apache-2.0
## Inference Code
Install [DiffSynth-Studio](https://github.com/modelscope/DiffSynth-Studio):
```bash
pip install diffsynth
```
Inference:
```python
import torch
from diffsynth.pipelines.fibo import FiboPipeline, ModelConfig
pipe = FiboPipeline.from_pretrained(
torch_dtype=torch.bfloat16,
device="cuda",
model_configs=[
ModelConfig(model_id="briaai/Fibo-2.0-dev", origin_file_pattern="transformer/*.safetensors"),
ModelConfig(model_id="briaai/Fibo-2.0-dev", origin_file_pattern="text_encoder/model.safetensors"),
ModelConfig(model_id="briaai/Fibo-2.0-dev", origin_file_pattern="vae/diffusion_pytorch_model.safetensors"),
],
processor_config=ModelConfig(model_id="briaai/Fibo-2.0-dev", origin_file_pattern="processor/"),
font_config=ModelConfig(model_id="briaai/Fibo-2.0-dev", origin_file_pattern="fonts/"),
)
pipe.load_lora(pipe.dit, ModelConfig(model_id="PerforMax/FIBO-LORA-TM-0", origin_file_pattern="FIBO-LORA-TM-0_c1-st6000.safetensors"))
prompt = "a cat"
image = pipe(prompt=prompt, height=1024, width=1024, seed=0, num_inference_steps=50, cfg_scale=5.0)
image.save("image.png")
```
