ee.Kernel.roberts

יצירת ליבת Roberts לזיהוי קצוות בגודל 2x2.

שימושהחזרות
ee.Kernel.roberts(magnitude, normalize)ליבה
ארגומנטסוגפרטים
magnitudeמספר ממשי (float), ברירת מחדל: 1הכפלה של כל ערך בסכום הזה.
normalizeבוליאני, ברירת מחדל: falseמנרמלים את ערכי הליבה כך שהסכום שלהם יהיה 1.

דוגמאות

עורך הקוד (JavaScript)

print('A Roberts kernel', ee.Kernel.roberts());

/**
 * Output weights matrix; center is position [1,1]
 *
 * [1,  0]
 * [0, -1]
 */

הגדרת Python

מידע על Python API ועל שימוש ב-geemap לפיתוח אינטראקטיבי מופיע בדף Python Environment.

import ee
import geemap.core as geemap

Colab (Python)

from pprint import pprint

print('A Roberts kernel:')
pprint(ee.Kernel.roberts().getInfo())

#  Output weights matrix; center is position [1,1]

#  [1,  0]
#  [0, -1]