From 959554b672a65f87b486a91dc7404e91928e3687 Mon Sep 17 00:00:00 2001 From: Sam Winebrake <85908068+samwinebrake@users.noreply.github.com> Date: Thu, 3 Oct 2024 11:45:15 -0400 Subject: [PATCH 1/4] Update endpoints.py --- brainscore_core/submission/endpoints.py | 1 + 1 file changed, 1 insertion(+) diff --git a/brainscore_core/submission/endpoints.py b/brainscore_core/submission/endpoints.py index cfd3e0a1..d1684d01 100644 --- a/brainscore_core/submission/endpoints.py +++ b/brainscore_core/submission/endpoints.py @@ -25,6 +25,7 @@ update_score) logger = logging.getLogger(__name__) +logger.setLevel(logging.INFO) class UserManager: From fd387b03f5701c2e912fd0d9a3788e4507e91e79 Mon Sep 17 00:00:00 2001 From: Sam Winebrake <85908068+samwinebrake@users.noreply.github.com> Date: Thu, 3 Oct 2024 13:28:44 -0400 Subject: [PATCH 2/4] testing warning level --- brainscore_core/submission/endpoints.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/brainscore_core/submission/endpoints.py b/brainscore_core/submission/endpoints.py index d1684d01..0b34399f 100644 --- a/brainscore_core/submission/endpoints.py +++ b/brainscore_core/submission/endpoints.py @@ -184,7 +184,7 @@ def _score_model_on_benchmark(self, model_identifier: str, benchmark_identifier: model_identifier=model_identifier, benchmark_identifier=benchmark_identifier) score_entry.end_timestamp = datetime.now() # store in database - logger.info(f'Score from running {model_identifier} on {benchmark_identifier}: {score_result}') + logger.warning(f'Score from running {model_identifier} on {benchmark_identifier}: {score_result}') update_score(score_result, score_entry) except Exception as e: stacktrace = traceback.format_exc() From 6ac2f95a338b78d765f28085be4d682c0623a900 Mon Sep 17 00:00:00 2001 From: Sam Winebrake <85908068+samwinebrake@users.noreply.github.com> Date: Mon, 7 Oct 2024 09:26:58 -0400 Subject: [PATCH 3/4] Update endpoints.py --- brainscore_core/submission/endpoints.py | 2 ++ 1 file changed, 2 insertions(+) diff --git a/brainscore_core/submission/endpoints.py b/brainscore_core/submission/endpoints.py index 0b34399f..01f45611 100644 --- a/brainscore_core/submission/endpoints.py +++ b/brainscore_core/submission/endpoints.py @@ -154,6 +154,7 @@ def _score_model_on_benchmark(self, model_identifier: str, benchmark_identifier: public: bool, competition: Union[None, str]): # TODO: the following is somewhat ugly because we're afterwards loading model and benchmark again # in the `score` method. + logger.setLevel(logging.INFO) logger.info(f'Model database entry') model = self.domain_plugins.load_model(model_identifier) model_entry = modelentry_from_model(model_identifier=model_identifier, domain=domain, @@ -184,6 +185,7 @@ def _score_model_on_benchmark(self, model_identifier: str, benchmark_identifier: model_identifier=model_identifier, benchmark_identifier=benchmark_identifier) score_entry.end_timestamp = datetime.now() # store in database + print('test') logger.warning(f'Score from running {model_identifier} on {benchmark_identifier}: {score_result}') update_score(score_result, score_entry) except Exception as e: From a1c54a17a59a23b8ef222cd448676e32d720860e Mon Sep 17 00:00:00 2001 From: Sam Winebrake <85908068+samwinebrake@users.noreply.github.com> Date: Mon, 7 Oct 2024 09:41:39 -0400 Subject: [PATCH 4/4] switching to print statement for now --- brainscore_core/submission/endpoints.py | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/brainscore_core/submission/endpoints.py b/brainscore_core/submission/endpoints.py index 01f45611..545930eb 100644 --- a/brainscore_core/submission/endpoints.py +++ b/brainscore_core/submission/endpoints.py @@ -185,8 +185,7 @@ def _score_model_on_benchmark(self, model_identifier: str, benchmark_identifier: model_identifier=model_identifier, benchmark_identifier=benchmark_identifier) score_entry.end_timestamp = datetime.now() # store in database - print('test') - logger.warning(f'Score from running {model_identifier} on {benchmark_identifier}: {score_result}') + print(f'Score from running {model_identifier} on {benchmark_identifier}: {score_result}') update_score(score_result, score_entry) except Exception as e: stacktrace = traceback.format_exc()