Skip to content

Access to MOD09 data broken? #232

Answered by TomAugspurger
jgomezdans asked this question in Q&A
Discussion options

You must be logged in to vote

Thanks. I can make some progress with this:

import odc.stac
import planetary_computer
import pystac_client
import shapely.geometry

catalog = pystac_client.Client.open(
    "https://planetarycomputer.microsoft.com/api/stac/v1",
    modifier=planetary_computer.sign_inplace,
)
location = shapely.geometry.Point(-118.2923, 36.5785)
bbox = location.buffer(2).bounds

items = catalog.search(
    collections=["modis-09A1-061"],
    intersects=location,
    datetime="2021-12-03",
).item_collection()


data = odc.stac.load(
    items,
    crs="EPSG:3857",
    bbox=bbox,
    resolution=1000,
    bands=["sur_refl_b01", "sur_refl_b04", "sur_refl_b03"]
)

data

The key change is the inclusion of the bands=

Replies: 2 comments 2 replies

Comment options

You must be logged in to vote
2 replies
@jgomezdans
Comment options

@TomAugspurger
Comment options

Answer selected by jgomezdans
Comment options

You must be logged in to vote
0 replies
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Category
Q&A
Labels
None yet
2 participants