policy module¶
Automated Machine Learning Environment (AMLE)
Policy library that handles reading in policy, validating it and providing values to other parts of AMLE
-
class
policy.
Policy
(config, project_directory)¶ Bases:
baseclass.BaseClass
This policy class serves these purposes: - Ingest policy (policy.yaml) from file - Validate correctness of policy against schema - Methods and functions to check various parameters
against policyNote: Class definitions are not nested as not considered Pythonic Main Methods and Variables: - ingest # Read in policy and check validity
-
get_aggregator
(name)¶ Return policy for a named aggregator
-
get_aggregators
()¶ Return a list of policy aggregators
-
get_algorithms
()¶ Return a list of policy algorithms
-
get_datasets
()¶ Return a list of policy datasets
-
get_experiment
(name)¶ Return policy for a named experiment
-
get_experiments
()¶ Return a list of policy experiments
-
get_run_items
()¶ Return a list of run items
-
-
policy.
validate
(logger, data, schema, where)¶ Generic validation of a data structure against schema using Voluptuous data validation library Parameters:
- logger: valid logger reference
- data: structure to validate
- schema: a valid Voluptuous schema
- where: string for debugging purposes to identity the policy location