360 Secure SkillHub
360 安全技能中心

geoskill-urban-ventilation-corridor

从本地建筑高度与平面面积密度 GeoTIFF 推导空气动力学粗糙度和通风潜力,按简化 Macdonald 公式计算 z0,使用 8 邻域 Dijkstra 在阻力栅格上提取最小阻力通风廊道,输出 GeoTIFF、GeoJSON、统计 JSON 和运行清单;支持合成数据离线运行。

ruiduobao
ruiduobao
热度 13.45
最近更新 2026-08-05 01:08:50
分类:数据依赖:代码执行 / 读写文件应用场景:数据处理 / 工作流 / 研究

安装技能

复制下面的话术发给你的 Agent,它会通过 secure-skills 检索并安装该技能。

执行命令安装此 skill: npx secure-skills-cli add geoskill-urban-ventilation-corridor
Metadata
name
geoskill-urban-ventilation-corridor
description
Derive aerodynamic roughness and ventilation potential from building morphology and extract least-resistance ventilation corridors.

城市通风廊道分析 | Urban Ventilation Corridor Analysis

Derives aerodynamic roughness and ventilation potential from building morphology and extracts least-resistance ventilation corridors, supporting urban ventilation planning and thermal environment mitigation.

Core algorithm: roughness follows the simplified Macdonald empirical formula z0 = 0.1×building height×plan area density; ventilation potential VP = exp(−k×z0), monotonically decreasing with roughness; an 8-neighborhood Dijkstra on the resistance raster (1−VP+ε) finds the least-resistance path from the upwind edge to the downwind edge as the ventilation corridor. Corridor geometry is built with shapely and output as GeoJSON.

Dependencies / 依赖

pip install 'numpy' 'rasterio' 'shapely'

Usage / 使用方法

Basic Usage

python geoskill-urban-ventilation-corridor.py --bbox 116.0 39.0 117.0 40.0 [other parameters]

Examples

Example 1 (Synthetic Data (Offline))

python geoskill-urban-ventilation-corridor.py --bbox 116.0 39.0 117.0 40.0 --synthetic --output-dir ./out

Example 2 (Usage 2)

python geoskill-urban-ventilation-corridor.py --input height.tif --footprints fp.tif --output-dir ./out

Example 3 (Usage 3)

python geoskill-urban-ventilation-corridor.py --bbox 121.0 31.0 122.0 32.0 --decay-k 0.8 --output-dir ./out --quiet

Example 4 (Usage 4)

python geoskill-urban-ventilation-corridor.py --input height.tif --roughness-coeff 0.15 --output-dir ./out

Example 5 (Usage 5)

python geoskill-urban-ventilation-corridor.py --bbox 116.0 39.0 117.0 40.0 --synthetic --output-dir ./out --quiet

Output / 输出

File Format Description
ventilation.tif GeoTIFF Two bands: band1=roughness z0, band2=ventilation potential VP
corridor.geojson GeoJSON Least-resistance ventilation corridor (LineString, built with shapely)
ventilation_stats.json JSON Mean roughness, mean ventilation potential, corridor cost/vertex count
output-manifest.json JSON Run manifest

Data Source / 数据源 / Source

Local building height + plan area density GeoTIFFs; --synthetic mode generates an urban scene containing a low-rise ventilation green belt.

Privacy / 隐私声明 / Privacy

  • Runs offline by default; --synthetic mode requires no network at all.
  • All processing is done locally; user data is never uploaded.

License / License

MIT



name: geoskill-urban-ventilation-corridor description: 'Derive aerodynamic roughness and ventilation potential from building morphology and extract least-resistance ventilation corridors.'

城市通风廊道分析 | Urban Ventilation Corridor Analysis

从建筑形态推导空气动力学粗糙度与通风潜力,并提取最小阻力通风廊道,服务于城市通风规划与热环境缓解。

核心算法:粗糙度采用 Macdonald 经验式简化 z0 = 0.1×建筑高度×平面面积密度;通风潜力 VP = exp(−k×z0),随粗糙度单调递减;在阻力栅格(1−VP+ε)上用 8 邻域 Dijkstra 求上风缘到下风缘的最小阻力路径作为通风廊道。廊道几何用 shapely 构建并输出 GeoJSON。

依赖

pip install 'numpy' 'rasterio' 'shapely'

使用方法

基本用法

python geoskill-urban-ventilation-corridor.py --bbox 116.0 39.0 117.0 40.0 [其他参数]

示例

示例 1(合成数据(离线))

python geoskill-urban-ventilation-corridor.py --bbox 116.0 39.0 117.0 40.0 --synthetic --output-dir ./out

示例 2(用法 2)

python geoskill-urban-ventilation-corridor.py --input height.tif --footprints fp.tif --output-dir ./out

示例 3(用法 3)

python geoskill-urban-ventilation-corridor.py --bbox 121.0 31.0 122.0 32.0 --decay-k 0.8 --output-dir ./out --quiet

示例 4(用法 4)

python geoskill-urban-ventilation-corridor.py --input height.tif --roughness-coeff 0.15 --output-dir ./out

示例 5(用法 5)

python geoskill-urban-ventilation-corridor.py --bbox 116.0 39.0 117.0 40.0 --synthetic --output-dir ./out --quiet

输出

文件 格式 说明
ventilation.tif GeoTIFF 双波段:band1=粗糙度 z0,band2=通风潜力 VP
corridor.geojson GeoJSON 最小阻力通风廊道(LineString,shapely 构建)
ventilation_stats.json JSON 平均粗糙度、平均通风潜力、廊道代价/顶点数
output-manifest.json JSON 运行清单

数据源 / Source

本地建筑高度 + 平面面积密度 GeoTIFF;--synthetic 模式生成含低矮通风绿带的城区场景。

隐私声明 / Privacy

  • 默认离线运行,--synthetic 模式完全无网络。
  • 所有处理在本地完成,不上传用户数据。

License

MIT