:py:mod:`causal_testing.surrogate.surrogate_search_algorithms` ============================================================== .. py:module:: causal_testing.surrogate.surrogate_search_algorithms .. autoapi-nested-parse:: Module containing implementation of search algorithm for surrogate search Module Contents --------------- Classes ~~~~~~~ .. autoapisummary:: causal_testing.surrogate.surrogate_search_algorithms.GeneticSearchAlgorithm .. py:class:: GeneticSearchAlgorithm(delta=0.05, config: dict = None) Bases: :py:obj:`causal_testing.surrogate.causal_surrogate_assisted.SearchAlgorithm` Implementation of SearchAlgorithm class. Implements genetic search algorithm for surrogate models. .. py:method:: search(surrogate_models: list[causal_testing.estimation.cubic_spline_estimator.CubicSplineRegressionEstimator], scenario: causal_testing.specification.scenario.Scenario) -> list Function which implements a search routine which searches for the optimal fitness value for the specified scenario :param surrogate_models: The surrogate models to be searched :param scenario: The modelling scenario .. py:method:: create_gene_types(surrogate_model: causal_testing.estimation.cubic_spline_estimator.CubicSplineRegressionEstimator, scenario: causal_testing.specification.scenario.Scenario) -> tuple[list, list] :staticmethod: Generate the gene_types and gene_space for a given fitness function and scenario :param surrogate_model: Instance of a CubicSplineRegressionEstimator :param scenario: The modelling scenario