إشعار: يجب
إثبات أهلية جميع المشاريع غير التجارية المسجّلة لاستخدام Earth Engine قبل
15 أبريل 2025 من أجل الحفاظ على إمكانية الوصول إلى Earth Engine.
ee.Classifier.spectralRegion
تنظيم صفحاتك في مجموعات
يمكنك حفظ المحتوى وتصنيفه حسب إعداداتك المفضّلة.
تنشئ هذه الدالة مصنّفًا يختبر ما إذا كانت المدخلات تقع ضمن مضلّع محدّد بمجموعة من الإحداثيات في نظام إحداثيات ثنائي الأبعاد عشوائي. يجب أن يحتوي كل إدخال سيتم تصنيفه على قيمتَين (على سبيل المثال، يجب أن تحتوي الصور على نطاقَين). ستكون النتيجة 1 في أي مكان تكون فيه قيم الإدخال مضمّنة في المضلّع المحدّد، و0 في الحالات الأخرى.
الاستخدام | المرتجعات |
---|
ee.Classifier.spectralRegion(coordinates, schema) | المصنِّف |
الوسيطة | النوع | التفاصيل |
---|
coordinates | قائمة | إحداثيات المضلّع، كقائمة من الحلقات كل حلقة هي قائمة بأزواج الإحداثيات (مثل [u1, v1, u2, v2, ..., uN, vN]). لا يمكن أن يتقاطع أيّ حافة مع أيّ حافة أخرى. سيكون التصنيف الناتج 1 في أي مكان تكون فيه قيم الإدخال داخل المضلّع المحدّد، أي يجب عبور عدد فردي من حواف المضلّع للخروج منه، و0 في ما عدا ذلك. |
schema | قائمة، القيمة التلقائية: فارغة | مخطط المصنِّف قائمة بأسماء النطاقات أو الخصائص التي سيتم تشغيل المصنّف عليها. بما أنّ هذا المصنّف لا يخضع لخطوة تدريب، يجب تحديد هذه القيم يدويًا. القيمة التلقائية هي ['u', 'v']. |
إنّ محتوى هذه الصفحة مرخّص بموجب ترخيص Creative Commons Attribution 4.0 ما لم يُنصّ على خلاف ذلك، ونماذج الرموز مرخّصة بموجب ترخيص Apache 2.0. للاطّلاع على التفاصيل، يُرجى مراجعة سياسات موقع Google Developers. إنّ Java هي علامة تجارية مسجَّلة لشركة Oracle و/أو شركائها التابعين.
تاريخ التعديل الأخير: 2025-07-26 (حسب التوقيت العالمي المتفَّق عليه)
[null,null,["تاريخ التعديل الأخير: 2025-07-26 (حسب التوقيت العالمي المتفَّق عليه)"],[[["\u003cp\u003eCreates a classifier to determine if input data points, represented by two values, fall within a defined polygon.\u003c/p\u003e\n"],["\u003cp\u003eThe classifier uses a polygon defined by a set of coordinates in a 2D coordinate system.\u003c/p\u003e\n"],["\u003cp\u003eInput data, such as images with two bands, is classified as 1 if inside the polygon and 0 if outside.\u003c/p\u003e\n"],["\u003cp\u003eUsers can specify the polygon coordinates and optionally define a schema for the classifier's input bands or properties.\u003c/p\u003e\n"]]],[],null,["# ee.Classifier.spectralRegion\n\nCreates a classifier that tests if its inputs lie within a polygon defined by a set of coordinates in an arbitrary 2D coordinate system. Each input to be classified must have 2 values (e.g., images must have 2 bands). The result will be 1 wherever the input values are contained within the given polygon and 0 otherwise.\n\n\u003cbr /\u003e\n\n| Usage | Returns |\n|---------------------------------------------------------|------------|\n| `ee.Classifier.spectralRegion(coordinates, `*schema*`)` | Classifier |\n\n| Argument | Type | Details |\n|---------------|---------------------|-------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| `coordinates` | List | The coordinates of the polygon, as a list of rings. Each ring is a list of coordinate pairs (e.g., \\[u1, v1, u2, v2, ..., uN, vN\\]). No edge may intersect any other edge. The resulting classification will be a 1 wherever the input values are within the interior of the given polygon, that is, an odd number of polygon edges must be crossed to get outside the polygon and 0 otherwise. |\n| `schema` | List, default: null | The classifier's schema. A list of band or property names that the classifier will operate on. Since this classifier doesn't undergo a training step, these have to be specified manually. Defaults to \\['u', 'v'\\]. |"]]