mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
set default max_models to 2 internally as well as as arg
This commit is contained in:
parent
0c8f0e3386
commit
80f2cfe3e3
@ -146,7 +146,7 @@ class Generate:
|
|||||||
esrgan=None,
|
esrgan=None,
|
||||||
free_gpu_mem=False,
|
free_gpu_mem=False,
|
||||||
safety_checker:bool=False,
|
safety_checker:bool=False,
|
||||||
max_loaded_models:int=3,
|
max_loaded_models:int=2,
|
||||||
# these are deprecated; if present they override values in the conf file
|
# these are deprecated; if present they override values in the conf file
|
||||||
weights = None,
|
weights = None,
|
||||||
config = None,
|
config = None,
|
||||||
|
@ -20,7 +20,7 @@ from omegaconf import OmegaConf
|
|||||||
from omegaconf.errors import ConfigAttributeError
|
from omegaconf.errors import ConfigAttributeError
|
||||||
from ldm.util import instantiate_from_config
|
from ldm.util import instantiate_from_config
|
||||||
|
|
||||||
DEFAULT_MAX_MODELS=3
|
DEFAULT_MAX_MODELS=2
|
||||||
|
|
||||||
class ModelCache(object):
|
class ModelCache(object):
|
||||||
def __init__(self, config:OmegaConf, device_type:str, precision:str, max_loaded_models=DEFAULT_MAX_MODELS):
|
def __init__(self, config:OmegaConf, device_type:str, precision:str, max_loaded_models=DEFAULT_MAX_MODELS):
|
||||||
|
Loading…
x
Reference in New Issue
Block a user