please do not send multiple inbox message, once you have sent, follow the same message to send further message.
I checked your notebook, yours’ root directory code lines are incorrect, and that is why in the error it shows there is no such file or directory.
you don’t need to define train dir and root directory separately. there is a hint mentioned there below the start code here.
HINT:
Use os.makedirs to create your directories with intermediate subdirectories
Don’t hardcode the paths. Use os.path.join to append the new directories to the root_path parameter
so you hardcode the root path.
THIS IS THE FIRST CODE LINE
os.makedirs(root_path)
THE NEXT CODE LINE SHOULD MAKE DIRECTORY WHICH MENTIONS THE DIRECTORY, AND THE PATH (os.path.join) which again joins to the root path and the file you want to create, i.e training, validation, training/cats, etc.
I have given you indirect hints to write the correct code.
this is just before your split data graded cell.
your split data graded cell code is also incorrect
use these hints
Hints:
os.listdir(DIRECTORY)
returns a list with the contents of that directory.os.path.getsize(PATH)
returns the size of the filecopyfile(source, destination)
copies a file from source to destinationrandom.sample(list, len(list))
shuffles a list
if you still do not get, let us know.
P.S if you search properly here, all these errors are already encountered by others and answer previously by mentors. go through those post, it will help you solve those errors. For eg, you have a split data error, then in search column type split_data tf1, course 2 week 1, you will get all the people who have encountered the error.
Regards
DP