rstar-python 0.0.1__cp310-cp310-win_amd64.whl

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
@@ -0,0 +1,5 @@
1
+ from .rstar_python import *
2
+
3
+ __doc__ = rstar_python.__doc__
4
+ if hasattr(rstar_python, "__all__"):
5
+ __all__ = rstar_python.__all__
@@ -0,0 +1,110 @@
1
+ Metadata-Version: 2.4
2
+ Name: rstar-python
3
+ Version: 0.0.1
4
+ Classifier: Development Status :: 3 - Alpha
5
+ Classifier: Intended Audience :: Developers
6
+ Classifier: License :: OSI Approved :: MIT License
7
+ Classifier: Programming Language :: Python :: 3
8
+ Classifier: Programming Language :: Python :: 3.10
9
+ Classifier: Programming Language :: Python :: 3.11
10
+ Classifier: Programming Language :: Rust
11
+ Classifier: Operating System :: POSIX :: Linux
12
+ Classifier: Operating System :: MacOS
13
+ Classifier: Operating System :: Microsoft :: Windows
14
+ Requires-Dist: numpy>=1.21.6
15
+ License-File: LICENSE
16
+ Summary: Python bindings for the rstar R*-tree spatial index
17
+ Author-email: Kyle Harrington <kyle@kyleharrington.com>
18
+ Requires-Python: >=3.10
19
+ Description-Content-Type: text/markdown; charset=UTF-8; variant=GFM
20
+
21
+ # rstar-python
22
+
23
+ Python bindings for the [rstar](https://github.com/georust/rstar) R*-tree spatial index library.
24
+
25
+ ## Installation
26
+
27
+ ```bash
28
+ pip install rstar-python
29
+ ```
30
+
31
+ ## Usage
32
+
33
+ ```python
34
+ from rstar_python import PyRTree
35
+
36
+ # Create a 3D R-tree
37
+ tree = PyRTree(dims=3)
38
+
39
+ # Insert points
40
+ tree.insert([1.0, 2.0, 3.0])
41
+ tree.insert([4.0, 5.0, 6.0])
42
+
43
+ # Bulk load points
44
+ points = [
45
+ [1.0, 2.0, 3.0],
46
+ [4.0, 5.0, 6.0],
47
+ [7.0, 8.0, 9.0]
48
+ ]
49
+ tree.bulk_load(points)
50
+
51
+ # Find nearest neighbor
52
+ nearest = tree.nearest_neighbor([1.1, 2.1, 3.1])
53
+
54
+ # Find k nearest neighbors
55
+ k_nearest = tree.k_nearest_neighbors([1.1, 2.1, 3.1], k=2)
56
+
57
+ # Find neighbors within radius
58
+ neighbors = tree.neighbors_within_radius([1.0, 2.0, 3.0], radius=1.0)
59
+
60
+ # Query points within a bounding box
61
+ points = tree.locate_in_envelope(
62
+ min_corner=[0.0, 0.0, 0.0],
63
+ max_corner=[2.0, 2.0, 2.0]
64
+ )
65
+
66
+ # Get tree size
67
+ size = tree.size()
68
+
69
+ # Remove a point
70
+ tree.remove([1.0, 2.0, 3.0])
71
+ ```
72
+
73
+ ## Features
74
+
75
+ - Supports 1D to 4D points
76
+ - Fast nearest neighbor queries
77
+ - Radius search
78
+ - Bounding box queries
79
+ - Bulk loading for faster initialization
80
+ - Built on top of the fast Rust rstar library
81
+
82
+ ## Development
83
+
84
+ Requirements:
85
+ - Rust
86
+ - Python 3.7+
87
+ - maturin
88
+
89
+ ```bash
90
+ # Clone repository
91
+ git clone https://github.com/kephale/rstar-python
92
+ cd rstar-python
93
+
94
+ # Create virtual environment
95
+ python -m venv venv
96
+ source venv/bin/activate # or `venv\Scripts\activate` on Windows
97
+
98
+ # Install development dependencies
99
+ pip install maturin pytest
100
+
101
+ # Build and install in development mode
102
+ maturin develop
103
+
104
+ # Run tests
105
+ pytest
106
+ ```
107
+
108
+ ## License
109
+
110
+ This project is licensed under the MIT License - see the [LICENSE](LICENSE) file for details.
@@ -0,0 +1,6 @@
1
+ rstar_python-0.0.1.dist-info/METADATA,sha256=IbqxMy5FOX42_wZElE_jc8T_JgxzMfjRxN72p-MHZAk,2543
2
+ rstar_python-0.0.1.dist-info/WHEEL,sha256=EFCgXGXxeCwiKFSIXs99j9wi5CzhWN9wgZDTgX5-fdU,96
3
+ rstar_python-0.0.1.dist-info/licenses/LICENSE,sha256=1vNK5wtdii97XWiIu-tGrewxnElyhROT7asu56sopuQ,1097
4
+ rstar_python/__init__.py,sha256=0MwoQYtUD1d4BA0J-n31O_tQpso4nN2ttWSt5pWsLek,131
5
+ rstar_python/rstar_python.cp310-win_amd64.pyd,sha256=wFBtGEiTWAStQQaPGNQIWWM2pMC7UyhHugJbOVlhX6M,653824
6
+ rstar_python-0.0.1.dist-info/RECORD,,
@@ -0,0 +1,4 @@
1
+ Wheel-Version: 1.0
2
+ Generator: maturin (1.8.2)
3
+ Root-Is-Purelib: false
4
+ Tag: cp310-cp310-win_amd64
@@ -0,0 +1,21 @@
1
+ MIT License
2
+
3
+ Copyright (c) 2025 Kyle I S Harrington
4
+
5
+ Permission is hereby granted, free of charge, to any person obtaining a copy
6
+ of this software and associated documentation files (the "Software"), to deal
7
+ in the Software without restriction, including without limitation the rights
8
+ to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9
+ copies of the Software, and to permit persons to whom the Software is
10
+ furnished to do so, subject to the following conditions:
11
+
12
+ The above copyright notice and this permission notice shall be included in all
13
+ copies or substantial portions of the Software.
14
+
15
+ THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16
+ IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17
+ FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18
+ AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19
+ LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20
+ OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21
+ SOFTWARE.