Пример #1
0
 def _get_ids(self):
     """Locate the ids of Experiments that match :attr:`algorithm_name` and :attr:`cross_experiment_key`"""
     self.experiment_ids = get_ids_by(
         leaderboard_path=self.leaderboard_path,
         algorithm_name=self.algorithm_name,
         cross_experiment_key=self.cross_experiment_key,
         hyperparameter_key=None)
 def _get_ids(self):
     """Get ids of Experiments matching :attr:`algorithm_name` and :attr:`cross_experiment_key`"""
     # TODO: If `sort`-ing chronologically, can use the "experiment_#" column in leaderboard
     self.experiment_ids = get_ids_by(
         leaderboard_path=self.leaderboard_path,
         algorithm_name=self.algorithm_name,
         cross_experiment_key=self.cross_experiment_key,
         hyperparameter_key=None,
     )
Пример #3
0
    def experiment_ids(self) -> List[str]:
        """Experiment IDs in the target Leaderboard that match :attr:`algorithm_name` and
        :attr:`cross_experiment_key`

        Returns
        -------
        List[str]
            All saved Experiment IDs listed in the Leaderboard at :attr:`leaderboard_path` that
            match the :attr:`algorithm_name` and :attr:`cross_experiment_key` of the template"""
        if self._experiment_ids is None:
            # TODO: If `sort`-ing chronologically, can use the "experiment_#" column in leaderboard
            self._experiment_ids = get_ids_by(
                leaderboard_path=self.leaderboard_path,
                algorithm_name=self.algorithm_name,
                cross_experiment_key=self.cross_experiment_key,
                hyperparameter_key=None,
            )

        return self._experiment_ids
def test_get_ids_by(params, expected):
    assert get_ids_by(leaderboard_path=path_lb_0,
                      **params) == [f"id_{_}" for _ in expected]