mlonmcu.environment package

Submodules

mlonmcu.environment.config module

class mlonmcu.environment.config.BackendConfig(name, enabled=True, features={})[source]

Bases: BaseConfig

class mlonmcu.environment.config.BackendFeatureConfig(name, backend, supported=True)[source]

Bases: FeatureConfig

class mlonmcu.environment.config.BaseConfig[source]

Bases: object

class mlonmcu.environment.config.DefaultsConfig(log_level=20, log_to_file=False, log_rotate=False, default_framework=None, default_backends={}, default_target=None, cleanup_auto=False, cleanup_keep=100)[source]

Bases: BaseConfig

class mlonmcu.environment.config.FeatureConfig(name, kind=FeatureKind.UNKNOWN, supported=True)[source]

Bases: object

class mlonmcu.environment.config.FeatureKind(value)[source]

Bases: Enum

An enumeration.

BACKEND = 2
FRAMEWORK = 1
FRONTEND = 4
TARGET = 3
UNKNOWN = 0
class mlonmcu.environment.config.FrameworkConfig(name, enabled=True, backends={}, features={})[source]

Bases: BaseConfig

class mlonmcu.environment.config.FrameworkFeatureConfig(name, framework, supported=True)[source]

Bases: FeatureConfig

class mlonmcu.environment.config.FrontendConfig(name, enabled=True, features={})[source]

Bases: BaseConfig

class mlonmcu.environment.config.FrontendFeatureConfig(name, frontend, supported=True)[source]

Bases: FeatureConfig

class mlonmcu.environment.config.PathConfig(path, base=None)[source]

Bases: BaseConfig

class mlonmcu.environment.config.PlatformConfig(name, enabled=True, features={})[source]

Bases: BaseConfig

class mlonmcu.environment.config.PlatformFeatureConfig(name, platform, supported=True)[source]

Bases: FeatureConfig

class mlonmcu.environment.config.RepoConfig(url, ref=None, options=None)[source]

Bases: BaseConfig

property recursive
property single_branch
property submodules
class mlonmcu.environment.config.TargetConfig(name, enabled=True, features={})[source]

Bases: BaseConfig

class mlonmcu.environment.config.TargetFeatureConfig(name, target, supported=True)[source]

Bases: FeatureConfig

mlonmcu.environment.config.get_config_dir()[source]
mlonmcu.environment.config.get_environments_dir()[source]
mlonmcu.environment.config.get_environments_file()[source]
mlonmcu.environment.config.get_plugins_dir()[source]
mlonmcu.environment.config.init_config_dir()[source]

mlonmcu.environment.environment module

class mlonmcu.environment.environment.DefaultEnvironment[source]

Bases: Environment

class mlonmcu.environment.environment.Environment[source]

Bases: object

classmethod from_file(filename)[source]
get_default_backends(framework)[source]
get_default_frameworks()[source]
get_default_targets()[source]
has_backend(name)[source]
has_feature(name)[source]

An alias for supports_feature.

has_framework(name)[source]
has_frontend(name)[source]
has_platform(name)[source]
has_target(name)[source]
has_toolchain(name)[source]
property home

Home directory of mlonmcu environment.

lookup_backend_configs(backend=None, framework=None, names_only=False)[source]
lookup_backend_feature_configs(name=None, framework=None, backend=None)[source]
lookup_feature_configs(name=None, kind=None, frontend=None, framework=None, backend=None, platform=None, target=None)[source]
lookup_framework_configs(framework=None, names_only=False)[source]
lookup_framework_feature_configs(name=None, framework=None)[source]
lookup_frontend_configs(frontend=None, names_only=False)[source]
lookup_frontend_feature_configs(name=None, frontend=None)[source]
lookup_path(name)[source]
lookup_platform_configs(platform=None, names_only=False)[source]
lookup_platform_feature_configs(name=None, platform=None)[source]
lookup_target_configs(target=None, names_only=False)[source]
lookup_target_feature_configs(name=None, target=None)[source]
lookup_var(name, default=None)[source]
supports_feature(name)[source]
to_file(filename)[source]
class mlonmcu.environment.environment.UserEnvironment(home, merge=False, alias=None, defaults=None, paths=None, repos=None, frameworks=None, frontends=None, platforms=None, toolchains=None, targets=None, variables=None, default_flags=None)[source]

Bases: DefaultEnvironment

mlonmcu.environment.init module

mlonmcu.environment.init.clone_models_repo(dest, url=None, ref=None, refresh=False, recursive=False)[source]
mlonmcu.environment.init.create_environment_directories(path, directories)[source]
mlonmcu.environment.init.create_venv_directory(base, hidden=True)[source]
mlonmcu.environment.init.initialize_environment(directory, name, interactive=True, create_venv=None, clone_models=None, allow_exists=None, register=None, template=None, config=None)[source]

mlonmcu.environment.list module

mlonmcu.environment.list.get_alternative_name(name, names)[source]
mlonmcu.environment.list.get_environment_names()[source]
mlonmcu.environment.list.get_environments_map()[source]
mlonmcu.environment.list.register_environment(name, path, overwrite=False)[source]
mlonmcu.environment.list.validate_name(name)[source]

mlonmcu.environment.loader module

mlonmcu.environment.loader.load_environment_from_file(filename, base)[source]

Utility to initialize a mlonmcu environment from a YAML file.

mlonmcu.environment.templates module

Definitions of mlonmcu config templates.

mlonmcu.environment.templates.fill_environment_yaml(template_name, home_dir, config=None)[source]
mlonmcu.environment.templates.fill_template(name, data={})[source]
mlonmcu.environment.templates.get_template_names()[source]
mlonmcu.environment.templates.get_template_text(name)[source]
mlonmcu.environment.templates.write_environment_yaml_from_template(path, template_name, home_dir, config=None)[source]

mlonmcu.environment.writer module

mlonmcu.environment.writer.create_environment_dict(environment)[source]
mlonmcu.environment.writer.write_environment_to_file(environment, filename)[source]

Utility to initialize a mlonmcu environment from a YAML file.

Module contents