The Scala object containing the main() method has the following workflow:
- We read all the business labels from the train.csv file
- We read and create a map from image ID to business ID of form imageID → busID
- We get a list of images from the photoDir directory to load and process and, finally, get the image IDs of 10,000 images (feel free to set the range)
- We then read and process images into a photoID → vector map
- We chain the output of step 3 and step 4 to align the business feature, image IDs, and label IDs to get the feature extracted for the CNN
- We construct nine CNNs.
- We train all the CNNs and specify the model savings locations
- We then repeat step 2 to step 6 to extract the features from the ...