BVLC/caffe — pull request #126 by kloudkl (2014-02-18 05:11:48+00:00)
Title: Add WARPLossLayer and gradient check test cases

This pull request chose to implement the Weighted Approximate Rank Pairwise (WARP) loss layer in response to issue #88 "Implement ranking loss layer". WARP[1] was applied in a similar manner for image annotation[2] and is also useful in image retrieval using text queries.

The only open source implementation of WARP loss that I found is in [the mrec recommender systems Python library from Mendeley](https://github.com/Mendeley/mrec/search?q=warp). WARP was used there to optimize a matrix factorization model and a hybrid ranking model.

Obeying the contributing protocol designed by @shelhamer in #101, I opened this work in progress PR to welcome comments to correct defects as early as possible and to guide my further development.

References:
[1] Jason Weston, Samy Bengio, and Nicolas Usunier. Wsabie: Scaling up to large vocabulary image annotation. In IJCAI, 2011.
[2] Yunchao Gong, Yangqing Jia, Sergey Ioffe, Alexander Toshev, Thomas Leung. Deep Convolutional Ranking for Multilabel Image Annotation. arXiv:1312.4894 [cs.CV]