add route for model conversion from safetensors to diffusers

- Begin to add SwaggerUI documentation for AnyModelConfig and other
  discriminated Unions.
This commit is contained in:
Lincoln Stein
2024-02-12 21:25:42 -05:00
committed by psychedelicious
parent 46c8ce9fed
commit 0845a0ed84
7 changed files with 113 additions and 21 deletions

View File

@ -117,6 +117,11 @@ class AnyModelLoader:
"""Return the RAM cache associated used by the loaders."""
return self._ram_cache
@property
def convert_cache(self) -> ModelConvertCacheBase:
"""Return the convert cache associated used by the loaders."""
return self._convert_cache
def load_model(self, model_config: AnyModelConfig, submodel_type: Optional[SubModelType] = None) -> LoadedModel:
"""
Return a model given its configuration.