Sounds like peculiar behaviour for sure.  I can't think of a reason for
this offhand.  Would need to see a sample dataset to see if the same
behaviour occurs in JTS.

Martin

On Wed, Sep 21, 2016 at 9:02 AM, Sandro Santilli <s...@kbt.io> wrote:

> Hi there,
> I'm writing to ask for help with STRtree as I'm seeing an unexpected
> number of matches from a _query and I'd like to check with you I'm
> not calling things the wrong way.
>
> I have an array of envelopes that I put in the index and then query
> them to find those that contain a point. The code, using GEOS, goes
> like this (pseudo):
>
>   tree = STRtree_create(10);
>   for each genv:
>     STRtree_insert(tree, genv, ring)
>
> Then upon querying the tree, containing about 1 milion envelopes,
> I often get an higher-than-expected number of matches from a query:
>
>   STRtree_query(tree, pt)
>
> In one case it got as high as almost the whole set:
>
>   Found 935029 candidate shells for containement of ring point POINT
> (1572657.1699999999254942 4808574.7900000000372529)
>
> Checking the point with other means tells me it's only contained by 11
> envelopes, not 935029. So, what could I be doing wrong to get such
> weird numbers ?
>
> --strk;
>
>   ()   Free GIS & Flash consultant/developer
>   /\   https://strk.kbt.io/services.html
>
------------------------------------------------------------------------------
_______________________________________________
Jts-topo-suite-user mailing list
Jts-topo-suite-user@lists.sourceforge.net
https://lists.sourceforge.net/lists/listinfo/jts-topo-suite-user

Reply via email to