diff --git a/brainscore_vision/benchmarks/lonnqvist2024/benchmark.py b/brainscore_vision/benchmarks/lonnqvist2024/benchmark.py index 73169adc5..9f22c1ae6 100644 --- a/brainscore_vision/benchmarks/lonnqvist2024/benchmark.py +++ b/brainscore_vision/benchmarks/lonnqvist2024/benchmark.py @@ -44,6 +44,9 @@ def __call__(self, candidate: BrainModel, return_raw_responses: bool = False): # Adjust score to ceiling ceiling = self.ceiling score = raw_score / ceiling + # ensure score <= 1.0 + if score.values > 1: + score = Score(np.array(1.)) score.attrs['raw'] = raw_score score.attrs['ceiling'] = ceiling if return_raw_responses: diff --git a/brainscore_vision/benchmarks/malania2007/benchmark.py b/brainscore_vision/benchmarks/malania2007/benchmark.py index 18bc9e7ee..7d6bc5f72 100644 --- a/brainscore_vision/benchmarks/malania2007/benchmark.py +++ b/brainscore_vision/benchmarks/malania2007/benchmark.py @@ -186,6 +186,9 @@ def __call__(self, candidate: BrainModel): # Adjust score to ceiling ceiling = self.ceiling score = raw_score / ceiling + # ensure score <= 1.0 + if score.values > 1: + score = Score(np.array(1.)) score.attrs['error'] = raw_score.error score.attrs['raw'] = raw_score