Created
January 22, 2019 14:01
-
-
Save adriaciurana/3b9faa625d1bbe508477c788250f3e44 to your computer and use it in GitHub Desktop.
Articulo Medium: Parte 5c
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
# Cargamos la imagen/imagenes | |
if os.path.isdir(args.image): | |
path_images = [] | |
for ext in ['jpg', 'jpeg', 'tiff', 'png', 'gif']: | |
path_images += glob.glob(os.path.join(args.image, "*." + ext)) | |
else: | |
path_images = [args.image] | |
images = [] | |
for path_im in path_images: | |
images.append(np.float32(cv2.resize(cv2.imread(path_im), (32, 32))[..., ::-1]/255.0)) |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment