Python:如何批量下载CLMS NDVI V3数据集?
01 说明
1.1 产品和API说明
如果只是小批量下载,直接使用Copernicus Broswer
或者下载或许更为方便,具体网址见:
Copernicus Broswer
:https://browser.dataspace.copernicus.eu/
Land-Copernicus Broswer
:https://land.copernicus.eu/en/map-viewer
我所下载的NDVI产品是:Normalised Difference Vegetation Index 1999-2020 (raster 1 km), global, 10-daily – version 3
(在上述网址均可检索到),全球范围.
具体产品信息说明见:https://land.copernicus.eu/en/products/vegetation/normalised-difference-vegetation-index-v3-0-1km
关于该数据集的API信息见: https://land.copernicus.eu/api/en/products/vegetation/normalised-difference-vegetation-index-v3-0-1km
关于CLMS API使用的官方脚本示例(使用的应是官方库terracatalogueclient
,但底层应是调用CLMS API)见:https://land.copernicus.eu/en/technical-library/bulk-download-clms-data
关于CLMS API的官方文档(非terracatalogueclient
的使用文档):https://eea.github.io/clms-api-docs/download.html
CLMS涉及的所有数据集(2025/8/30查询)见附录(title
| collection_id
, 若使用terracatalogueclient
库下载可用于检索查看)。
目前(2025/8/30)下载CLMS NDVI V3
数据集无需token等密钥, 故此处创建密钥步骤略.
1.2 其他说明
由于下载需求为全球范围、时间范围为2000-2020年。因此代码中没有涉及覆盖范围参数的选取(不清楚对于全球是否会进行云处理裁剪之后返回)。
02 代码
from datetime import date
from terracatalogueclient import Catalogue
from terracatalogueclient.config import CatalogueConfig, CatalogueEnvironment# 准备
config = CatalogueConfig.from_environment(CatalogueEnvironment.CGLS) # 创建默认配置(默认配置无需API认证例如账户和密钥)
catalogue = Catalogue(config) # 实例化CLMS数据集目录
out_dir = r'F:\PyProJect\veg_growing_mountain\Src\Download\NDVI_V3_2010_DOWNLOADS' # 输出目录
start_date = date(2000, 1, 1) # 检索的起始日期
end_date = date(2020, 12, 31) # 检索的终止日期
collection_id = "clms_global_ndvi_1km_v3_10daily_geotiff" # 通过下方的c.id获取# 打印所有的数据集合的标题和id(id用于下方的collection参数), 用时较长
for c in list(catalogue.get_collections()):print("{} | {}".format(c.properties.get("title"), c.id))# 数据集下载(Normalised Difference Vegetation Index 1999-2020 (raster 1 km), global, 10-daily – version 3)
products = list(catalogue.get_products(collection_id, # 填入数据集idstart=start_date,end=end_date,# 如需要限制覆盖范围指定bbox=(west, south, east, north)
))# 下载检索到的数据集
catalogue.download_products(products, out_dir) # 输入y确认下载
03 附录
CLMS涉及的所有数据集(2025/8/30查询):
Title | Colleciton ID |
---|---|
Burnt Area: global daily (raster 300m) | clms_global_ba_300m_v3_daily_geotiff |
Burnt Area: global daily (raster 300m) | clms_global_ba_300m_v3_daily_netcdf |
Burnt Area: global monthly (raster 300m) | clms_global_ba_300m_v3_monthly_geotiff |
Burnt Area: global monthly (raster 300m) | clms_global_ba_300m_v3_monthly_netcdf |
Dry Matter Productivity: global 10-daily (raster 1km) | clms_global_dmp_1km_v2_10daily_geotiff |
Dry Matter Productivity: global 10-daily (raster 1km) | clms_global_dmp_1km_v2_10daily_netcdf |
Dry Matter Productivity: global 10-daily (raster 300m) | clms_global_dmp_300m_v1_10daily_geotiff |
Dry Matter Productivity: global 10-daily (raster 300m) | clms_global_dmp_300m_v1_10daily_netcdf |
Fraction of Absorbed Photosynthetically Active Radiation: global 10-daily (raster 1km) | clms_global_fapar_1km_v1_10daily_geotiff |
Fraction of Absorbed Photosynthetically Active Radiation: global 10-daily (raster 1km) | clms_global_fapar_1km_v1_10daily_netcdf |
Fraction of Absorbed Photosynthetically Active Radiation: global 10-daily (raster 1km) | clms_global_fapar_1km_v2_10daily_geotiff |
Fraction of Absorbed Photosynthetically Active Radiation: global 10-daily (raster 1km) | clms_global_fapar_1km_v2_10daily_netcdf |
Fraction of Absorbed Photosynthetically Active Radiation: global 10-daily (raster 300m) | clms_global_fapar_300m_v1_10daily_geotiff |
Fraction of Absorbed Photosynthetically Active Radiation: global 10-daily (raster 300m) | clms_global_fapar_300m_v1_10daily_netcdf |
Fraction of Absorbed Photosynthetically Active Radiation: global 10-daily (raster 1km) | clms_global_fcover_1km_v1_10daily_geotiff |
Fraction of Absorbed Photosynthetically Active Radiation: global 10-daily (raster 1km) | clms_global_fcover_1km_v1_10daily_netcdf |
Fraction of Absorbed Photosynthetically Active Radiation: global 10-daily (raster 1km) | clms_global_fcover_1km_v2_10daily_geotiff |
Fraction of Absorbed Photosynthetically Active Radiation: global 10-daily (raster 1km) | clms_global_fcover_1km_v2_10daily_netcdf |
Fraction of Vegetation Cover: global 10-daily (raster 300m) | clms_global_fcover_300m_v1_10daily_geotiff |
Fraction of Vegetation Cover: global 10-daily (raster 300m) | clms_global_fcover_300m_v1_10daily_netcdf |
Gross Dry Matter Productivity: global 10-daily (raster 1km) | clms_global_gdmp_1km_v2_10daily_geotiff |
Gross Dry Matter Productivity: global 10-daily (raster 1km) | clms_global_gdmp_1km_v2_10daily_netcdf |
Gross Dry Matter Productivity: global 10-daily (raster 300m) | clms_global_gdmp_300m_v1_10daily_geotiff |
Gross Dry Matter Productivity: global 10-daily (raster 300m) | clms_global_gdmp_300m_v1_10daily_netcdf |
Gross Primary Productivity: global 10-daily (raster 300m) | clms_global_gpp_300m_v1_10daily_geotiff |
Gross Primary Productivity: global 10-daily (raster 300m) | clms_global_gpp_300m_v1_10daily_netcdf |
Leaf Area Index: global 10-daily (raster 1km) | clms_global_lai_1km_v1_10daily_geotiff |
Leaf Area Index: global 10-daily (raster 1km) | clms_global_lai_1km_v1_10daily_netcdf |
Leaf Area Index: global 10-daily (raster 1km) | clms_global_lai_1km_v2_10daily_geotiff |
Leaf Area Index: global 10-daily (raster 1km) | clms_global_lai_1km_v2_10daily_netcdf |
Leaf Area Index: global 10-daily (raster 300m) | clms_global_lai_300m_v1_10daily_geotiff |
Leaf Area Index: global 10-daily (raster 300m) | clms_global_lai_300m_v1_10daily_netcdf |
Dynamic Land Cover 2015-2019: global annual (raster 100m) - version 3 | clms_global_lcc_100m_v3_yearly_geotiff |
Lake Ice Extent: Baltic daily (raster 250 m) | clms_global_lie_250m_v1_daily_netcdf |
Lake Ice Extent: Continental Europe daily (raster 250 m) | clms_global_lie_250m_v2_daily_netcdf |
Lake Ice Extent: Europe daily (raster 500 m) | clms_global_lie_500m_v1_daily_netcdf |
Lake Ice Extent: Global daily (raster 500 m), version 2 | clms_global_lie_500m_v2_daily_netcdf |
Land Surface Phenology: global yearly (raster 300m) | clms_global_lsp_300m_v1_yearly_geotiff |
Land Surface Temperature: global 10-daily Daily Cycle (raster 5km) | clms_global_lst_5km_v1_10daily-daily-cycle_geotiff |
Land Surface Temperature: global 10-daily Daily Cycle (raster 5km) | clms_global_lst_5km_v1_10daily-daily-cycle_netcdf |
Land Surface Temperature: global 10-daily Thermal Condition Index (raster 5km) | clms_global_lst_5km_v1_10daily-tci_geotiff |
Land Surface Temperature: global 10-daily Thermal Condition Index (raster 5km) | clms_global_lst_5km_v1_10daily-tci_netcdf |
Land Surface Temperature: global hourly (raster 5km) | clms_global_lst_5km_v1_hourly_geotiff |
Land Surface Temperature: global hourly (raster 5km) | clms_global_lst_5km_v1_hourly_netcdf |
Land Surface Temperature: global 10-daily Daily Cycle (raster 5km) | clms_global_lst_5km_v2_10daily-daily-cycle_geotiff |
Land Surface Temperature: global 10-daily Daily Cycle (raster 5km) | clms_global_lst_5km_v2_10daily-daily-cycle_netcdf |
Land Surface Temperature: global 10-daily Thermal Condition Index (raster 5km) | clms_global_lst_5km_v2_10daily-tci_geotiff |
Land Surface Temperature: global 10-daily Thermal Condition Index (raster 5km) | clms_global_lst_5km_v2_10daily-tci_netcdf |
Land Surface Temperature: global hourly (raster 5km) | clms_global_lst_5km_v2_hourly_geotiff |
Land Surface Temperature: global hourly (raster 5km) | clms_global_lst_5km_v2_hourly_netcdf |
Lake Surface Water Temperature: global 10-daily near-real time (raster 1km) | clms_global_lswt_1km_v1_10daily-nrt_netcdf |
Lake Surface Water Temperature: global 10-daily reprocessed (raster 1km) | clms_global_lswt_1km_v1_10daily-reproc_netcdf |
Lake Water Quality: global 10-daily near-real time (raster 100m) | clms_global_lwq_100m_v1_10daily-nrt_netcdf |
Lake Water Quality: global 10-daily near-real time (raster 100m) - version 2 | clms_global_lwq_100m_v2_10daily-nrt_netcdf |
Lake Water Quality: global 10-daily near-real time (raster 1km) | clms_global_lwq_1km_v1_10daily-nrt_netcdf |
Lake Water Quality: global 10-daily reprocessed (raster 1km) | clms_global_lwq_1km_v1_10daily-reproc_netcdf |
Lake Water Quality: global 10-daily near-real time (raster 300m) | clms_global_lwq_300m_v1_10daily-nrt_netcdf |
Lake Water Quality: global 10-daily reprocessed (raster 300m) | clms_global_lwq_300m_v1_10daily-reproc_netcdf |
Lake Water Quality: global 10-daily near-real time (raster 300m) | clms_global_lwq_300m_v2_10daily-nrt_netcdf |
Normalized Difference Vegetation Index: global 10-daily (raster 1km) | clms_global_ndvi_1km_v2_10daily_geotiff |
Normalized Difference Vegetation Index: global 10-daily (raster 1km) | clms_global_ndvi_1km_v2_10daily_netcdf |
Normalized Difference Vegetation Index: global 10-daily statistics (raster 1km) | clms_global_ndvi_1km_v2_statistics_geotiff |
Normalized Difference Vegetation Index: global 10-daily statistics (raster 1km) | clms_global_ndvi_1km_v2_statistics_netcdf |
Normalized Difference Vegetation Index: global 10-daily (raster 1km) | clms_global_ndvi_1km_v3_10daily_geotiff |
Normalized Difference Vegetation Index: global 10-daily (raster 1km) | clms_global_ndvi_1km_v3_10daily_netcdf |
Normalized Difference Vegetation Index: global 10-daily statistics (raster 1km) | clms_global_ndvi_1km_v3_statistics_geotiff |
Normalized Difference Vegetation Index: global 10-daily statistics (raster 1km) | clms_global_ndvi_1km_v3_statistics_netcdf |
Normalized Difference Vegetation Index: global 10-daily (raster 300m) | clms_global_ndvi_300m_v1_10daily_geotiff |
Normalized Difference Vegetation Index: global 10-daily (raster 300m) | clms_global_ndvi_300m_v1_10daily_netcdf |
Normalized Difference Vegetation Index: global 10-daily (raster 300m) | clms_global_ndvi_300m_v2_10daily_geotiff |
Normalized Difference Vegetation Index: global 10-daily (raster 300m) | clms_global_ndvi_300m_v2_10daily_netcdf |
Net Primary Productivity: global 10-daily (raster 300m) | clms_global_npp_300m_v1_10daily_geotiff |
Net Primary Productivity: global 10-daily (raster 300m) | clms_global_npp_300m_v1_10daily_netcdf |
Snow Cover Extent: northern hemisphere daily (raster 1 km) | clms_global_sce_1km_v1_daily_netcdf |
Snow Cover Extent: Europe daily (raster 500 m) | clms_global_sce_500m_v1_daily_netcdf |
Surface Soil Moisture: global daily (raster 1 km) | clms_global_ssm_1km_v1_daily_geotiff |
Surface Soil Moisture: global daily (raster 1 km) | clms_global_ssm_1km_v1_daily_netcdf |
Snow Water Equivalent: northern hemisphere daily (raster 5 km) | clms_global_swe_5km_v1_daily_netcdf |
Snow Water Equivalent: northern hemisphere daily (raster 5 km), version 2 | clms_global_swe_5km_v2_daily_netcdf |
Soil Water Index: global 10-daily (raster 12.5 km) | clms_global_swi_12.5km_v3_10daily_geotiff |
Soil Water Index: global 10-daily (raster 12.5 km) | clms_global_swi_12.5km_v3_10daily_netcdf |
Soil Water Index: global daily (raster 12.5 km) | clms_global_swi_12.5km_v3_daily_geotiff |
Soil Water Index: global daily (raster 12.5 km) | clms_global_swi_12.5km_v3_daily_netcdf |
Soil Water Index: global daily (raster 12.5 km) | clms_global_swi_12.5km_v3_static_netcdf |
Soil Water Index: global time series (discrete global grid) | clms_global_swi_12.5km_v3_time-series_netcdf |
Soil Water Index: global 10-daily (raster 12.5 km) | clms_global_swi_12.5km_v4_10daily_netcdf |
Soil Water Index: global daily (raster 12.5 km) | clms_global_swi_12.5km_v4_daily_netcdf |
Soil Water Index: global daily (raster 1 km) | clms_global_swi_1km_v1_daily_geotiff |
Soil Water Index: global daily (raster 1 km) | clms_global_swi_1km_v1_daily_netcdf |
Soil Water Index: global daily (raster 1 km) | clms_global_swi_1km_v2_daily_netcdf |
Water Bodies: global monthly (raster 100m) | clms_global_wb_100m_v1_monthly_netcdf |
Water Bodies: global 10-daily (raster 1km) | clms_global_wb_1km_v2_10daily_netcdf |
Water Bodies: global 10-daily (raster 300m) | clms_global_wb_300m_v1_10daily_netcdf |
Water Bodies: global monthly (raster 300m) | clms_global_wb_300m_v2_monthly_netcdf |
Lake Water Level: observation time series (vector) | clms_global_wl_lakes_v2_daily_geojson |
Lake Water Level: observation time series (vector) | clms_global_wl_rivers_v2_daily_geojson |