问题
Following Hadoop: how to access (many) photo images to be processed by map/reduce? question, where orangeoctopus provides a reasonable direction to load the image binaries and collect them into SequenceFiles
to feed the mapper.
Think this could be useful for the others also, as a local java process or probably a hadoop job in case of vast amount image files, I created this separate question to look for the example for the implementation.
Thanks!
回答1:
Hadoop: The Definitive Guide - Chapter 4 has some samples for reading/writing sequence files. Here is the code for the same. Go through the code and change it for the binary images as input for the sequence file.
来源:https://stackoverflow.com/questions/8754154/hadoop-example-process-to-generating-a-sequencefile-with-image-binaries-to-be-p