search for: get_percent

Displaying 15 results from an estimated 15 matches for "get_percent".

2012 Mar 16
1
MSetIterator::get_percent Shows Increased Values When Using Query::OP_FILTER
...d behavior with respect to the match percent that is returned when performing a simple query. It appears that the addition of a filter to a simple OR query will not affect the weight of the match, but will increase the percent of the resulting match. According to the documentation for MSetIterator::get_percent ( http://xapian.org/docs/apidoc/html/classXapian_1_1MSetIterator.html#99514c11a9291175d20fafa73a0839fd) a match should only get 100% if it matches all of the weight contributing terms in the query. I've attached a test case that shows the odd behavior that I am seeing. I had a database with 2...
2007 Sep 30
1
Perl example of using termitrator?
...{ string term = *termIt; } Or something similar. However when I attempt to translate that into perl, I am trying:( I am working in the blind here) foreach my $match ( @matches ) { my %hit; my %ht; my $doc = $match->get_document(); my $per = $match->get_percent(); my $id = $match->get_docid(); my $bterm = $enq->get_matching_terms_begin($id); for(my $xit=$bterm;$xit != $enq->get_matching_terms_end($id);$xit++) { my $term=$xit; print $term; } Which doesn't really make any sense. Xit is...
2006 Jan 31
1
retrieving attributes of searchresults
...ire($q); my $mset = $enq->get_mset(0,999); my @matches; tie(@matches, 'Search::Xapian::MSet::Tied', $mset); foreach my $match (@matches) { my $doc = $match->get_document(); printf "ID %d %d%% [ %s ]\n", $match->get_docid(), $match->get_percent(), $doc->get_data(); } warn scalar @matches; ------------>8-------------------------------------------------------
2007 Feb 02
1
Working demo of search engine using boolean query.
...; print "Total: $total results found.\n------------------------\n"; my @matches = $enq->matches(0, 15); #------------------------------------------------------------------------------# foreach my $match ( @matches ) { printf "ID %d %d%%", $match->get_docid(), $match->get_percent(); my $doc = $match->get_document(); printf " [ %s ]", $doc->get_data(); print "\n"; } #------------------------------------------------------------------------------#
2009 Mar 02
0
Xapian, PHP bindings and
...$i = $matches->begin(); while ( ! $i->equals($matches->end())) { $n = $i->get_rank() + 1; $data = $i->get_document()->get_data(); echo "$n: {$i->get_percent()}% docid={$i->get_docid()} [$data]<br />"; echo "<br />\n\n"; $i->next(); } } catch (Exception $e) { print $e->getMessage() . "<br />\n";...
2007 Feb 09
1
PHP Binding and dbi2omega questions
...echo 'TERMS: '.$terms.'<br/>'; // Loop the matches and output some data.. for ($i = $mset->begin(); !$i->equals($mset->end()); $i->next()) { echo '<hr/> Document ID '.$i->get_docid().'<br/>'; echo $i->get_percent().'% <br/>'; $doc = $i->get_document(); echo $doc->get_data(); } ?> The echo $doc->get_data() output is as follows: content=blah blah blah id=1 title=My Title Is that data accessible via xapian bindings directly i.e. $data->content or $data->ti...
2015 Jan 16
2
Question on "single writer, multiple reader"
...lts found" << endl; for (Xapian::MSetIterator i = matches.begin(); i != matches.end(); ++i) { Xapian::Document doc = i.get_document(); cout << "Document ID " << *i << "\t" << i.get_percent() << "% [" << doc.get_data() << "]" << endl; } }
2014 Apr 13
2
Adding an external library to Xapian
...mmer("english"); @@ -88,19 +107,19 @@ cout << matches.get_matches_estimated() << " results found:" << endl; for (Xapian::MSetIterator i = matches.begin(); i != matches.end(); ++i) { - cout << i.get_rank() + 1 << ": " << i.get_percent() << "% docid=" << *i - << " [" << i.get_document().get_data() << "]\n\n"; + cout << i.get_rank() + 1 << ": " << i.get_percent() << "% docid=" << *i + << " [" <&...
2015 Jan 20
2
Question on "single writer, multiple reader"
On Sun, Jan 18, 2015 at 04:25:29PM +0000, James Aylett wrote: > That?s exactly how it?s supposed to work. ?Eventually? (once the > writer gets sufficiently far ahead of the reader), the reader will get > a DatabaseModifiedError and will have to re-open the database, but > until then it?s up to it when it does so. You may wish to do it every > N requests, or every K seconds, or only
2014 Apr 13
2
Adding an external library to Xapian
My code is not on Github. I am using the tarball as of now. The following it the error that occurred: http://pastebin.com/cVJrjUZX On Sun, Apr 13, 2014 at 8:16 PM, James Aylett <james-xapian at tartarus.org>wrote: > On 13 Apr 2014, at 15:37, Pallavi Gudipati <pallavigudipati at gmail.com> > wrote: > > > A linker error is encountered even after following the above
2011 Apr 21
1
How to Retrieve content of the document?
...enq->get_query()->get_description(); my @matches = $enq->matches(0, 10); print scalar(@matches) . " results found\n"; foreach my $match ( @matches ) { my $doc = $match->get_document(); printf "ID %d %d%% [ %s ] \n", $match->get_docid(), $match->get_percent(), $doc->get_data(); } This returns to me 8 documents which I know is the correct answer becuase I have made a search engine which gives me the same results. The problem is i only get the document numbers(ids) but not the content. the $doc->get_data(); is supposed to give me the content if...
2008 Sep 27
3
Query::MatchAll
Why there still been rank when using Query::MatchAll() ?
2006 Nov 30
1
PHP / XapianQueryParser
...;<br/>"; $oiter = new XapianMSetIterator();$oiter = $omset->begin(); while (!$oiter->equals($omset->end())){ $odoc = $oiter->get_document(); //Loop through values. echo "Rank: " . $oiter->get_rank() . "<br/>"; echo "%: " . $oiter->get_percent() . "<br/>"; echo "Desc: " . $oiter->get_description() . "<br/>"; $data = $odoc->get_data(); echo $data; echo $odoc->termlist_count() . "<br/>"; echo $odoc->values_count() . "<br/>"; $ovalues = $odoc->v...
2013 Aug 26
2
Perl interface isn't working in 1.2.x
On 08/25/2013 05:02 PM, Olly Betts wrote: > So the simple fix is > probably just to install the perl-Search-Xapian RPM instead. Thanks, the Centos 6 repos don't have that rpm and the http://xapian.org/download page seems to only cover the XS bindings, if I am reading this correctly: But I was able to remove the rpm packages and compile and install the core and swig from source.
2004 Oct 18
1
xapian-bindings compile creates 34mb xapian_wrap.o file?
Questions are threaded into the output: ******************** #./configure --without-python checking for a BSD-compatible install... /usr/bin/install -c checking whether build environment is sane... yes checking for gawk... no checking for mawk... mawk checking whether make sets $(MAKE)... yes checking build system type... i686-pc-linux-gnu checking host system type... i686-pc-linux-gnu checking