mirror of
https://github.com/invoke-ai/InvokeAI
synced 2024-08-30 20:32:17 +00:00
further removal of Paths
This commit is contained in:
parent
141d438517
commit
5190a4c282
@ -267,12 +267,11 @@ async def convert_model(
|
|||||||
logger = ApiDependencies.invoker.services.logger
|
logger = ApiDependencies.invoker.services.logger
|
||||||
try:
|
try:
|
||||||
logger.info(f"Converting model: {model_name}")
|
logger.info(f"Converting model: {model_name}")
|
||||||
dest = pathlib.Path(convert_dest_directory) if convert_dest_directory else None
|
|
||||||
ApiDependencies.invoker.services.model_manager.convert_model(
|
ApiDependencies.invoker.services.model_manager.convert_model(
|
||||||
model_name,
|
model_name,
|
||||||
base_model=base_model,
|
base_model=base_model,
|
||||||
model_type=model_type,
|
model_type=model_type,
|
||||||
convert_dest_directory=dest,
|
convert_dest_directory=convert_dest_directory,
|
||||||
)
|
)
|
||||||
model_raw = ApiDependencies.invoker.services.model_manager.list_model(
|
model_raw = ApiDependencies.invoker.services.model_manager.list_model(
|
||||||
model_name, base_model=base_model, model_type=model_type
|
model_name, base_model=base_model, model_type=model_type
|
||||||
|
@ -577,7 +577,7 @@ class ModelManagerService(ModelManagerServiceBase):
|
|||||||
alpha: float = 0.5,
|
alpha: float = 0.5,
|
||||||
interp: Optional[MergeInterpolationMethod] = None,
|
interp: Optional[MergeInterpolationMethod] = None,
|
||||||
force: bool = False,
|
force: bool = False,
|
||||||
merge_dest_directory: Optional[Path] = Field(
|
merge_dest_directory: Optional[str] = Field(
|
||||||
default=None, description="Optional directory location for merged model"
|
default=None, description="Optional directory location for merged model"
|
||||||
),
|
),
|
||||||
) -> AddModelResult:
|
) -> AddModelResult:
|
||||||
|
@ -31,7 +31,7 @@ class ModelMerger(object):
|
|||||||
|
|
||||||
def merge_diffusion_models(
|
def merge_diffusion_models(
|
||||||
self,
|
self,
|
||||||
model_paths: List[Path],
|
model_paths: List[str],
|
||||||
alpha: float = 0.5,
|
alpha: float = 0.5,
|
||||||
interp: Optional[MergeInterpolationMethod] = None,
|
interp: Optional[MergeInterpolationMethod] = None,
|
||||||
force: bool = False,
|
force: bool = False,
|
||||||
@ -75,7 +75,7 @@ class ModelMerger(object):
|
|||||||
alpha: float = 0.5,
|
alpha: float = 0.5,
|
||||||
interp: Optional[MergeInterpolationMethod] = None,
|
interp: Optional[MergeInterpolationMethod] = None,
|
||||||
force: bool = False,
|
force: bool = False,
|
||||||
merge_dest_directory: Optional[Path] = None,
|
merge_dest_directory: Optional[str] = None,
|
||||||
**kwargs,
|
**kwargs,
|
||||||
) -> AddModelResult:
|
) -> AddModelResult:
|
||||||
"""
|
"""
|
||||||
|
Loading…
Reference in New Issue
Block a user