My data is in the format of csv file (sam,1,34,there,hello). I want to add an image to each row in the csv file using hadoop. Does any body have any idea about it. I have seen about Hipi which process the image files and adds it also. But I want to add as a column to csv file.
Asked
Active
Viewed 175 times
1 Answers
0
If you have to use CSV file, consider using Base64 encoding over binary image data - it will give you a printable string. But in general I would recommend you to switch to sequence file, there you would be able to store the image directly in a binary format

0x0FFF
- 4,948
- 3
- 20
- 26
-
Any example do you have? – G Krishna Sampath Jan 13 '15 at 09:55
-
Here's an example for Base64: http://stackoverflow.com/questions/10226046/java-convert-image-to-base64 – 0x0FFF Jan 13 '15 at 09:58
-
Here's an example with sequence file: http://stackoverflow.com/questions/16546040/store-images-videos-into-hadoop-hdfs – 0x0FFF Jan 13 '15 at 09:58