EcoJulia / RasterDataSources.jl

Easily download and use raster data sets in Julia
MIT License
21 stars 10 forks source link

Adding scale to MODIS #61

Open mdmaas opened 9 months ago

mdmaas commented 9 months ago

Hi! I'm finding this is an amazing package!

I want to use it for MODIS data, which is marked as beta. One issue I'm seeing is that, for example NDVI data is not scaled automatically, and that the metadata shows a scale factor of 1.0 instead of the proper values which in some cases should be 0.0001 (as shown here under the Layers tab).

So let's say I create a table with the information in the LPDAAC page... where it should be added? Once the scale factor in the metadata is correct, will it propagate to any uses of the data?

Thanks!

rafaqz commented 9 months ago

You could add a scale function that accepts the same arguments as getraster, so would return matching values in Vector/NamedTuple just like getraster does?

Im not sure how else we could propagate them.

mdmaas commented 9 months ago

Ok, I'll add a scale function with the different MODIS producs, and then we'll see what can be done at the Rasters.jl level. I believe what MODIS is doing is storing data in a "scaledInt" numerical format, for compression purposes.

rafaqz commented 9 months ago

Rasters needs modis loading to be implementrd anyway right? We could use both in that.