1

I am having trouble indexing GeoTIFF files using the Python API. I have managed to generate a .yml file for my .tif file and would like to now add it to the index. Basically what datacube dataset add XYZ.yml would do.

I was able to find

dc.index.datasets.add(dataset)

I then created the dataset:

yml = yaml.safe_load(ymlfile) # ymlfile is the corresponding XYZ.yml
dataset=datacube.model.Dataset(???,cfg)

but I can't seem to figure out what the DatasetType should be.

Vince
20.5k16 gold badges49 silver badges65 bronze badges
asked Jun 21, 2021 at 10:50

1 Answer 1

0

A "Dataset Type" is a Product Definition, as documented here.

The simplest way to programmatically get a document indexed is documented here.

A slightly different example is captured in code here.

answered Jun 23, 2021 at 1:55
0

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.