mirror of
https://github.com/sd-webui/stable-diffusion-webui.git
synced 2024-12-14 14:52:31 +03:00
Fix again, final hopefully
This commit is contained in:
parent
bc212870ae
commit
670ab25a6a
4
webui.py
4
webui.py
@ -312,7 +312,9 @@ if opt.optimized:
|
||||
modelFS = instantiate_from_config(config.modelFirstStage)
|
||||
_, _ = modelFS.load_state_dict(sd, strict=False)
|
||||
modelFS.eval()
|
||||
del sd
|
||||
device = torch.device("cuda") if torch.cuda.is_available() else torch.device("cpu")
|
||||
model = model if opt.no_half else model.half()
|
||||
modelCS = modelCS if opt.no_half else modelCS.half()
|
||||
else:
|
||||
config = OmegaConf.load("configs/stable-diffusion/v1-inference.yaml")
|
||||
model = load_model_from_config(config, "models/ldm/stable-diffusion-v1/model.ckpt")
|
||||
|
Loading…
Reference in New Issue
Block a user