mirror of
https://github.com/pytorch/pytorch.git
synced 2025-10-21 05:34:18 +08:00
Make emit_metrics importable without having boto3 installed (#107070)
Make it so that scripts can import and run the `emit_metrics` function even if they don't have boto3 installed, in which case it will still validate the inputs but skip the actual metric emission part. It's purely a refactor without any real logic changes Motivation: So that run_test.py and the target determination code can use this library easily without worrying about if it was imported or if it's dependencies are installed. Pull Request resolved: https://github.com/pytorch/pytorch/pull/107070 Approved by: https://github.com/huydhn
This commit is contained in:
committed by
PyTorch MergeBot
parent
3920ce2f6e
commit
5ddb8ef827
@ -13,7 +13,7 @@ from tools.shared.logging_utils import duration_to_str, pluralize
|
||||
from tools.stats.export_test_times import TEST_FILE_RATINGS_FILE
|
||||
|
||||
from tools.stats.import_test_stats import get_disabled_tests, get_slow_tests
|
||||
from tools.stats.upload_stats_lib import emit_metric
|
||||
from tools.stats.upload_metrics import emit_metric
|
||||
|
||||
REPO_ROOT = Path(__file__).resolve().parent.parent.parent
|
||||
|
||||
|
Reference in New Issue
Block a user