GEE——使用cart机器学习方法对Landsat影像条带修复以NDVI和NDWI为例(全代码)

本文主要是介绍GEE——使用cart机器学习方法对Landsat影像条带修复以NDVI和NDWI为例(全代码),希望对大家解决编程问题提供一定的参考价值,需要的开发者们随着小编来一起学习吧!

简介

之前发表了两篇关于影像修复的文章,并且制作了APP,大家可以去看以下的两篇博客来了解具体的研究内容和整个方法的有效性:

Google Earth Engine APP——影像条带色差、色调不均匀等现象解决方案Landsat5 NDWI Image Restoration APP_ndwi不能识别泛红水体怎么办-CSDN博客

基于GEE云平台一种快速修复Landsat影像条带色差的方法_gee平台-CSDN博客

影像条带色差产生的主要原因有以下几点:

1. 光学系统问题:光学系统中的透镜、滤光片等元件可能存在偏差或缺陷,导致不同波长的光在传输过程中被聚焦的位置不一致,从而产生色差。

2. 图像传感器问题:图像传感器中的像素单元可能对不同波长的光的响应度不同,导致不同波长的光在图像传感器上形成的图像亮度不一致,从而产生色差。

3. 色彩处理问题:在图像的处理过程中,可能会对不同波长的光进行不同的处理,如增强某个颜色通道的亮度或饱和度,从而导致色差。

4. 环境光影响:在拍摄现场,环境光的波长和强度可能有所不同,对拍摄的影像产生影响,从而产生色差。

总的来说,影像条带色差的产生主要是由于光学系统、图像传感器、色彩处理和环境光等多个因素综合作用的结果。

函数:

本文里面的主要使用的函数众多,包含了归一化函数,直方图统计,机器学习方法以及图形展示等 

normalizedDifference(bandNames)

Computes the normalized difference between two bands. If the bands to use are not specified, uses the first two bands. The normalized difference is computed as (first − second) / (first + second). Note that the returned image band name is 'nd', the input image properties are not retained in the output image, and a negative pixel value in either input band will cause the output pixel to be masked. To avoid masking negative input values, use ee.Image.expression() to compute normalized difference.

Arguments:

this:input (Image):

The input image.

bandNames (List, default: null):

A list of names specifying the bands to use. If not specified, the first and second bands are used.

Returns: Image

CLOSE

ee.ImageCollection.fromImages(images)

Returns the image collection containing the given images.

Arguments:

images (List):

The images to include in the collection.

Returns: ImageCollection

ui.Chart.image.histogram(image, regionscalemaxBucketsminBucketWidthmaxRawmaxPixels)

Generates a Chart from an image. Computes and plots histograms of the values of the bands in the specified region of the image.

  • X-axis: Histogram buckets (of band value).

  • Y-axis: Frequency (number of pixels with a band value in the bucket).

Returns a chart.

Arguments:

image (Image):

The image to generate a histogram from.

region (Feature|FeatureCollection|Geometry, optional):

The region to reduce. If omitted, uses the entire image.

scale (Number, optional):

The pixel scale used when applying the histogram reducer, in meters.

maxBuckets (Number, optional):

The maximum number of buckets to use when building a histogram; will be rounded up to a power of 2.

minBucketWidth (Number, optional):

The minimum histogram bucket width, or null to allow any power of 2.

maxRaw (Number, optional):

The number of values to accumulate before building the initial histogram.

maxPixels (Number, optional):

If specified, overrides the maximum number of pixels allowed in the histogram reduction. Defaults to 1e6.

Returns: ui.Chart

setSeriesNames(seriesNames, seriesIndex)

Returns a copy of this chart with updated series names.

Arguments:

this:ui.chart (ui.Chart):

The ui.Chart instance.

seriesNames (Dictionary|Dictionary<String>|List|List<String>|String):

New series names. If it's a string, the name of the series at seriesIndex is set to seriesNames. If it's a list, the value at index i in the list is used as a label for series number i. If it's a dictionary or an object, it's treated as a map from existing series names to new series names. In the last two cases, seriesIndex is ignored.

seriesIndex (Number, optional):

The index of the series to rename. Ignored if seriesNames is a list or dictionary. Series are 0-indexed.

Returns: ui.Chart

ee.Reducer.histogram(maxBucketsminBucketWidthmaxRaw)

Create a reducer that will compute a histogram of the inputs.

Arguments:

maxBuckets (Integer, default: null):

