Efficient Content-Based Image Retrieval From Videos Using Compact Deep Learning Networks With Re-Ranking