pgh_raster
PgHydro 栅格水文分析扩展
概览
| ID | 扩展名 | Bin | Lib | Load | Create | Trust | Reloc | 模式 |
|---|---|---|---|---|---|---|---|---|
| 1600 | pghydro | 否 | 否 | 否 | 是 | 否 | 否 | pghydro |
| 1601 | pgh_raster | 否 | 否 | 否 | 是 | 否 | 否 | pgh_raster |
| 1602 | pgh_hgm | 否 | 否 | 否 | 是 | 否 | 否 | pgh_hgm |
| 1603 | pgh_output | 否 | 否 | 否 | 是 | 否 | 否 | pgh_output |
| 1604 | pgh_output_en_au | 否 | 否 | 否 | 是 | 否 | 否 | pgh_output_en_au |
| 1605 | pgh_output_pt_br | 否 | 否 | 否 | 是 | 否 | 否 | pgh_output_pt_br |
| 1606 | pgh_consistency | 否 | 否 | 否 | 是 | 否 | 否 | pgh_consistency |
| 相关扩展 | plpgsql postgis postgis_raster pghydro postgis_raster pointcloud pgrouting ogr_fdw h3 q3c mobilitydb pg_sphere |
|---|---|
| 下游依赖 | pgh_hgm |
版本
| 类型 | 仓库 | 版本 | PG 大版本 | 包名 | 依赖 |
|---|---|---|---|---|---|
| EXT | PIGSTY | 6.6 | 1817161514 | pghydro | plpgsql, postgis, postgis_raster, pghydro |
| RPM | PIGSTY | 6.6 | 1817161514 | pghydro_$v | postgis36_$v |
| DEB | PIGSTY | 6.6 | 1817161514 | postgresql-$v-pghydro | postgresql-$v-postgis-3 |
| OS / PG | PG18 | PG17 | PG16 | PG15 | PG14 |
|---|---|---|---|---|---|
| el8.x86_64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| el8.aarch64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| el9.x86_64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| el9.aarch64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| el10.x86_64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| el10.aarch64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| d12.x86_64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| d12.aarch64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| d13.x86_64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| d13.aarch64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| u22.x86_64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| u22.aarch64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| u24.x86_64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| u24.aarch64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| u26.x86_64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
| u26.aarch64 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 | PIGSTY 6.6 |
构建
您可以使用 pig build 命令构建 pghydro 扩展的 RPM / DEB 包:
安装
您可以直接安装 pghydro 扩展包的预置二进制包,首先确保 PGDG 和 PIGSTY 仓库已经添加并启用:
使用 pig 或者是 apt/yum/dnf 安装扩展:
安装
pig
dnf
apt
创建扩展:
用法
来源:PGHydro README,pgh_raster SQL
pgh_raster 为 PgHydro 增加基于栅格的水文产品。它保存 DEM、flow path、flow direction、flow accumulation 栅格,并提供上游/下游像元追踪、排水区分析、高程查询、高程剖面和栅格裁剪函数。
启用
栅格表
扩展创建 pgh_raster schema,其中包括:
| 表 | 用途 |
|---|---|
pghrt_elevation | 高程栅格数据 |
pghrt_flowpath | flow path 栅格数据 |
pghrt_flowdirection | flow direction 栅格数据 |
pghrt_flowaccumulation | flow accumulation 栅格数据 |
可以使用 raster2pgsql 等 PostGIS Raster 工具加载栅格产品,并确保 SRID 与切片方式匹配排水数据集。
分析函数
函数组包括下游和上游像元遍历、上游面积查询、下游排水点和排水区查询、高程像元值、高程剖面,以及栅格裁剪。
注意事项
pgh_raster 同时依赖 pghydro 和 postgis_raster。派生水文地貌指标之前,应确保栅格对齐、SRID 和 nodata 处理与矢量排水图层一致。
这个页面对您有帮助吗?
感谢反馈,我们会据此改进这篇文档。
哪里没有解决?(可选)