Jan-02-2020, 02:39 PM
I'm working on a data set from text files and I would like to:
1. Convert the dataset into an array in order to make .jpg images
2. Convert the grayscale into RBG
3. Convert dataset into 5000 jpg images (saved into laptop)
4. Use 1000 random RBG jpg images for the test data
5. Start using Keras for image classification using CNN, in order to classify images by its color.
So I'm stuck on step 2.
How could one convert 400 pixels values ranging from -1 to 1 into a RGB format? How could one encode this in hexadecimal or make it fit into a RGB triplets ?
1. Convert the dataset into an array in order to make .jpg images
2. Convert the grayscale into RBG
3. Convert dataset into 5000 jpg images (saved into laptop)
4. Use 1000 random RBG jpg images for the test data
5. Start using Keras for image classification using CNN, in order to classify images by its color.
So I'm stuck on step 2.
How could one convert 400 pixels values ranging from -1 to 1 into a RGB format? How could one encode this in hexadecimal or make it fit into a RGB triplets ?