Cnn in tensorflow

deep learning tensor flow.ipynb (172.6 KB)

in this scroll down to rock paper scissors example

why is it showing that all images belong to 1 class and then during model.fit
it is giving accuracy of only about 33%
pls can anyone help me out with this

1 Like

This is probably due to a bad string parsing. I would recommend to print all the files identified for class 0 and for class 1. If there are 0 files for 0 class, then the problem is the name of the files (bad string parsing).

1 Like

yes ,I tried printing the seperate files but it is showing file not found error

even though my file path is correct
but as soon as I add os.list_dir function then it throws this error

can you tell why this is so???

1 Like

The first rule of debugging is “Believe the error message”. If you don’t understand what it says, that’s the first problem you need to solve. Did you read the pathname there? It looks like your “join” operation used backslashes instead of forward slashes. Notice that the rest of the slashes you can see in the earlier part of the path are forward slashes. Maybe you’d be better off writing the string processing operations directly in python, so you can control that.

1 Like

thanks sir solved this problem

1 Like