Nearest neighbor search on Earth's surface with a GPU
Project description
Vincenty nearest neighbor search using CUDA
Nearest neighbor search algorithm on Earth's surface that runs on a GPU and uses Vincenty's formula
Requirements
- CUDA-enabled GPU with compute capability 2.0 or above with an up-to-data Nvidia driver.
- CUDA toolkit
Installation
pip install vincenty_cuda_nns
Usage example
import geopandas as gpd
from vincenty_cuda_nns import CudaTree
df = gpd.read_file('points.geojson')
# data is array of points like [longitude, latitude]
data = np.stack(df['geometry']).astype(np.float32)
# build tree for the data
cuda_tree = CudaTree(data, leaf_size=4)
# query over the tree for nearest neighbor (including itself)
distances, indices = cuda_tree.query(n_neighbors=2)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
Built Distribution
Close
Hashes for vincenty_cuda_nns-0.1.1-py3-none-any.whl
Algorithm | Hash digest | |
---|---|---|
SHA256 | e3095506bae69515f059712cc6edfee974e07dbadc235e5c37d10140efecb7c0 |
|
MD5 | 2ca466624aa1d7106d6e497da450d730 |
|
BLAKE2b-256 | fafa1f01d7b91b8bf9a3a177db1991dfa5297ac97272de80d80ce24428f07560 |