Hi All,
I’m trying to do the “Get hands-on with computer vision (Lab 1)” but stuck with below error… appreciate assistance…
NameError: name ‘training_labels’ is not defined
Kind regards,
Om
Hi All,
I’m trying to do the “Get hands-on with computer vision (Lab 1)” but stuck with below error… appreciate assistance…
NameError: name ‘training_labels’ is not defined
Kind regards,
Om
Hello there,
This is normally an error that means you have not run the cell where the training_labels has been defined. ry to run all the previews cells above or even restarting the kernel and rerun from top -bottom all cells!
Hi @gent.spah
Thank you for your response.
I’m following the course and could see the training labels is not defined or not sure how to check this. Can I dm you pls?
@gent.spah is telling you to run all the cells from beginning one by one.
Kindly always share a screenshot of the error you get when posting your issue or query, it will help mentors to address your issue more efficiently.
Regards
DP
Thank you for your response @Deepti_Prasad
I indeed run all the cells, however I also have confusion if traning_labels is actually defined. I took the codes from the lessons…
error screenshot as below
Are you running this lab by writing the codes from the videos in your personal jupyter notebook??
Also in the cell#5 labels is misspelt as lables, kindly correct it
As you DM me that you are using your personal jupyter notebook, please make sure if you have correctly imported the images.
I would suggest to go through all videos and then experiment or learn on the personal jupyter environment as one would require necessary test files, metadata and images for your codes to work in your local jupyter environment.
Regards
DP
Hello @omsundaram
I didn’t know there was a message limit for new user even for post thread.
After your spelling correction the reason you are still getting the error is you need to have all the necessary metadata for fashion mnist files like images, other utils files in your local computer in one folder from where you could import the file into your local jupyter environment so the images are readable in the notebook, hence you are still getting the error.
As you have MSG limit. Let us(me or @gent.spah) know if you have issue doing the above necessary steps, for further guidance.
Another pointer as mentioned DM, the message limitation for learners have been given to avoid sending codes directly to mentors. If a mentor feels need to look at your codes then mentor will MSG you first asking for your codes to have a look as this is a part of comprehensive learning for the benefits of learners.
Regards
DP
Hi @Deepti_Prasad @gent.spah
Thank you for the guidance.
In cell #5 I changed from “train_images, train_labels” to “training_images,training labels” and it worked.
Thanks again!