According to Geoff Hutchison: > On Fri, 18 Jan 2002, Gilles Detillieux wrote: > > As an aside, we've always operated under the assumption that the word > > location affected the word score somehow, but I can't find any code in > > htsearch that does this. > > It's not in htsearch. Remember that before 3.2, htsearch did no > scoring. So check htcommon/WordList.cc: > wordRef->WordCount++; > wordRef->Weight += int((1000 - location) * weight_factor); > if (location < wordRef->Location) > wordRef->Location = location;
Sorry, brain fart. Of couse the score is calculated in htdig in 3.1. However, it does seem pointless to store locations in db.wordlist and db.words.db if only htdig uses them. Even in an update dig, htdig only adds to db.wordlist for reparsed documents, and schedules the old word records for deletion, so the locations are only used internally by htdig. > > As far as I can tell, when the info is transfered > > from WordRecords to DocMatches, the location field is completely ignored. > > You might argue that htsearch should use a class that's slimmer than > WordRecord, but htdig certainly uses location. I had entertained thoughts > of using the location flag as well for speeding up hilight in excerpts in > htsearch, but since it's a 1/1000 location and not a character or word > location, I scrapped those plans. Well, yeah, I guess htmerge and htsearch would save memory by using a slimmer class for word records, but you'd also cut down the size of the databases. Hmm. A little too radical a change for 3.1.6, though, I think. -- Gilles R. Detillieux E-mail: <[EMAIL PROTECTED]> Spinal Cord Research Centre WWW: http://www.scrc.umanitoba.ca/~grdetil Dept. Physiology, U. of Manitoba Phone: (204)789-3766 Winnipeg, MB R3E 3J7 (Canada) Fax: (204)789-3930 _______________________________________________ htdig-dev mailing list [EMAIL PROTECTED] https://lists.sourceforge.net/lists/listinfo/htdig-dev
