[Xapian-devel] LTR

Parth Gupta parthg.88 at gmail.com
Thu May 31 10:52:38 BST 2012

Hi Rishabh,

Very nice, As I said, you will need to change the parameters of the methods
as you go, you can safely change the questletor accordingly. The linking in
C++ might be different than Java, so you should start reading a bit about
it and feel free to ask us at the IRC or here if you get stuck.

Basically in the score() or the letor_score() the mset is transformed into
the appropriate format for libsvm and it is passed to it to get the
predicted label which is set back in the form of Map<docid, score>.

I might not get the chance to look at the code for a couple of days, so
best thing would be to just pass through our last discussion at IRC about
the code and you should be fine, because in that we discussed the modules
in quite detail. You might need to remove or add some variables according
to the need. Olly might be able to help you with the linking part.


On Thu, May 31, 2012 at 11:24 AM, Rishabh Mehrotra <erishabh at gmail.com>wrote:

> Hello,
> I had updated my fork at Git with the some what refactored code. Some
> errors still need to be removed. As of now I haven't modified the
> prepare_training_file method in letor_internals.cc at all.
> letor_score used to return a map<docid,double> and questletor was based on
> this structure, but when wehave ranklists this needed to change, but then I
> would have had to change the questletor file which I didn't want to(you had
> mentioned that letor.cc and questletor.cc will remain the same). I think
> this can be done once this refactored code is running properly.
> Also, in the SVMRanker.cc file, the rank function should have taken in
> Ranklist rl only as the parameter but as I wasn't able to understand the
> functioning of the code written inside letor_score(= now inside rank()) so
> as a temporary measure I have passed mset as well inside the rank function.
> Please have a look at the overall structure now and let me know the
> errors(linking part still needs to be done-C++ linking isn't much similar
> to Java). Also please have a look at SVMRanker.cc 's rank function and
> letor_internals.cc's prepare_training_file function as you would easily get
> to know what changes needs to be done in these methods, I didn't get much
> out of the code written in these modules.
> Regards,
> --
> Rishabh.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.xapian.org/pipermail/xapian-devel/attachments/20120531/5fbd61c5/attachment.htm>

More information about the Xapian-devel mailing list