shuishen
7 days ago deac984180e54dcb904f415c8f2e095b8b1661a7
capabilities/00-change-detection/README.md
@@ -1,6 +1,6 @@
# 变化检测
这是一个可独立运行的 CPU Demo,用 `geoai-py 0.42.0` 的 ChangeStar 接口对双期
这是一个可独立运行的 Demo,用 `geoai-py 0.42.0` 的 ChangeStar 接口对双期
影像生成变化概率栅格、二值变化栅格和变化图斑 GeoJSON。核心推理的能力边界为
**A(直接 GeoAI 能力)**;OpenCV 只负责普通 JPG 的特征配准和尺寸处理,Rasterio
负责网格对齐、栅格写出及清理后掩膜的一对一矢量化。
@@ -27,11 +27,19 @@
  --output .\shared\outputs\00-change-detection\validation-real-20260817
```
The retained CPU environment is always usable with `--device cpu`. When the
verified CUDA environment `.venvs/00-change-detection-cuda` is present and its
server-side probe succeeds, the console invokes that fixed interpreter with
`--device cuda`; otherwise it falls back to the fixed CPU interpreter. The CLI
also accepts `--device auto|cpu|cuda` and records both `requested_device` and
the actual `device` in `run_metadata.json`. CUDA changes execution speed, not
the trained ChangeStar weights or this Demo's accuracy claim.
带空间参考的双期 GeoTIFF 可显式使用 `--processing-mode geotiff --max-dimension 0`;
普通图片可使用 `--processing-mode image --max-dimension 2048`。省略模式时使用
`auto`,省略 `--max-dimension` 时普通图片默认 `1024`,带 CRS 的 GeoTIFF 默认保持原始尺寸。
首次运行会从 Hugging Face 缓存 ChangeStar `s1_s1c1_vitb` 权重;CPU 运行时间与
首次运行会从 Hugging Face 缓存 ChangeStar `s1_s1c1_vitb` 权重;运行时间与
机器和缩放参数有关。`--max-dimension` 默认 1024,`--tile-size` 默认 512,适合
先做代表性验证;增加尺寸或批量运行前应先人工检查配准和误报。每次运行可单独
选择 `0.01` 到 `0.99` 的变化概率阈值,默认值为 `0.5`;实际阈值会写入
@@ -70,6 +78,12 @@
   和矢量输出是否可读。该样本是近景边坡照片,不是 ChangeStar 训练分布,不能
   据此宣称工程变化检测准确率。
2026-08-25 GPU validation used the same real pair at 1024 px: CPU produced 674
changed pixels and one vector in 41.556 seconds; CUDA produced the same 674
pixels, one vector, and 755/769 registration inliers in 22.583 seconds. A
self-comparison on CUDA produced zero changed pixels and zero vectors. This is
output parity and runtime evidence only, not an accuracy benchmark.
控制台必须使用配准后的第二期作为栅格和矢量叠加底图;原始第二期只用于查看
输入。2026-08-20 的道路样本验证中,青色视觉差异层补充覆盖了车辆与部分人员
变化,但也出现道路边缘、阴影和局部配准残差,因此只能作为人工复核候选,不能