matlab code for Spatial Tensor Aggregation: D. Picard, "Preserving local spatial information in image similarity using tensor aggregation of local features," 2016 IEEE International Conference on Image Processing (ICIP), Phoenix, AZ, USA, 2016, pp. 201-205. DOI: 10.1109/ICIP.2016.7532347
make_tensor_cnn.m provides a basic example. You have to change global variables to match the directories of the images on your computer and tweak some parameters. Running the script as is should lead to >70% mAp on holidays.