Skip to main content

geokits

海事地理计算库(Rust + PyO3,Python 3.12+)。

港口属性判定(PortAttrs)

给定港口经纬度,一步算出全部管辖属性——建港时只需经纬度和名称:

from geokits import PortAttrs

pa = PortAttrs()  # 进程内建一个实例反复用(构造即加载内嵌边界,~毫秒级)
pa.lookup(121.5, 31.4)
# {'zone_name': 'North China & Far East', 'is_eu_mrv': False,
#  'is_fueleu_exclude': False, 'continent': 'ASIA'}
字段 类型 说明
zone_name str | None 海区名(12 海区词表,与 port.zone_name 一致)
is_eu_mrv bool 是否在 EU MRV 管辖边界内
is_fueleu_exclude bool 是否属 FuelEU 豁免区域(挪威/冰岛)
continent str | None 大洲(大写下划线词表:ASIA/EUROPE/…)
  • 边界多边形内嵌于 crate(data/*.geojson),无需外部数据源、无网络请求;单次 lookup 微秒级
  • pa.data_version 返回边界数据版本(YYYYMMDD),用于排查新旧不一致
  • 已处理跨 ±180° 经度环(PostGIS 导出会把 >180° 经度归一化为负值)
  • 实例无状态、线程安全,可全局共享

编译

maturin develop --release

数据更新

边界数据来自 weather-routing 库(zone + eu_geo_boundary 表),可再生成:

python scripts/export_boundaries.py   # 需本地 postgis 容器
cargo test                            # 回归

Metadata

Release files for geokits 0.5.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Built distributions (wheels)

Table of built distributions (wheels) for geokits 0.5.0
File Actions
geokits-0.5.0-cp312-cp312-win_amd64.whl CPython 3.12 CPython 3.12 Windows x86-64 Details for geokits-0.5.0-cp312-cp312-win_amd64.whl
geokits-0.5.0-cp312-cp312-manylinux_2_34_x86_64.whl CPython 3.12 CPython 3.12 Linux glibc 2.34+ x86-64 Details for geokits-0.5.0-cp312-cp312-manylinux_2_34_x86_64.whl
geokits-0.5.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl CPython 3.12 CPython 3.12 Linux glibc 2.17+ ARM64 Details for geokits-0.5.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
geokits-0.5.0-cp312-cp312-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl CPython 3.12 CPython 3.12 macOS 11.0+ ARM64, macOS 10.12+ x86-64, macOS 10.12+ universal2 (ARM64, x86-64) Details for geokits-0.5.0-cp312-cp312-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl

Total release size: 1.2 MB

Release files / geokits-0.5.0-cp312-cp312-win_amd64.whl

Download URL geokits-0.5.0-cp312-cp312-win_amd64.whl
Size 175.8 kB
Tags CPython 3.12 Windows x86-64
SHA-256 checksum
How to use checksums
c004594691e6ec6be41cea284cbb98ab563b5137f10a3f513838d2d88735ca9a
BLAKE2b-256 checksum
How to use checksums
33a6c8fb1b724216af8019d504182b10aea6f1b8d58308dd783fcfa68b946ecb
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.2 {"installer":{"name":"uv","version":"0.11.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / geokits-0.5.0-cp312-cp312-manylinux_2_34_x86_64.whl

Download URL geokits-0.5.0-cp312-cp312-manylinux_2_34_x86_64.whl
Size 278.7 kB
Tags CPython 3.12 Linux glibc 2.34+ x86-64
SHA-256 checksum
How to use checksums
d4586d119e1632b21103dac1bd63aeb1dd6d235e126114234cdbbe9b08b93f9b
BLAKE2b-256 checksum
How to use checksums
8a796c742b74ff549063cceba59f5515d0995f4eeccb0774eddf3086b6b063a1
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.2 {"installer":{"name":"uv","version":"0.11.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / geokits-0.5.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl

Download URL geokits-0.5.0-cp312-cp312-manylinux_2_17_aarch64.manylinux2014_aarch64.whl
Size 262.7 kB
Tags CPython 3.12 Linux glibc 2.17+ ARM64
SHA-256 checksum
How to use checksums
5fcbc83398c426f5af11068f3bda8d986f4c34eacb09ffeaad1108836e507ca5
BLAKE2b-256 checksum
How to use checksums
4fbbece728ce47d3db4b447d106640ab46c6f82837f1d6ff2e18281041cbac3c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.2 {"installer":{"name":"uv","version":"0.11.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Release files / geokits-0.5.0-cp312-cp312-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl

Download URL geokits-0.5.0-cp312-cp312-macosx_10_12_x86_64.macosx_11_0_arm64.macosx_10_12_universal2.whl
Size 472.9 kB
Tags CPython 3.12 macOS 10.12+ universal2 (ARM64, x86-64) macOS 10.12+ x86-64 macOS 11.0+ ARM64
SHA-256 checksum
How to use checksums
acb46f4592b95a79c0462a502f9f3825f90efdae965cce03409822ed3cc6a624
BLAKE2b-256 checksum
How to use checksums
71aefaa0a1019c4e9d4edf8814203554e5ca29b670087fa62933c12e393d956e
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via uv/0.11.2 {"installer":{"name":"uv","version":"0.11.2","subcommand":["publish"]},"python":null,"implementation":{"name":null,"version":null},"distro":{"name":"macOS","version":null,"id":null,"libc":null},"system":{"name":null,"release":null},"cpu":null,"openssl_version":null,"setuptools_version":null,"rustc_version":null,"ci":null}

Security for geokits 0.5.0

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

No provenance found

None of the files in this release were uploaded with provenance metadata.

A note on package security

PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.

To learn more about protecting yourself from malicious actors, visit our package security documentation.

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page