mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
allow submodels to be fetched independent of parent pipeline
This commit is contained in:
parent
d8b1f29066
commit
2204e47596
@ -357,6 +357,13 @@ class ModelManager(object):
|
|||||||
vae_id = mconfig.vae.repo_id
|
vae_id = mconfig.vae.repo_id
|
||||||
vae = (SDModelType.vae, vae_id)
|
vae = (SDModelType.vae, vae_id)
|
||||||
|
|
||||||
|
# optimization - don't load whole model if the user
|
||||||
|
# is asking for just a piece of it
|
||||||
|
if model_type == SDModelType.diffusers and submodel and not subfolder:
|
||||||
|
model_type = submodel
|
||||||
|
subfolder = submodel.name
|
||||||
|
submodel = None
|
||||||
|
|
||||||
model_context = self.cache.get_model(
|
model_context = self.cache.get_model(
|
||||||
location,
|
location,
|
||||||
model_type = model_type,
|
model_type = model_type,
|
||||||
|
Loading…
x
Reference in New Issue
Block a user