The maximum number of buckets to use when building a histogram; will be rounded up to a power of 2.

这篇关于GEE——使用cart机器学习方法对Landsat影像条带修复以NDVI和NDWI为例(全代码)的文章就介绍到这儿,希望我们推荐的文章对编程师们有所帮助!



http://www.chinasem.cn/article/485712

相关文章

Nginx设置连接超时并进行测试的方法步骤

《Nginx设置连接超时并进行测试的方法步骤》在高并发场景下,如果客户端与服务器的连接长时间未响应,会占用大量的系统资源,影响其他正常请求的处理效率,为了解决这个问题,可以通过设置Nginx的连接... 目录设置连接超时目的操作步骤测试连接超时测试方法:总结:设置连接超时目的设置客户端与服务器之间的连接

Java中String字符串使用避坑指南

《Java中String字符串使用避坑指南》Java中的String字符串是我们日常编程中用得最多的类之一,看似简单的String使用,却隐藏着不少“坑”,如果不注意,可能会导致性能问题、意外的错误容... 目录8个避坑点如下:1. 字符串的不可变性:每次修改都创建新对象2. 使用 == 比较字符串,陷阱满

Java判断多个时间段是否重合的方法小结

《Java判断多个时间段是否重合的方法小结》这篇文章主要为大家详细介绍了Java中判断多个时间段是否重合的方法,文中的示例代码讲解详细,感兴趣的小伙伴可以跟随小编一起学习一下... 目录判断多个时间段是否有间隔判断时间段集合是否与某时间段重合判断多个时间段是否有间隔实体类内容public class D

Python使用国内镜像加速pip安装的方法讲解

《Python使用国内镜像加速pip安装的方法讲解》在Python开发中,pip是一个非常重要的工具,用于安装和管理Python的第三方库,然而,在国内使用pip安装依赖时,往往会因为网络问题而导致速... 目录一、pip 工具简介1. 什么是 pip?2. 什么是 -i 参数?二、国内镜像源的选择三、如何

使用C++实现链表元素的反转

《使用C++实现链表元素的反转》反转链表是链表操作中一个经典的问题,也是面试中常见的考题,本文将从思路到实现一步步地讲解如何实现链表的反转,帮助初学者理解这一操作,我们将使用C++代码演示具体实现,同... 目录问题定义思路分析代码实现带头节点的链表代码讲解其他实现方式时间和空间复杂度分析总结问题定义给定

IDEA编译报错“java: 常量字符串过长”的原因及解决方法

《IDEA编译报错“java:常量字符串过长”的原因及解决方法》今天在开发过程中,由于尝试将一个文件的Base64字符串设置为常量,结果导致IDEA编译的时候出现了如下报错java:常量字符串过长,... 目录一、问题描述二、问题原因2.1 理论角度2.2 源码角度三、解决方案解决方案①:StringBui

Linux使用nload监控网络流量的方法

《Linux使用nload监控网络流量的方法》Linux中的nload命令是一个用于实时监控网络流量的工具,它提供了传入和传出流量的可视化表示,帮助用户一目了然地了解网络活动,本文给大家介绍了Linu... 目录简介安装示例用法基础用法指定网络接口限制显示特定流量类型指定刷新率设置流量速率的显示单位监控多个

Java覆盖第三方jar包中的某一个类的实现方法

《Java覆盖第三方jar包中的某一个类的实现方法》在我们日常的开发中,经常需要使用第三方的jar包,有时候我们会发现第三方的jar包中的某一个类有问题,或者我们需要定制化修改其中的逻辑,那么应该如何... 目录一、需求描述二、示例描述三、操作步骤四、验证结果五、实现原理一、需求描述需求描述如下:需要在

JavaScript中的reduce方法执行过程、使用场景及进阶用法

《JavaScript中的reduce方法执行过程、使用场景及进阶用法》:本文主要介绍JavaScript中的reduce方法执行过程、使用场景及进阶用法的相关资料,reduce是JavaScri... 目录1. 什么是reduce2. reduce语法2.1 语法2.2 参数说明3. reduce执行过程

C#中读取XML文件的四种常用方法

《C#中读取XML文件的四种常用方法》Xml是Internet环境中跨平台的,依赖于内容的技术,是当前处理结构化文档信息的有力工具,下面我们就来看看C#中读取XML文件的方法都有哪些吧... 目录XML简介格式C#读取XML文件方法使用XmlDocument使用XmlTextReader/XmlTextWr