tracts.driver_utils.load_model_from_driver#

load_model_from_driver(driver_spec, script_dir, driver_path, allosome_label=None)#

Loads the demographic model based on the specifications in the driver file. The model is expected to be defined in a separate yaml file, whose path is specified in the driver file under “model_filename”. See online documentation for details on how to specify the model yaml file and its contents.

Parameters:
  • (InferenceConfig) (driver_spec)

  • None) (allosome_label (str |)

  • (str) (driver_path)

  • None)

Returns:

ParametrizedDemography or ParametrizedDemographySexBiased

Return type:

The loaded demographic model, which can be either a ParametrizedDemography or a ParametrizedDemographySexBiased depending on whether allosomal admixture is modelled.