mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
fix incorrect VAE config file path during conversion of ckpts (#3616)
This fixes a "config file not found" error when loading VAE checkpoints.
This commit is contained in:
commit
d9ac36df1d
@ -137,7 +137,6 @@ def _convert_vae_ckpt_and_cache(
|
|||||||
from .stable_diffusion import _select_ckpt_config
|
from .stable_diffusion import _select_ckpt_config
|
||||||
# all sd models use same vae settings
|
# all sd models use same vae settings
|
||||||
config_file = _select_ckpt_config(base_model, ModelVariantType.Normal)
|
config_file = _select_ckpt_config(base_model, ModelVariantType.Normal)
|
||||||
|
|
||||||
else:
|
else:
|
||||||
raise Exception(f"Vae conversion not supported for model type: {base_model}")
|
raise Exception(f"Vae conversion not supported for model type: {base_model}")
|
||||||
|
|
||||||
@ -152,7 +151,7 @@ def _convert_vae_ckpt_and_cache(
|
|||||||
if "state_dict" in checkpoint:
|
if "state_dict" in checkpoint:
|
||||||
checkpoint = checkpoint["state_dict"]
|
checkpoint = checkpoint["state_dict"]
|
||||||
|
|
||||||
config = OmegaConf.load(config_file)
|
config = OmegaConf.load(app_config.root_path/config_file)
|
||||||
|
|
||||||
vae_model = convert_ldm_vae_to_diffusers(
|
vae_model = convert_ldm_vae_to_diffusers(
|
||||||
checkpoint = checkpoint,
|
checkpoint = checkpoint,
|
||||||
|
Loading…
Reference in New Issue
Block a user