ethz-asl / hierarchical_loc

Deep image retrieval for efficient 6-DoF localization
BSD 3-Clause "New" or "Revised" License
177 stars 38 forks source link

Where to apply descriptor dimension reduction using PCA? #3

Closed jingedawang closed 5 years ago

jingedawang commented 6 years ago

I am not clearly about which place the descriptor dimension reduction is located in training process of MobileNetVLAD. Is it applied to global descriptor computed by teacher network, and then use the reduced descriptor as the supervision for student network? Or other places?

Looking forward to your reply. Thanks!

sarlinpe commented 6 years ago

1) The target descriptors are PCA-reduced NetVLAD descriptors, where the PCA parameters are provided by the original authors. MobileNetVLAD additionally contains a final projection layer to match the descriptor dimensionality.

2) PCA is also computed at test time. The parameters are estimated from the descriptors of the indexed keyframes and later applied to each query descriptor.

jingedawang commented 5 years ago

Thanks for your reply. One more question, is the final projection layer in MobileNetVLAD a convolutional layer? Or just a computation stage after the MobileNetVLAD network?

sarlinpe commented 5 years ago

Yes, it is a convolutional layer: https://github.com/ethz-asl/hierarchical_loc/blob/master/retrievalnet/retrievalnet/models/mobilenetvlad.py#L45