Skip to content

Commit

Permalink
fix bug which caused seed to get "stuck" on previous image even when …
Browse files Browse the repository at this point in the history
…UI specified -1
  • Loading branch information
lstein committed Sep 9, 2022
1 parent 1b5aae3 commit c85ae00
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion ldm/dream/server.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@ def build_opt(post_data, seed, gfpgan_model_exists):
setattr(opt, 'gfpgan_strength', float(post_data['gfpgan_strength']) if gfpgan_model_exists else 0)
setattr(opt, 'upscale', [int(post_data['upscale_level']), float(post_data['upscale_strength'])] if post_data['upscale_level'] != '' else None)
setattr(opt, 'progress_images', 'progress_images' in post_data)
setattr(opt, 'seed', seed if int(post_data['seed']) == -1 else int(post_data['seed']))
setattr(opt, 'seed', None if int(post_data['seed']) == -1 else int(post_data['seed']))
setattr(opt, 'variation_amount', float(post_data['variation_amount']) if int(post_data['seed']) != -1 else 0)
setattr(opt, 'with_variations', [])

Expand Down

0 comments on commit c85ae00

Please sign in to comment.