Class QuadTreeRTPartitioning
- java.lang.Object
-
- org.apache.sedona.core.spatialPartitioning.QuadtreePartitioning
-
- org.apache.sedona.core.spatialPartitioning.QuadTreeRTPartitioning
-
- All Implemented Interfaces:
Serializable
public class QuadTreeRTPartitioning extends QuadtreePartitioning
The class is used to build an R-tree over a random sample of another dataset and uses distance bounds to ensure efficient local kNN joins.By calculating distance bounds and using circle range queries, it ensures that the subsets Si, containing all necessary points for accurate kNN results. The final union of local join results provides the complete kNN join result for the datasets R and S.
It generates List
- > expandedPartitionedBoundaries based on the quad tree.
- See Also:
- Serialized Form
-
-
Field Summary
-
Fields inherited from class org.apache.sedona.core.spatialPartitioning.QuadtreePartitioning
partitionTree
-
-
Constructor Summary
Constructors Constructor Description QuadTreeRTPartitioning(List<org.locationtech.jts.geom.Envelope> samples, org.locationtech.jts.geom.Envelope boundary, int partitions)
QuadTreeRTPartitioning(List<org.locationtech.jts.geom.Envelope> samples, org.locationtech.jts.geom.Envelope boundary, int partitions, int minTreeLevel)
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description org.locationtech.jts.index.strtree.STRtree
buildSTRTree(List<org.locationtech.jts.geom.Envelope> samples, int k)
This function is used to build the STR tree from the quad-tree built from the samples.HashMap<Integer,List<org.locationtech.jts.geom.Envelope>>
getMbrs()
org.locationtech.jts.index.strtree.STRtree
getMbrSpatialIndex()
double
getMinimalEnvelopeWidth(List<QuadRectangle> partitionMBRs)
This function is used to calculate the minimal envelope width of the partitioned MBRs.void
processPartitions(List<QuadRectangle> partitionMBRs, Map<Integer,List<org.locationtech.jts.geom.Envelope>> mbrs, int k, org.locationtech.jts.index.strtree.STRtree sampleTree, org.locationtech.jts.geom.GeometryFactory geometryFactory)
-
Methods inherited from class org.apache.sedona.core.spatialPartitioning.QuadtreePartitioning
getPartitionTree
-
-
-
-
Method Detail
-
getMbrSpatialIndex
public org.locationtech.jts.index.strtree.STRtree getMbrSpatialIndex()
-
buildSTRTree
public org.locationtech.jts.index.strtree.STRtree buildSTRTree(List<org.locationtech.jts.geom.Envelope> samples, int k)
This function is used to build the STR tree from the quad-tree built from the samples. It is used to expand the partitioned boundaries.- Parameters:
samples
- the samplesk
- the number of neighbor samples- Returns:
-
processPartitions
public void processPartitions(List<QuadRectangle> partitionMBRs, Map<Integer,List<org.locationtech.jts.geom.Envelope>> mbrs, int k, org.locationtech.jts.index.strtree.STRtree sampleTree, org.locationtech.jts.geom.GeometryFactory geometryFactory)
-
getMinimalEnvelopeWidth
public double getMinimalEnvelopeWidth(List<QuadRectangle> partitionMBRs)
This function is used to calculate the minimal envelope width of the partitioned MBRs.- Parameters:
partitionMBRs
-- Returns:
-
-