Read image files and write it into csv to be used for weka