idmtools.core.experiment_factory module#

Define ExperimentFactory.

This is used mostly internally. It does allow us to support specialized experiment types when needed.

Copyright 2021, Bill & Melinda Gates Foundation. All rights reserved.

class idmtools.core.experiment_factory.ExperimentFactory[source]#

Bases: object

ExperimentFactory allows creating experiments that could be derived through plugins.

DEFAULT_KEY = 'idmtools.entities.experiment.Experiment'#
__init__()[source]#

Initialize our factory.

On initialize, we load our plugin and build a map of ids for experiments.

create(key, fallback=None, **kwargs) Experiment[source]#

Create an experiment of type key.

Parameters:
  • key – Experiment Type

  • fallback – Fallback type. If none, uses DEFAULT_KEY

  • **kwargs – Options to pass to the experiment object

Returns:

Experiment object that was created