C3 week2 assignment Exercise 1

Why do I have this error, after replacing None by “PyTorch” and checking the other args in the function which seem compatible ? Thanks
Nicolas Bonjour

inference_image_uri = sagemaker.image_uris.retrieve(
### BEGIN SOLUTION - DO NOT delete this comment for grading purposes
framework=‘PyTorch’, # Replace None
### END SOLUTION - DO NOT delete this comment for grading purposes
version=‘1.6.0’,
instance_type=inference_instance_type,
region=region,
py_version=‘py3’,
image_scope=‘inference’
)
print(inference_image_uri)

FileNotFoundError Traceback (most recent call last)
in
7 region=region,
8 py_version=‘py3’,
----> 9 image_scope=‘inference’
10 )
11 print(inference_image_uri)

/opt/conda/lib/python3.7/site-packages/sagemaker/image_uris.py in retrieve(framework, region, version, py_version, instance_type, accelerator_type, image_scope, container_version, distribution, base_framework_version)
67 ValueError: If the combination of arguments specified is not supported.
68 “”"
—> 69 config = _config_for_framework_and_scope(framework, image_scope, accelerator_type)
70
71 original_version = version

1 Like

Hi Nicolas, you can try to replace the ‘PyTorch’ with ‘pytorch’, I saw this in another thread and it works for me. I guess the camel case is incorrect

Hi Tim,

Thks a lot! It works; I thought about this which takes 1 sec, but I regret to have not tried this idea!! And I wasted 1h30…
image
Regards,