公告:凡是在
2025 年 4 月 15 日前註冊使用 Earth Engine 的非商業專案,都必須
驗證非商業用途資格,才能繼續存取 Earth Engine。
ee.Image.spectralDilation
透過集合功能整理內容
你可以依據偏好儲存及分類內容。
計算圖像的光譜/空間擴張,方法是計算結構核心下每個像素的光譜距離,從核心下所有像素的質心開始,然後取最遠的結果。請參閱「Spatial/spectral endmember extraction by multidimensional morphological operations.」(透過多維度形態作業擷取空間/光譜端元)。IEEE transactions on geoscience and remote sensing 40.9 (2002): 2025-2041.
用量 | 傳回 |
---|
Image.spectralDilation(metric, kernel, useCentroid) | 圖片 |
引數 | 類型 | 詳細資料 |
---|
這個:image | 圖片 | 輸入圖片。 |
metric | 字串,預設值為「sam」 | 要使用的頻譜距離指標。可以是「sam」(光譜角度對應器)、「sid」(光譜資訊差異)、「sed」(平方歐幾里得距離) 或「emd」(地球移動距離)。 |
kernel | 核心,預設值:null | 連結性核心。預設值為半徑 1 的正方形 (8 向連線)。 |
useCentroid | 布林值,預設值為 false | 如果為 true,系統會根據核心下所有像素的平均值計算距離,而非核心的中心像素。 |
除非另有註明,否則本頁面中的內容是採用創用 CC 姓名標示 4.0 授權,程式碼範例則為阿帕契 2.0 授權。詳情請參閱《Google Developers 網站政策》。Java 是 Oracle 和/或其關聯企業的註冊商標。
上次更新時間:2025-07-26 (世界標準時間)。
[null,null,["上次更新時間:2025-07-26 (世界標準時間)。"],[[["\u003cp\u003eComputes the spectral/spatial dilation of an image based on the spectral distance of pixels within a kernel.\u003c/p\u003e\n"],["\u003cp\u003eUses a specified spectral distance metric (SAM, SID, SED, or EMD) to calculate distances.\u003c/p\u003e\n"],["\u003cp\u003eOffers options to define the kernel shape and whether to use the centroid or center pixel for distance calculations.\u003c/p\u003e\n"],["\u003cp\u003eOutputs an image representing the spectral dilation result.\u003c/p\u003e\n"]]],[],null,["# ee.Image.spectralDilation\n\nComputes the spectral/spatial dilation of an image by computing the spectral distance of each pixel under a structuring kernel from the centroid of all pixels under the kernel and taking the most distant result. See 'Spatial/spectral endmember extraction by multidimensional morphological operations.' IEEE transactions on geoscience and remote sensing 40.9 (2002): 2025-2041.\n\n\u003cbr /\u003e\n\n| Usage | Returns |\n|---------------------------------------------------------------------|---------|\n| Image.spectralDilation`(`*metric* `, `*kernel* `, `*useCentroid*`)` | Image |\n\n| Argument | Type | Details |\n|---------------|-------------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| this: `image` | Image | The input image. |\n| `metric` | String, default: \"sam\" | The spectral distance metric to use. One of 'sam' (spectral angle mapper), 'sid' (spectral information divergence), 'sed' (squared Euclidean distance), or 'emd' (earth movers distance). |\n| `kernel` | Kernel, default: null | Connectedness kernel. Defaults to a square of radius 1 (8-way connected). |\n| `useCentroid` | Boolean, default: false | If true, distances are computed from the mean of all pixels under the kernel instead of the kernel's center pixel. |"]]