Terrier Users :  Terrier Forum terrier.org
General discussion about using/developing applications using Terrier 
Proximity measure - Null Pointer Exception
Posted by: kelvin86 ()
Date: March 07, 2018 06:38AM

Hi,

I have a custom proximity measure - which is testing well but when trying to use it with terrier - it throws up a null pointer exception. Any thoughts?

DFRDependenceScoreModifier altered scores for 1000 documents
06:21:19.633 [main] INFO o.t.matching.PostingListManager - Query 158 with 5 terms has 5 posting lists
phrase term: public
phrase term: health
phrase term: emerg
phrase term: prepared
phrase term: respons
Error in uk.ac.gla.dcs.dsms.AvgMinDis java.lang.NullPointerException
java.lang.NullPointerException
at org.terrier.matching.FatUtils$BIterablePostingFromWritablePostingSlice.getPositions(FatUtils.java:578)
at uk.ac.gla.dcs.dsms.AvgMinDis.calculateDependence(AvgMinDis.java:40)
at org.terrier.matching.dsms.DependenceScoreModifier.doDependency(DependenceScoreModifier.java:307)
at org.terrier.matching.dsms.DependenceScoreModifier.modifyScores(DependenceScoreModifier.java:188)
at org.terrier.matching.FatFeaturedScoringMatching.doMatch(FatFeaturedScoringMatching.java:283)
at org.terrier.matching.FatFeaturedScoringMatching.match(FatFeaturedScoringMatching.java:319)
at org.terrier.querying.Manager.runMatching(Manager.java:705)
at org.terrier.applications.batchquerying.TRECQuerying.processQuery(TRECQuerying.java:674)
at org.terrier.applications.batchquerying.TRECQuerying.processQueryAndWrite(TRECQuerying.java:594)
at org.terrier.applications.batchquerying.TRECQuerying.processQueries(TRECQuerying.java:784)
at org.terrier.applications.TrecTerrier.run(TrecTerrier.java:396)
at org.terrier.applications.TrecTerrier.applyOptions(TrecTerrier.java:584)
at org.terrier.applications.TrecTerrier.main(TrecTerrier.java:229)



Edited 1 time(s). Last edit at 03/07/2018 06:40AM by kelvin86.

Options: ReplyQuote
Re: Proximity measure - Null Pointer Exception
Posted by: craigm ()
Date: March 14, 2018 09:01AM

Hi,

I think we discussed this in person in the lab. The problem is that are reading from a posting that does not have such a document, e.g. its reached the end.

Craig

Options: ReplyQuote


Sorry, only registered users may post in this forum.
This forum powered by Phorum.