Thông báo : Tất cả dự án phi thương mại đã đăng ký sử dụng Earth Engine trước
ngày 15 tháng 4 năm 2025 phải
xác minh điều kiện sử dụng phi thương mại để duy trì quyền truy cập. Nếu bạn chưa xác minh trước ngày 26 tháng 9 năm 2025, quyền truy cập của bạn có thể bị tạm ngưng.
Gửi ý kiến phản hồi
ee.ErrorMargin
Sử dụng bộ sưu tập để sắp xếp ngăn nắp các trang
Lưu và phân loại nội dung dựa trên lựa chọn ưu tiên của bạn.
Trả về ErrorMargin thuộc loại đã cho với giá trị đã cho.
Cách sử dụng Giá trị trả về ee.ErrorMargin(value , unit )
ErrorMargin
Đối số Loại Thông tin chi tiết value
Float, mặc định: null Giá trị lỗi tối đa được phép theo lợi nhuận. Bị bỏ qua nếu đơn vị là "vô hạn". unit
Chuỗi, mặc định: "meters" Đơn vị của lề này: "meters", "projected" hoặc "infinite".
Ví dụ
Trình soạn thảo mã (JavaScript)
// Construct a variety of error margins.
print ( ee . ErrorMargin ( 0 )); // unit: meters value: 0
print ( ee . ErrorMargin ( 1 )); // unit: meters value: 1
// Negative margin yields a positive value.
print ( ee . ErrorMargin ( - 1 )); // unit: meters value: 1
// Large values are turned into an 'infinite'
print ( ee . ErrorMargin ( 1e8 )); // unit: infinite
// A very large error margin does not quite trigger infinite, which is 2.0e7.
print ( ee . ErrorMargin ( 1e7 )); // unit: meters value: 10000000
// Being explicit about the units of the error margin.
print ( ee . ErrorMargin ( 1 , 'meters' )); // unit: meters value: 1
print ( ee . ErrorMargin ( 1 , 'projected' )); // unit: projected value: 1
print ( ee . ErrorMargin ( 1 , 'infinite' )); // unit: infinite
Thiết lập Python
Hãy xem trang
Môi trường Python để biết thông tin về API Python và cách sử dụng geemap
cho quá trình phát triển tương tác.
import ee
import geemap.core as geemap
Colab (Python)
# Construct a variety of error margins.
print ( ee . ErrorMargin ( 0 ) . getInfo ()) # unit: meters value: 0
print ( ee . ErrorMargin ( 1 ) . getInfo ()) # unit: meters value: 1
# Negative margin yields a positive value.
print ( ee . ErrorMargin ( - 1 ) . getInfo ()) # unit: meters value: 1
# Large values are turned into an 'infinite'
print ( ee . ErrorMargin ( 1e8 ) . getInfo ()) # unit: infinite
# A very large error margin does not quite trigger infinite, which is 2.0e7.
print ( ee . ErrorMargin ( 1e7 ) . getInfo ()) # unit: meters value: 10000000
# Being explicit about the units of the error margin.
print ( ee . ErrorMargin ( 1 , 'meters' ) . getInfo ()) # unit: meters value: 1
print ( ee . ErrorMargin ( 1 , 'projected' ) . getInfo ()) # unit: projected value: 1
print ( ee . ErrorMargin ( 1 , 'infinite' ) . getInfo ()) # unit: infinite
Gửi ý kiến phản hồi
Trừ phi có lưu ý khác, nội dung của trang này được cấp phép theo Giấy phép ghi nhận tác giả 4.0 của Creative Commons và các mẫu mã lập trình được cấp phép theo Giấy phép Apache 2.0 . Để biết thông tin chi tiết, vui lòng tham khảo Chính sách trang web của Google Developers . Java là nhãn hiệu đã đăng ký của Oracle và/hoặc các đơn vị liên kết với Oracle.
Cập nhật lần gần đây nhất: 2025-07-26 UTC.
Bạn muốn chia sẻ thêm với chúng tôi?
[[["Dễ hiểu","easyToUnderstand","thumb-up"],["Giúp tôi giải quyết được vấn đề","solvedMyProblem","thumb-up"],["Khác","otherUp","thumb-up"]],[["Thiếu thông tin tôi cần","missingTheInformationINeed","thumb-down"],["Quá phức tạp/quá nhiều bước","tooComplicatedTooManySteps","thumb-down"],["Đã lỗi thời","outOfDate","thumb-down"],["Vấn đề về bản dịch","translationIssue","thumb-down"],["Vấn đề về mẫu/mã","samplesCodeIssue","thumb-down"],["Khác","otherDown","thumb-down"]],["Cập nhật lần gần đây nhất: 2025-07-26 UTC."],[],[]]