公告:凡是在
2025 年 4 月 15 日前註冊使用 Earth Engine 的非商業專案,都必須
驗證非商業用途資格,才能繼續存取 Earth Engine。
ee.Image.loadZarrV2Array
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
以圖片形式載入 Zarr v2 陣列。陣列屬性 (.zattrs) 必須包含「_ARRAY_DIMENSIONS」欄位,這是各個維度的名稱清單 (例如['time', 'y', 'x']). 至少須有兩個維度,最後兩個維度分別代表 Y 和 X (例如 ['lat', 'lon']). 支援的壓縮編解碼器包括 'blosc'、'gzip'、'lz4'、'zlib' 和 'zstd'。支援的 blosc 元壓縮編碼器為 'lz4'、lz4hc'、'zlib' 和 'zstd' (不支援 'blosclz')。
用量 | 傳回 |
---|
ee.Image.loadZarrV2Array(uri, proj, starts, ends) | 圖片 |
引數 | 類型 | 詳細資料 |
---|
uri | 字串 | 要載入的 .zarray 檔案的 Cloud Storage URI。陣列目錄的父目錄中必須有 .zmetadata 檔案 (例如,如果是「gs://b/o/.zarray」,則必須有「gs://b/.zmetadata」)。必須能夠存取值區中繼資料 (需要「Storage 舊版值區讀取者」角色提供的 `storage.buckets.get` 權限,請參閱 https://cloud.google.com/storage/docs/access-control/iam-roles),且值區必須位於美國多地區、包含 US-CENTRAL1 的雙區域或 US-CENTRAL1 區域。 |
proj | 預測值 | 陣列的投影。 |
starts | 清單,預設值:null | 沿著每個非空間維度開始切片的索引 (包含上限)。如果為空值,則所有非空間維度的切片都會從索引 0 開始。如果指定了這個清單,其長度必須等於非空間維度的數量 (總維度 - 2)。清單中的個別元素可能為空值,該維度的預設值為 0。負數索引會從維度的結尾開始計數 (例如-1 是最後一個元素)。 |
ends | 清單,預設值:null | 沿著每個非空間維度停止切片的索引 (不含)。如果為空值,切片會延伸至每個對應非空間維度的結尾 (也就是預設為維度的長度)。如果指定了這個清單,其長度必須等於非空間維度的數量 (總維度 - 2)。清單中的個別元素可能為空值,且預設為該維度的長度。負數索引會從維度的結尾開始計數 (例如-1 是最後一個元素)。 |
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-07-25 (世界標準時間)。
[null,null,["上次更新時間:2025-07-25 (世界標準時間)。"],[],[],null,["# ee.Image.loadZarrV2Array\n\nLoads a Zarr v2 array as an Image. The array attributes (.zattrs) must contain the field '_ARRAY_DIMENSIONS', which is a list of the names of each dimension (e.g., \\['time', 'y', 'x'\\]). There must be at least two dimensions, with the final two representing Y and X respectively (e.g., \\['lat', 'lon'\\]). The supported compression codecs are 'blosc', 'gzip', 'lz4', 'zlib', and 'zstd'. The supported blosc meta-compression codecs are 'lz4', lz4hc', 'zlib', and 'zstd' ('blosclz' is not supported).\n\n\u003cbr /\u003e\n\n| Usage | Returns |\n|--------------------------------------------------------------|---------|\n| `ee.Image.loadZarrV2Array(uri, proj, `*starts* `, `*ends*`)` | Image |\n\n| Argument | Type | Details |\n|----------|---------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `uri` | String | The Cloud Storage URI of the .zarray file to load. A .zmetadata file must be present in the parent directory of the array's directory (e.g., for 'gs://b/o/.zarray', 'gs://b/.zmetadata' must be present). The bucket metadata must be accessible (requires the \\`storage.buckets.get\\` permission which is provided by the role \"Storage Legacy Bucket Reader\" among others, see https://cloud.google.com/storage/docs/access-control/iam-roles) and the bucket must be located in the US multi-region, a dual-region including US-CENTRAL1, or the US-CENTRAL1 region. |\n| `proj` | Projection | The projection of the array. |\n| `starts` | List, default: null | The indices (inclusive) at which to start taking slices along each non-spatial dimension. If null, slices will start at index 0 for all non-spatial dimensions. If specified, this list must have a length equal to the number of non-spatial dimensions (total dimensions - 2). An individual element within the list may be null, which defaults to 0 for that dimension. Negative indices are counted from the end of the dimension (e.g., -1 is the last element). |\n| `ends` | List, default: null | The indices (exclusive) at which to stop taking slices along each non-spatial dimension. If null, slices will extend to the end of each corresponding non-spatial dimension (i.e., defaults to the length of the dimension). If specified, this list must have a length equal to the number of non-spatial dimensions (total dimensions - 2). An individual element within the list may be null, which also defaults to the length of that dimension. Negative indices are counted from the end of the dimension (e.g., -1 is the last element). |"]]