We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
When running on Windows, the '/' will result in error, int() problem with string.
Workaround is to change '/' to double backslash '\\', specifically:
def get_class(img_path): return int(img_path.split('\\')[-2])
root_dir = 'GTSRB_Final_Training_Images\\GTSRB\\Final_Training\\Images\\'
all_img_paths = glob.glob(os.path.join(root_dir, '* \\ *.ppm'))
That fixed the int() error.
Coding solution will be:
def get_class(img_path): return int(img_path.split(os.sep)[-2])
as is, non issue.
all_img_paths = glob.glob(os.path.join(root_dir, os.path.join(' * ', ' *.ppm')))
Thanks.
The text was updated successfully, but these errors were encountered:
it's differnce bewteen windows and linux in path
Sorry, something went wrong.
No branches or pull requests
When running on Windows, the '/' will result in error, int() problem with string.
Workaround is to change '/' to double backslash '\\', specifically:
def get_class(img_path):
return int(img_path.split('\\')[-2])
root_dir = 'GTSRB_Final_Training_Images\\GTSRB\\Final_Training\\Images\\'
all_img_paths = glob.glob(os.path.join(root_dir, '* \\ *.ppm'))
That fixed the int() error.
Coding solution will be:
def get_class(img_path):
return int(img_path.split(os.sep)[-2])
as is, non issue.
all_img_paths = glob.glob(os.path.join(root_dir, os.path.join(' * ', ' *.ppm')))
Thanks.
The text was updated successfully, but these errors were encountered: