opendatacube / datacube-core

Open Data Cube analyses continental scale Earth Observation data through time
http://www.opendatacube.org
Apache License 2.0
505 stars 176 forks source link

Dataset loading by geometry is not working #1371

Closed uotamendi closed 1 year ago

uotamendi commented 1 year ago

Expected behaviour

Load available dataset with query

Actual behaviour

Loads 0 datasets

Steps to reproduce the behaviour

datasets = dc.find_datasets(product=SOURCE_PRODUCT,
                                time=(start_date.strftime("%Y-%m-%d"),
                                      end_date.strftime("%Y-%m-%d")),
                                )
datasets2 = dc.find_datasets(product=SOURCE_PRODUCT,
                                time=(start_date.strftime("%Y-%m-%d"),
                                      end_date.strftime("%Y-%m-%d")),
                                geopolygon=datasets[0].extent,
                                )

datasets2 is empty

Environment information

datacube==1.8.9 Open Data Cube core, version 1.8.9

Note: Stale issues will be automatically closed after a period of six months with no activity. To ensure critical issues are not closed, tag them with the Github pinned tag. If you are a community member and not a maintainer please escalate this issue to maintainers via GIS StackExchange or Slack.

SpacemanPaul commented 1 year ago

Thanks for raising. I'm currently working on this part of the code so should be able to address relatively soon.

SpacemanPaul commented 1 year ago

I cannot reproduce this.

>>> datasets = dc.find_datasets(product='ga_ls8c_ard_3', time=('2018-01-01', '2018-01-12'))
>>> datasets2 = dc.find_datasets(product='ga_ls8c_ard_3', time=('2018-01-01', '2018-01-12'), geopolygon=datasets[0].extent)
>>> len(datasets)
384
>>> len(datasets2)
3
>>> datasets[0] in datasets2
True

Please attach the metadata type and product documents, and the dataset document for your datasets[0].

SpacemanPaul commented 1 year ago

Can't reproduce