Check out our new VS Code extension for experiment tracking and model development
Get a view of the MLEM project by listing all of its MLEM Objects
def ls(
project: str = ".",
rev: Optional[str] = None,
fs: Optional[AbstractFileSystem] = None,
type_filter: Union[
Type[MlemObject], Iterable[Type[MlemObject]], None
] = None,
include_links: bool = True,
) -> Dict[Type[MlemObject], List[MlemObject]]
from mlem.api import ls
objects = ls(".", rev=None, type_filter=None, include_links=True)
Populates a dictionary where keys are different types
of
MlemObjects and values are a
collection of MlemObjects of that type. This API is internally used by the CLI
command list.
project
(required) - Path or URL to projectrev
(optional) - revision, could be Git commit SHA, branch name or tag.fs
(optional) - filesystem to load from. If not provided, will be inferred
from projecttype_filter
(optional) - type of objects to be listed (eg: models / dataset
/ etc.)include_links
(optional) - whether to include links while fetching the list
of MlemObjects. Defaults to TrueNone
from mlem.api import ls
objects = ls(".")