ee.Image.spectralErosion
จัดทุกอย่างให้เป็นระเบียบอยู่เสมอด้วยคอลเล็กชัน
บันทึกและจัดหมวดหมู่เนื้อหาตามค่ากำหนดของคุณ
คำนวณการกัดกร่อนเชิงสเปกตรัม/เชิงพื้นที่ของรูปภาพโดยการคำนวณระยะทางเชิงสเปกตรัมของแต่ละพิกเซลภายใต้เคอร์เนลโครงสร้างจากจุดศูนย์กลางของพิกเซลทั้งหมดภายใต้เคอร์เนล และใช้ผลลัพธ์ที่ใกล้ที่สุด ดู "Spatial/spectral endmember extraction by multidimensional morphological operations" IEEE transactions on geoscience and remote sensing 40.9 (2002): 2025-2041.
การใช้งาน | การคืนสินค้า |
---|
Image.spectralErosion(metric, kernel, useCentroid) | รูปภาพ |
อาร์กิวเมนต์ | ประเภท | รายละเอียด |
---|
ดังนี้ image | รูปภาพ | รูปภาพที่อินพุตเข้ามา |
metric | String, ค่าเริ่มต้น: "sam" | เมตริกระยะทางสเปกตรัมที่จะใช้ โดยอาจเป็น "sam" (spectral angle mapper), "sid" (spectral information divergence), "sed" (squared Euclidean distance) หรือ "emd" (earth movers distance) |
kernel | เคอร์เนล ค่าเริ่มต้น: null | เคอร์เนลความเชื่อมโยง ค่าเริ่มต้นคือสี่เหลี่ยมจัตุรัสที่มีรัศมี 1 (เชื่อมต่อ 8 ทาง) |
useCentroid | บูลีน ค่าเริ่มต้น: false | หากเป็นจริง ระบบจะคำนวณระยะทางจากค่าเฉลี่ยของพิกเซลทั้งหมดภายใต้เคอร์เนลแทนที่จะเป็นพิกเซลตรงกลางของเคอร์เนล |
เนื้อหาของหน้าเว็บนี้ได้รับอนุญาตภายใต้ใบอนุญาตที่ต้องระบุที่มาของครีเอทีฟคอมมอนส์ 4.0 และตัวอย่างโค้ดได้รับอนุญาตภายใต้ใบอนุญาต Apache 2.0 เว้นแต่จะระบุไว้เป็นอย่างอื่น โปรดดูรายละเอียดที่นโยบายเว็บไซต์ Google Developers Java เป็นเครื่องหมายการค้าจดทะเบียนของ Oracle และ/หรือบริษัทในเครือ
อัปเดตล่าสุด 2025-07-26 UTC
[null,null,["อัปเดตล่าสุด 2025-07-26 UTC"],[[["\u003cp\u003eComputes the spectral/spatial erosion of an image based on spectral distance.\u003c/p\u003e\n"],["\u003cp\u003eUtilizes a structuring kernel to determine the spectral relationship between pixels.\u003c/p\u003e\n"],["\u003cp\u003eOffers various spectral distance metrics: SAM, SID, SED, and EMD.\u003c/p\u003e\n"],["\u003cp\u003eAllows for customization of the kernel and distance calculation method.\u003c/p\u003e\n"]]],[],null,["# ee.Image.spectralErosion\n\nComputes the spectral/spatial erosion 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 closest 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.spectralErosion`(`*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. |"]]