C3W1 Data channels dictionary setup

Hi,

I am having a little trouble with the Data channels dictionary setup part of the grading in the lab.The submission report states that “Test 1 failed: ‘‘train’’ was incorrectly defined. ‘‘validation’’ was incorrectly defined. Please try again” but when I check out the cell in the lab I have defined them using the “_uri” variables.Am I missing a space or something else?

https://labs.vocareum.com/main/main.php?m=clabide&mode=s&asnid=444555&stepid=444556&hideNavBar=1

https://d-vqivnj3udy54.studio.us-east-1.sagemaker.aws/jupyter/default/lab?#c3w1-ex-1

The instructions indicate to pass the S3 input paths into the TrainingInput function. Just passing the S3 locations alone is not sufficient. We need to wrap the corresponding S3 locations in a TrainingInput object.

2 Likes

Thank you! I should have read through the instructions more thoroughly

My pleasure. Keep the great work going! :smile:

A follow up to just to avoid creating a new thread

I have wrapped S3 input paths in TrainingInput object but still get the same error. My code is as below

from sagemaker.inputs import TrainingInput

data_channels = {
    ### BEGIN SOLUTION - DO NOT delete this comment for grading purposes
    'train': TrainingInput(s3_data=processed_train_data_s3_uri), # Replace None
    'validation': TrainingInput(s3_data=processed_validation_data_s3_uri) # Replace None
    ### END SOLUTION - DO NOT delete this comment for grading purposes
}

Any help would be appreciated. Thanks

I think if you submit once, then you need to run the whole notebook again. Otherwise, it will not see the changes. I am not sure. But after changing the TrainingInput(s3_data= …) it still shows me that I have got 0, then I ran the whole notebook again. After that, I have submitted and got the result 15/15. So try to rerun the notebook again. Maybe you will also get the full score.