All Questions
7 questions
1
vote
1
answer
130
views
How to cut and paste a part of an image randomly to a different location using tensorflow?
I am trying to implement a custom layer in keras.layers where I want to do a custom image augmentation. My idea is to cut out a part of an image from a random location and paste it to a different ...
1
vote
1
answer
1k
views
Image getting corrupted with tf.keras.preprocessing.image.save_img
I have an np array (a segmentation mask predicted by a model).
I have to save this mask (array) as an image for visualizing the result.
I am able to save the array as an image using, tf.keras....
2
votes
1
answer
318
views
how to pass an array instead of path in keras preprocessor
I want to convert an image that was loaded by cv2 into an specific format with keras preprocessor.
The keras.preprocessing.image.load_image() function takes input as path but i have only the numpy ...
0
votes
0
answers
982
views
Image distortion using PIL vs opencv
Edit- Attaching random pics from Flickr8k Dataset using the same transformations as discussed (can't share the original images - private dataset)
Output RGB image when loaded using Keras's generator ...
1
vote
2
answers
2k
views
ValueError: could not broadcast input array from shape (300,300,3) into shape (300,300)
I have a simple Python code (a Keras tutorial for training). I tried to remove img = img.convert('L') to keep colors when loading images (all my images are RGB colored so data is not the issue), but I ...
2
votes
1
answer
569
views
Difference in opencv and PIL affecting the model prediction
I've trained a model in Keras for image classification. The training was performed by loading the images using pillow. During deployment the images are loaded in opencv which drops the accuracy of the ...
2
votes
2
answers
7k
views
get a numpy array from a sequence of images in a folder
I have a folder, say video1 with bunch of images in order frame_00.png, frame_01.png, ...
What I want is a 4D numpy array in the format (number of frames, w, h, 3)
This is what I did, but I think ...