Skip to main content

地理建模与可视化工具库

Project description

GeoModelingZ

这是一个地理建模与可视化工具库,专为Jupyter Notebook环境优化,提供了丰富的交互式地理数据可视化功能。

主要功能

  • 环境检测: 自动检测Jupyter Notebook环境
  • 交互式图表: 支持matplotlib交互式图表绘制
  • 地理地图可视化: 强大的交互式地理地图功能
  • GeoJSON支持: 完整支持GeoJSON数据格式
  • 多几何类型: 支持点、线、多边形和Multi类型几何数据
  • 自动聚焦: 智能聚焦到数据区域
  • 多底图支持: 支持Mapbox和OpenStreetMap等多种底图

安装

基本安装

pip install GeoModelingZ

安装Jupyter支持(推荐)

pip install GeoModelingZ[jupyter]

使用方法

交互式图表(主版本待开发)

from GeoModelingZ import plot_simple_chart

# 创建简单的交互式图表
fig = plot_simple_chart(title="我的图表")

# 在Jupyter环境中,可以交互调整参数
# 在普通环境中,返回matplotlib图表对象

地理地图可视化

from GeoModelingZ import create_geo_map

# 创建基本地图
map_obj = create_geo_map(
    width=1000, 
    height=700,
    center=[39.9042, 116.4074],  # 北京坐标
    zoom_start=10
)

# 加载GeoJSON数据
map_with_data = create_geo_map(
    geojson_file="path/to/your/data.geojson",
    mapbox_token="your_mapbox_token",  # 可选
    basemap='dark'
)

# 显示地图(在Jupyter中)
map_with_data

支持的GeoJSON几何类型

  • Point: 单点数据
  • MultiPoint: 多点数据
  • LineString: 线数据
  • MultiLineString: 多线数据
  • Polygon: 多边形数据
  • MultiPolygon: 复杂多边形数据

底图类型

  • streets: 矢量街道地图(默认)
  • satellite: 卫星影像地图
  • outdoors: 地形图
  • light: 浅色底图
  • dark: 深色底图
  • OpenStreetMap: 开源街道地图

依赖

  • Python >= 3.6
  • numpy
  • matplotlib
  • ipython
  • folium

可选依赖(用于Jupyter功能)

  • ipywidgets >= 7.0.0
  • jupyterlab_widgets

更新日志

v0.0.6

  • 重构代码结构,移除冗余功能
  • 专注于地理数据可视化核心功能
  • 优化GeoJSON数据处理逻辑
  • 改进地图渲染性能
  • 增强错误处理和调试信息

贡献

欢迎提交Issue和Pull Request来改进这个库!

许可证

MIT License

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

geomodelingz-0.0.6.tar.gz (8.9 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

geomodelingz-0.0.6-py3-none-any.whl (9.0 kB view details)

Uploaded Python 3

File details

Details for the file geomodelingz-0.0.6.tar.gz.

File metadata

  • Download URL: geomodelingz-0.0.6.tar.gz
  • Upload date:
  • Size: 8.9 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for geomodelingz-0.0.6.tar.gz
Algorithm Hash digest
SHA256 16d3c861aa6fd33309111abed65d588411b2bb0027c75e94384c10b87375a476
MD5 6a5a539d7266c4c4818b0f6b4b05a117
BLAKE2b-256 81bb3a1c91c610607d0f85857765f3ba09030cb73c5cf51c9c60a909f03ff5ba

See more details on using hashes here.

File details

Details for the file geomodelingz-0.0.6-py3-none-any.whl.

File metadata

  • Download URL: geomodelingz-0.0.6-py3-none-any.whl
  • Upload date:
  • Size: 9.0 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.13.2

File hashes

Hashes for geomodelingz-0.0.6-py3-none-any.whl
Algorithm Hash digest
SHA256 b909f6512b2d5400d4ed32058eab398c956960d5e9874caa81b68715e1a54eb8
MD5 750e7708dca751e543fab80ec4d8e9fa
BLAKE2b-256 dcf9d5db2a941d7812959cf913b23eb18ab6e2b102f2ced0ba74aee39c8741c1

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page