Announcement: All noncommercial projects registered to use Earth Engine before April 15, 2025 must verify noncommercial eligibility to maintain Earth Engine access.
Stay organized with collections
Save and categorize content based on your preferences.
Shortcut to filter a collection by intersection with geometry. Items in the collection with a footprint that fails to intersect the given geometry will be excluded.
This is equivalent to this.filter(ee.Filter.bounds(...)).
Returns the filtered collection.
Usage
Returns
ImageCollection.filterBounds(geometry)
Collection
Argument
Type
Details
this: collection
Collection
The Collection instance.
geometry
ComputedObject|FeatureCollection|Geometry
The geometry, feature or collection to intersect with.
[[["Easy to understand","easyToUnderstand","thumb-up"],["Solved my problem","solvedMyProblem","thumb-up"],["Other","otherUp","thumb-up"]],[["Missing the information I need","missingTheInformationINeed","thumb-down"],["Too complicated / too many steps","tooComplicatedTooManySteps","thumb-down"],["Out of date","outOfDate","thumb-down"],["Samples / code issue","samplesCodeIssue","thumb-down"],["Other","otherDown","thumb-down"]],["Last updated 2023-10-06 UTC."],[[["\u003cp\u003e\u003ccode\u003efilterBounds()\u003c/code\u003e filters an ImageCollection, returning only images that intersect a specified geometry, Feature, or FeatureCollection.\u003c/p\u003e\n"],["\u003cp\u003eThis method effectively removes images with footprints that do not overlap the provided geometry.\u003c/p\u003e\n"],["\u003cp\u003eUsing a large or complex geometry for filtering can significantly impact performance and should be minimized for efficiency.\u003c/p\u003e\n"],["\u003cp\u003e\u003ccode\u003efilterBounds()\u003c/code\u003e provides a spatial filter similar to using \u003ccode\u003efilter(ee.Filter.bounds(...))\u003c/code\u003e.\u003c/p\u003e\n"]]],[],null,["# ee.ImageCollection.filterBounds\n\n\u003cbr /\u003e\n\nShortcut to filter a collection by intersection with geometry. Items in the collection with a footprint that fails to intersect the given geometry will be excluded.\n\n\u003cbr /\u003e\n\nThis is equivalent to this.filter(ee.Filter.bounds(...)).\n| **Caution:** providing a large or complex collection as the `geometry` argument can result in poor performance. Collating the geometry of collections does not scale well; use the smallest collection (or geometry) that is required to achieve the desired outcome.\n\nReturns the filtered collection.\n\n| Usage | Returns |\n|------------------------------------------|------------|\n| ImageCollection.filterBounds`(geometry)` | Collection |\n\n| Argument | Type | Details |\n|--------------------|---------------------------------------------|--------------------------------------------------------|\n| this: `collection` | Collection | The Collection instance. |\n| `geometry` | ComputedObject\\|FeatureCollection\\|Geometry | The geometry, feature or collection to intersect with. |\n\nExamples\n--------\n\n### Code Editor (JavaScript)\n\n```javascript\n// A Sentinel-2 surface reflectance image collection for 3 months in 2021.\nvar ic = ee.ImageCollection('COPERNICUS/S2_SR')\n .filterDate('2021-07-01', '2021-10-01');\n\n// A point geometry for the peak of Mount Shasta, California, USA.\nvar geom = ee.Geometry.Point(-122.196, 41.411);\nprint('Images intersecting point geometry', ic.filterBounds(geom));\n\n// A feature collection of point geometries for mountain peaks.\nvar fc = ee.FeatureCollection([\n ee.Feature(ee.Geometry.Point(-122.196, 41.411), {mountain: 'Mount Shasta'}),\n ee.Feature(ee.Geometry.Point(-121.697, 45.374), {mountain: 'Mount Hood'})\n]);\nprint('Images intersecting feature collection', ic.filterBounds(fc));\n```\nPython setup\n\nSee the [Python Environment](/earth-engine/guides/python_install) page for information on the Python API and using\n`geemap` for interactive development. \n\n```python\nimport ee\nimport geemap.core as geemap\n```\n\n### Colab (Python)\n\n```python\n# A Sentinel-2 surface reflectance image collection for 3 months in 2021.\nic = ee.ImageCollection('COPERNICUS/S2_SR').filterDate(\n '2021-07-01', '2021-10-01'\n)\n\n# A point geometry for the peak of Mount Shasta, California, USA.\ngeom = ee.Geometry.Point(-122.196, 41.411)\nprint('Images intersecting point geometry:', ic.filterBounds(geom).getInfo())\n\n# A feature collection of point geometries for mountain peaks.\nfc = ee.FeatureCollection([\n ee.Feature(ee.Geometry.Point(-122.196, 41.411),\n {'mountain': 'Mount Shasta'}),\n ee.Feature(ee.Geometry.Point(-121.697, 45.374),\n {'mountain': 'Mount Hood'})\n])\nprint('Images intersecting feature collection:', ic.filterBounds(fc).getInfo())\n```"]]