in dags/pytorch_xla/configs/pytorchxla_torchbench_config.py [0:0]
def get_version_mapping(test_version):
"""Get version dependecies based on version type.
Args:
output_file: If not None, model installation message will be piped to a file.
Returns:
Version mapping of the version type.
Raises:
Version type not found value error.
"""
if test_version == VERSION.NIGHTLY:
version_mapping = VERSION_MAPPING.NIGHTLY
elif test_version == VERSION.R2_2:
version_mapping = VERSION_MAPPING.R2_2
elif test_version == VERSION.R2_3:
version_mapping = VERSION_MAPPING.R2_3
elif test_version == VERSION.R2_4:
version_mapping = VERSION_MAPPING.R2_4
elif test_version == VERSION.R2_5:
version_mapping = VERSION_MAPPING.R2_5
elif test_version == VERSION.R2_5_1:
version_mapping = VERSION_MAPPING.R2_5_1
elif test_version == VERSION.R2_6:
version_mapping = VERSION_MAPPING.R2_6
elif test_version == VERSION.R2_7:
version_mapping = VERSION_MAPPING.R2_7
else:
raise ValueError("version number does not exist in VERSION enum")
return version_mapping