Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Refactor spatial related functions under spatial package #656

Merged
merged 23 commits into from
Aug 23, 2022
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
23 commits
Select commit Hold shift + click to select a range
0700863
Move trajectory into sub-package
isVoid Aug 15, 2022
6a9b0dd
Organize test files in the same folder structure
isVoid Aug 15, 2022
eb35b2c
Group interpolate under `trajectory` category.
isVoid Aug 15, 2022
a007d57
reorganize spline tests
isVoid Aug 15, 2022
265874a
Create new hierarchy for spatial functions
isVoid Aug 16, 2022
bf01510
Organize tests in the same hierarchy as code
isVoid Aug 16, 2022
b2017fb
Refactor `CubicSpline` to be independent of `trajectory` component.
isVoid Aug 16, 2022
943c5a8
Match test files structure
isVoid Aug 16, 2022
8125efe
style
isVoid Aug 16, 2022
dd78588
Merge branch 'refactor/trajectory' into refactor/spatial
isVoid Aug 17, 2022
4b77ee2
Update documentation
isVoid Aug 17, 2022
e0845f2
Update top level module visibility
isVoid Aug 17, 2022
060c562
Merge branch 'branch-22.10' of https://github.com/rapidsai/cuspatial …
isVoid Aug 18, 2022
bed6c62
add sections to spatial api reference
isVoid Aug 18, 2022
b14806d
Revert "Refactor `CubicSpline` to be independent of `trajectory` comp…
isVoid Aug 19, 2022
5915ce9
Revert "Move trajectory into sub-package"
isVoid Aug 19, 2022
9d3ab98
Expose spatial package to top level API
isVoid Aug 19, 2022
d673faa
style, license date
isVoid Aug 19, 2022
30c3f87
Add project wide config file for black
isVoid Aug 19, 2022
7b7f7eb
black format
isVoid Aug 19, 2022
a812008
renaming the files to new suggestion
isVoid Aug 23, 2022
516157a
Update docs/source/api_docs/spatial.rst
isVoid Aug 23, 2022
2219db0
Merge branch 'branch-22.10' of https://github.com/rapidsai/cuspatial …
isVoid Aug 23, 2022
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
1 change: 1 addition & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -13,6 +13,7 @@ repos:
hooks:
- id: black
files: python/cuspatial/.*
# Explicitly specify the pyproject.toml at the repo root, not per-project.
args: ["--config", "pyproject.toml"]
- repo: https://gitlab.com/pycqa/flake8
rev: 3.7.7
Expand Down
9 changes: 0 additions & 9 deletions docs/source/api_docs/gis.rst

This file was deleted.

3 changes: 1 addition & 2 deletions docs/source/api_docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,8 +9,7 @@ This page provides a list of all publicly accessible modules, methods and classe
:maxdepth: 2
:caption: API Documentation

gis
spatial_indexing
spatial
harrism marked this conversation as resolved.
Show resolved Hide resolved
trajectory
geopandas_compatibility
io
41 changes: 41 additions & 0 deletions docs/source/api_docs/spatial.rst
Original file line number Diff line number Diff line change
@@ -0,0 +1,41 @@
Spatial
-------

Functions that operate on spatial data.

.. currentmodule:: cuspatial

Spatial Indexing Functions
++++++++++++++++++++++++++
.. autofunction:: cuspatial.quadtree_on_points

Spatial Join Functions
++++++++++++++++++++++

.. autofunction:: cuspatial.point_in_polygon
.. autofunction:: cuspatial.quadtree_point_in_polygon
.. autofunction:: cuspatial.quadtree_point_to_nearest_polyline
.. autofunction:: cuspatial.join_quadtree_and_bounding_boxes

Measurement Functions
+++++++++++++++++++++

.. autofunction:: cuspatial.directed_hausdorff_distance
.. autofunction:: cuspatial.haversine_distance
.. autofunction:: cuspatial.pairwise_linestring_distance

Bounding Boxes
++++++++++++++

.. autofunction:: cuspatial.polygon_bounding_boxes
.. autofunction:: cuspatial.polyline_bounding_boxes

Projection Functions
++++++++++++++++++++

.. autofunction:: cuspatial.lonlat_to_cartesian

Spatial Filtering Functions
+++++++++++++++++++++++++++

.. autofunction:: cuspatial.points_in_spatial_window
15 changes: 0 additions & 15 deletions docs/source/api_docs/spatial_indexing.rst

This file was deleted.

16 changes: 7 additions & 9 deletions python/cuspatial/cuspatial/__init__.py
Original file line number Diff line number Diff line change
@@ -1,22 +1,20 @@
from ._version import get_versions
from .core import interpolate
from .core.gis import (
from .core.spatial import (
directed_hausdorff_distance,
haversine_distance,
join_quadtree_and_bounding_boxes,
lonlat_to_cartesian,
point_in_polygon,
pairwise_linestring_distance,
polygon_bounding_boxes,
polyline_bounding_boxes,
pairwise_linestring_distance,
)
from .core.indexing import quadtree_on_points
from .core.interpolate import CubicSpline
from .core.spatial_join import (
join_quadtree_and_bounding_boxes,
point_in_polygon,
points_in_spatial_window,
quadtree_on_points,
quadtree_point_in_polygon,
quadtree_point_to_nearest_polyline,
)
from .core.spatial_window import points_in_spatial_window
from .core.interpolate import CubicSpline
from .core.trajectory import (
derive_trajectories,
trajectory_bounding_boxes,
Expand Down
Loading