公告:所有在
2025 年 4 月 15 日之前注册使用 Earth Engine 的非商业项目都必须
验证是否符合非商业性质的资格条件,才能继续使用 Earth Engine。
ee.ImageCollection.reduce
使用集合让一切井井有条
根据您的偏好保存内容并对其进行分类。
将缩减器应用于集合中的所有影像。
如果缩减器的输入源只有一个,则会单独应用于集合的每个波段;否则,其输入源的数量必须与集合的波段数量相同。
化简器输出名称决定了输出波段的名称:具有多个输入的化简器将直接使用输出名称,而具有单个输入的化简器将在输出名称前添加输入波段名称作为前缀(例如,'10_mean'、'20_mean')。
用法 | 返回 |
---|
ImageCollection.reduce(reducer, parallelScale) | 图片 |
参数 | 类型 | 详细信息 |
---|
此:collection | ImageCollection | 要缩减的图片集合。 |
reducer | 缩减器 | 要应用于指定集合的缩减器。 |
parallelScale | 浮点数,默认值:1 | 用于限制内存使用量的缩放比例;使用较大的 parallelScale(例如,2 或 4)可能会启用内存不足的计算(使用默认值)。 |
如未另行说明,那么本页面中的内容已根据知识共享署名 4.0 许可获得了许可,并且代码示例已根据 Apache 2.0 许可获得了许可。有关详情,请参阅 Google 开发者网站政策。Java 是 Oracle 和/或其关联公司的注册商标。
最后更新时间 (UTC):2025-07-27。
[null,null,["最后更新时间 (UTC):2025-07-27。"],[[["\u003cp\u003eApplies a reducer function across all images within an ImageCollection, resulting in a single output Image.\u003c/p\u003e\n"],["\u003cp\u003eReducers can operate on individual bands or multiple bands simultaneously, determining the output band names accordingly.\u003c/p\u003e\n"],["\u003cp\u003eUtilizes a parallelScale factor to manage memory consumption during computation.\u003c/p\u003e\n"],["\u003cp\u003eAccess this functionality via the \u003ccode\u003eImageCollection.reduce()\u003c/code\u003e method, providing the reducer and optional parallelScale as parameters.\u003c/p\u003e\n"]]],[],null,["# ee.ImageCollection.reduce\n\nApplies a reducer across all of the images in a collection.\n\n\u003cbr /\u003e\n\nIf the reducer has a single input, it will be applied separately to each band of the collection; otherwise it must have the same number of inputs as the collection has bands.\n\nThe reducer output names determine the names of the output bands: reducers with multiple inputs will use the output names directly, while reducers with a single input will prefix the output name with the input band name (e.g., '10_mean', '20_mean').\n\n| Usage | Returns |\n|------------------------------------------------------|---------|\n| ImageCollection.reduce`(reducer, `*parallelScale*`)` | Image |\n\n| Argument | Type | Details |\n|--------------------|-------------------|---------------------------------------------------------------------------------------------------------------------------------------------------------|\n| this: `collection` | ImageCollection | The image collection to reduce. |\n| `reducer` | Reducer | The reducer to apply to the given collection. |\n| `parallelScale` | Float, default: 1 | A scaling factor used to limit memory use; using a larger parallelScale (e.g., 2 or 4) may enable computations that run out of memory with the default. |"]]