• Type: New Feature
    • Status: Closed
    • Priority: Major
    • Resolution: Fixed
    • Affects Version/s: None
    • Fix Version/s: 5.1
    • Component/s: modules/spatial
    • Labels:
    • Lucene Fields:


      Lucene spatial's PrefixTree (grid) based strategies index data in a way highly amenable to faceting on grids cells to compute a so-called heatmap. The underlying code in this patch uses the PrefixTreeFacetCounter utility class which was recently refactored out of faceting for NumberRangePrefixTree LUCENE-5735. At a low level, the terms (== grid cells) are navigated per-segment, forward only with, so it's pretty quick and furthermore requires no extra caches & no docvalues. Ideally you should use QuadPrefixTree (or Flex once it comes out) to maximize the number grid levels which in turn maximizes the fidelity of choices when you ask for a grid covering a region. Conveniently, the provided capability returns the data in a 2-D grid of counts, so the caller needn't know a thing about how the data is encoded in the prefix tree. Well almost... at this point they need to provide a grid level, but I'll soon provide a means of deriving the grid level based on a min/max cell count.

      I recommend QuadPrefixTree with geo=false so that you can provide a square world-bounds (360x360 degrees), which means square grid cells which are more desirable to display than rectangular cells.


        1. LUCENE-6191__Spatial_heatmap.patch
          25 kB
          David Smiley
        2. LUCENE-6191__Spatial_heatmap.patch
          28 kB
          David Smiley
        3. LUCENE-6191__Spatial_heatmap.patch
          29 kB
          David Smiley

          Issue Links



              • Assignee:
                dsmiley David Smiley
                dsmiley David Smiley
              • Votes:
                1 Vote for this issue
                6 Start watching this issue


                • Created: