ModelList Class¶
-
class
modelindex.models.ModelList.ModelList(models: Optional[Union[List[Union[modelindex.models.Model.Model, Dict, str]], modelindex.models.Model.Model, Dict]] = None, _filepath: Optional[str] = None, _path_to_readme: Optional[str] = None)[source]¶ ModeList is a list of Models.
- Parameters
models (list, Model, dict) – Either a list of models, and individual model or a dict representing a model
_filepath (str) – The path of the file from which the list is initialized
_path_to_readme (str) – Path to README if loaded from there
-
__init__(models: Optional[Union[List[Union[modelindex.models.Model.Model, Dict, str]], modelindex.models.Model.Model, Dict]] = None, _filepath: Optional[str] = None, _path_to_readme: Optional[str] = None)[source]¶ - Parameters
models (list, Model, dict) – Either a list of models, and individual model or a dict representing a model
_filepath (str) – The path of the file from which the list is initialized
_path_to_readme (str) – Path to README if loaded from there
-
property
models¶ Get the list of models.
-
add(model: Union[modelindex.models.Model.Model, Dict], _filepath: Optional[str] = None)[source]¶ Add a model to the list.
- Parameters
model (Model, dict) – Either a Model or a dict representing a model
_filepath (str) – The path from which it was loaded