Source code for qdpy.benchmarks.base

#    This file is part of qdpy.
#
#    qdpy is free software: you can redistribute it and/or modify
#    it under the terms of the GNU Lesser General Public License as
#    published by the Free Software Foundation, either version 3 of
#    the License, or (at your option) any later version.
#
#    qdpy is distributed in the hope that it will be useful,
#    but WITHOUT ANY WARRANTY; without even the implied warranty of
#    MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
#    GNU Lesser General Public License for more details.
#
#    You should have received a copy of the GNU Lesser General Public
#    License along with qdpy. If not, see <http://www.gnu.org/licenses/>.


## @file
# @brief Metadata shared by benchmark evaluators and search configuration.

__all__ = ["Benchmark"]

from qdpy.base import *


[docs] class Benchmark(object): """Describe an evaluator and compatible search and archive domains. :param fn: Evaluation callable used by the search. :param ind_domain: Common lower and upper genome coordinate bounds. :param fitness_domain: One interval per returned objective. :param features_domain: One interval per returned behaviour descriptor. :param default_task: The optimisation direction for the benchmark. """ fn: Callable ind_domain: DomainLike fitness_domain: Sequence[DomainLike] features_domain: Sequence[DomainLike] default_task: str def __init__(self, fn: Callable, ind_domain: DomainLike, fitness_domain: Sequence[DomainLike], features_domain: Sequence[DomainLike], default_task: str = "minimisation"): self.fn = fn # type: ignore self.ind_domain = ind_domain self.fitness_domain = fitness_domain self.features_domain = features_domain self.default_task = default_task
# MODELINE "{{{1 # vim:expandtab:softtabstop=4:shiftwidth=4:fileencoding=utf-8 # vim:foldmethod=marker