sd: load single file model using local config
This commit is contained in:
@@ -14,6 +14,7 @@ from iopaint.const import (
|
||||
DIFFUSERS_SDXL_INPAINT_CLASS_NAME,
|
||||
ANYTEXT_NAME,
|
||||
)
|
||||
from iopaint.model.original_sd_configs import get_config_files
|
||||
from iopaint.model_info import ModelInfo, ModelType
|
||||
|
||||
|
||||
@@ -60,6 +61,7 @@ def get_sd_model_type(model_abs_path: str) -> ModelType:
|
||||
load_safety_checker=False,
|
||||
local_files_only=True,
|
||||
num_in_channels=9,
|
||||
config_files=get_config_files()
|
||||
)
|
||||
model_type = ModelType.DIFFUSERS_SD_INPAINT
|
||||
except ValueError as e:
|
||||
@@ -84,6 +86,7 @@ def get_sdxl_model_type(model_abs_path: str) -> ModelType:
|
||||
load_safety_checker=False,
|
||||
local_files_only=True,
|
||||
num_in_channels=9,
|
||||
config_files=get_config_files()
|
||||
)
|
||||
if model.unet.config.in_channels == 9:
|
||||
# https://github.com/huggingface/diffusers/issues/6610
|
||||
|
||||
Reference in New Issue
Block a user