ee.Kernel.laplacian8
Zadbaj o dobrą organizację dzięki kolekcji
Zapisuj i kategoryzuj treści zgodnie ze swoimi preferencjami.
Generuje jądro wykrywania krawędzi 3x3 Laplacian-8.
Wykorzystanie | Zwroty |
---|
ee.Kernel.laplacian8(magnitude, normalize) | Jądro |
Argument | Typ | Szczegóły |
---|
magnitude | Liczba zmiennoprzecinkowa, domyślnie: 1 | Skaluj każdą wartość o tę kwotę. |
normalize | Wartość logiczna, domyślnie: false | Znormalizuj wartości jądra tak, aby ich suma wynosiła 1. |
Przykłady
Edytor kodu (JavaScript)
print('A Laplacian-8 kernel', ee.Kernel.laplacian8());
/**
* Output weights matrix
*
* [1, 1, 1]
* [1, -8, 1]
* [1, 1, 1]
*/
Konfiguracja Pythona
Informacje o interfejsie Python API i używaniu geemap
do interaktywnego programowania znajdziesz na stronie
Środowisko Python.
import ee
import geemap.core as geemap
Colab (Python)
from pprint import pprint
print('A Laplacian-8 kernel:')
pprint(ee.Kernel.laplacian8().getInfo())
# Output weights matrix
# [1, 1, 1]
# [1, -8, 1]
# [1, 1, 1]
O ile nie stwierdzono inaczej, treść tej strony jest objęta licencją Creative Commons – uznanie autorstwa 4.0, a fragmenty kodu są dostępne na licencji Apache 2.0. Szczegółowe informacje na ten temat zawierają zasady dotyczące witryny Google Developers. Java jest zastrzeżonym znakiem towarowym firmy Oracle i jej podmiotów stowarzyszonych.
Ostatnia aktualizacja: 2025-07-26 UTC.
[null,null,["Ostatnia aktualizacja: 2025-07-26 UTC."],[],["The `ee.Kernel.laplacian8()` function generates a 3x3 Laplacian-8 edge-detection kernel. It accepts two optional arguments: `magnitude` (float, default 1) to scale kernel values, and `normalize` (boolean, default false) to normalize values to sum to 1. The function returns a Kernel object. The default kernel matrix consists of ones around the perimeter and negative eight in the center: [[1, 1, 1], [1, -8, 1], [1, 1, 1]].\n"],null,[]]