Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

fix stable diffusion inference bug. #5289

Merged
merged 3 commits into from
Mar 5, 2024
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 2 additions & 0 deletions examples/images/diffusion/README.md
Original file line number Diff line number Diff line change
Expand Up @@ -202,6 +202,8 @@ python main.py --logdir /tmp/ -t -b configs/Teyvat/train_colossalai_teyvat.yaml
```

## Inference
if you want to test with pretrain model,as bellow:
python scripts/txt2img.py --prompt "a photograph of an astronaut riding a horse" --plms --outdir ./output --ckpt 512-base-ema.ckpt --config configs/train_ddp.yaml

You can get your training last.ckpt and train config.yaml in your `--logdir`, and run by
```
Expand Down
3 changes: 1 addition & 2 deletions examples/images/diffusion/configs/train_ddp.yaml
Original file line number Diff line number Diff line change
@@ -1,5 +1,6 @@
model:
base_learning_rate: 1.0e-4
target: ldm.models.diffusion.ddpm.LatentDiffusion
params:
parameterization: "v"
linear_start: 0.00085
Expand Down Expand Up @@ -86,8 +87,6 @@ lightning:
max_epochs: 2
precision: 16
auto_select_gpus: False
strategy:
find_unused_parameters: False
log_every_n_steps: 2
# max_steps: 6o
logger: True
Expand Down