基于 SAR 低后向散射特性的洪水范围制图:Otsu 阈值分割低 σ⁰ 水体 + 形态学去噪 + 可选 DEM 坡度排除,并矢量化为 GeoJSON。SAR flood extent mapping via Otsu thresholding of low backscatter, morphological cleanup and vectorization. 输出洪水二值 GeoTIFF + 面积统计 JSON + 范围 GeoJSON。
Coding
geoskill-sar-sea-ice-mapping
Try it从SAR σ⁰制图海冰类型与密集度:dB刻度三类Otsu分水面/新冰/多年冰,GLCM纹理精炼多年冰,滑窗计算冰密集度,输出海冰类型GeoTIFF、密集度GeoTIFF与面积统计JSON。SAR sea ice type and concentration mapping via multi-Otsu backscatter thresholds and GLCM texture.
What it does
从SAR σ⁰制图海冰类型与密集度:dB刻度三类Otsu分水面/新冰/多年冰,GLCM纹理精炼多年冰,滑窗计算冰密集度,输出海冰类型GeoTIFF、密集度GeoTIFF与面积统计JSON。SAR sea ice type and concentration mapping via multi-Otsu backscatter thresholds and GLCM texture.
The skill document
SAR 海冰制图 | SAR Sea Ice Mapping
Maps sea ice type and concentration from single-temporal SAR σ⁰ (linear power). Physical basis:
- Open water: specular reflection, very low σ⁰ (~−24 dB) and uniform texture.
- Young ice: newly formed ice surface, moderate σ⁰ and fairly uniform texture.
- Multi-year ice: repeatedly frozen and thawed, rough surface, high σ⁰ and strong texture.
Processing workflow:
- Three-class Otsu on a dB scale: 3-class Otsu on
10·log10(σ⁰)separates open water / young ice / multi-year ice (log scale + three thresholds prevent young ice from being merged into open water; bimodal scenes automatically fall back to 2 classes). - GLCM texture refinement: multi-year ice = high σ⁰ and high GLCM contrast; the remaining ice is classified as young ice.
--season summerraises the texture threshold (summer melt weakens texture, so multi-year ice is judged more conservatively). - Concentration: fraction of ice pixels within the
--windowsliding window (ice concentration ∈ [0,1]).
Dependencies / 依赖
pip install numpy rasterio scipy
Usage / 使用方法
Basic usage (bbox only, synthetic data auto-generated)
python geoskill-sar-sea-ice-mapping.py --bbox 120.0 75.0 122.0 77.0 --output-dir ./out
Example 1: synthetic data (offline, winter)
python geoskill-sar-sea-ice-mapping.py --bbox 120 75 122 77 --synthetic --season winter --output-dir ./syn
Example 2: real SAR σ⁰ imagery
python geoskill-sar-sea-ice-mapping.py --input sigma0_linear.tif --output-dir ./real
Example 3: summer scenario
python geoskill-sar-sea-ice-mapping.py --bbox 120 75 122 77 --season summer --output-dir ./summer --quiet
Example 4: custom concentration window
python geoskill-sar-sea-ice-mapping.py --bbox 120 75 122 77 --window 15 --output-dir ./w15 --quiet
Output / 输出
| File | Format | Description |
|---|---|---|
ice_type.tif | GeoTIFF (uint8) | Sea ice type (0=open water 1=young ice 2=multi-year ice), EPSG:4326 |
ice_concentration.tif | GeoTIFF (float32) | Ice concentration [0,1] |
ice_statistics.json | JSON | Per-class pixels / share / area, mean concentration, thresholds |
output-manifest.json | JSON | Run manifest |
Data Source / 数据源 / Source
- Real mode: local SAR σ⁰ GeoTIFF (linear power).
- Synthetic mode: locally generated sea-surface background + young / multi-year ice areas (with different σ⁰ and texture).
Privacy / 隐私声明 / Privacy
- Fully offline by default;
--syntheticmode makes no network calls. - All processing is done locally; no user data is uploaded.
License / License
MIT
name: geoskill-sar-sea-ice-mapping description: '从SAR σ⁰制图海冰类型与密集度:dB刻度三类Otsu分水面/新冰/多年冰,GLCM纹理精炼多年冰,滑窗计算冰密集度,输出海冰类型GeoTIFF、密集度GeoTIFF与面积统计JSON。SAR sea ice type and concentration mapping via multi-Otsu backscatter thresholds and GLCM texture.'
SAR 海冰制图 | SAR Sea Ice Mapping
从单时相 SAR σ⁰(线性功率)制图海冰类型与密集度。物理依据:
- 开放水面:镜面反射,σ⁰ 极低(~−24 dB)、纹理均匀。
- 新冰(young ice):初生冰面,σ⁰ 中等、纹理较均匀。
- 多年冰(multi-year ice):反复冻融、表面粗糙,σ⁰ 高且纹理强。
方法流程:
- dB 刻度三类 Otsu:在
10·log10(σ⁰)上用 3 类 Otsu 分水面 / 新冰 / 多年冰(对数刻度 + 三阈值避免新冰被并入水面;双峰场景自动回退 2 类)。 - GLCM 纹理精炼:多年冰 = 高 σ⁰ 且高 GLCM 对比度,其余冰判为新冰。
--season summer会提高纹理门限(夏季融冰减弱纹理,更保守判多年冰)。 - 密集度:
--window滑窗内冰像元占比(ice concentration ∈ [0,1])。
依赖
pip install numpy rasterio scipy
使用方法
基本用法(仅给 bbox,自动合成)
python geoskill-sar-sea-ice-mapping.py --bbox 120.0 75.0 122.0 77.0 --output-dir ./out
示例 1:合成数据(离线,冬季)
python geoskill-sar-sea-ice-mapping.py --bbox 120 75 122 77 --synthetic --season winter --output-dir ./syn
示例 2:真实 SAR σ⁰ 影像
python geoskill-sar-sea-ice-mapping.py --input sigma0_linear.tif --output-dir ./real
示例 3:夏季场景
python geoskill-sar-sea-ice-mapping.py --bbox 120 75 122 77 --season summer --output-dir ./summer --quiet
示例 4:自定义密集度窗口
python geoskill-sar-sea-ice-mapping.py --bbox 120 75 122 77 --window 15 --output-dir ./w15 --quiet
输出
| 文件 | 格式 | 说明 |
|---|---|---|
ice_type.tif | GeoTIFF (uint8) | 海冰类型(0=水面 1=新冰 2=多年冰),EPSG:4326 |
ice_concentration.tif | GeoTIFF (float32) | 冰密集度 [0,1] |
ice_statistics.json | JSON | 逐类像元 / 占比 / 面积、平均密集度、阈值 |
output-manifest.json | JSON | 运行清单 |
数据源 / Source
- 真实模式:本地 SAR σ⁰ GeoTIFF(线性功率)。
- 合成模式:本地生成海面背景 + 新冰 / 多年冰区(不同 σ⁰ 与纹理)。
隐私声明 / Privacy
- 默认完全离线运行,
--synthetic无任何网络。 - 所有处理本地完成,不上传用户数据。
License
MIT
Related skills
基于SAR后向散射与GLCM纹理的城市建成区提取:Otsu/固定σ⁰阈值 + GLCM对比度纹理 + 形态学闭运算,输出城市范围二值GeoTIFF与面积统计JSON。SAR urban/built-up mapping via backscatter threshold, GLCM texture and morphology.
多时相 SAR 后向散射时序统计:逐像元均值/标准差/振幅/变异系数与极化比。Multi-temporal SAR backscatter time-series statistics (mean/std/amplitude/CV) and polarization ratio. 输入多时相 σ⁰ 立方体(或用 --synthetic 生成含植被物候正弦信号的时序),输出多波段统计 GeoTIFF + 时序曲线 JSON。
SAR 船舶检测:CA/OS-CFAR 恒虚警检测 + 连通域聚类,从单极化 SAR 强度影像提取船舶目标并输出 GeoJSON 矢量与属性表
SAR 海面风场反演:基于简化 CMOD5/CMOD7 经验地球物理模型,由后向散射系数 σ⁰ 与风向二分法数值反演海面风速场
融合InSAR形变速率、后向散射变化与DEM坡度综合加权评分,双门限提取疑似滑坡连通域并矢量化分级(high/medium/low),输出滑坡GeoJSON、形变速率/风险评分GeoTIFF与风险汇总JSON。SAR landslide detection fusing InSAR deformation, backscatter change and slope.