在 Python 中處理地理空間資料
Joris Van den Bossche
Open source software developer and teacher, GeoPandas maintainer
艾菲爾鐵塔的位置:
POINT (2.2945 48.8584)
→ 座標參考系統(CRS) 會將座標對應到地球上的特定位置。

緯度與經度(度分秒)。
例如 48°51′N,2°17′E
用於 GPS、網頁地圖應用…
注意!
在 Python 中使用 (lon, lat),而非 (lat, long)


(x, y) 座標通常以公尺或英尺表示
Albers 等積投影

墨卡托投影(Mercator)

投影大小 vs 實際大小(墨卡托投影)

proj4 字串
範例:+proj=longlat +datum=WGS84 +no_defs
字典表示法:
{'proj': 'longlat', 'datum': 'WGS84', 'no_defs': True}
EPSG 代碼
範例:
EPSG:4326 = WGS84 地理座標 CRS(經度、緯度)
GeoDataFrame/GeoSeries 的 .crs 屬性:
import geopandas
gdf = geopandas.read_file("countries.shp")
print(gdf.crs)
{'init': 'epsg:4326'}
.crs 屬性在 Python 中處理地理空間資料