in src/hyperpod_nemo_adapter/utils/config_utils.py [0:0]
def _validate_model_type(model_type: Optional[str], hf_model_name_or_path: Optional[str]) -> None:
if model_type is None and hf_model_name_or_path is None:
msg = "model_type and hf_model_name_or_path are missing but at least one is required"
_logger.error(msg)
raise AttributeError(msg)
# Enums support the `in` operator starting with Python 3.12
if model_type is not None and model_type not in [key.value for key in ModelType]:
msg = (
f'Model "{model_type}" is not supported by SageMaker Model Parallel. Please ensure `use_smp_model` is False'
)
_logger.warning(msg)