Hello Kevin, thanks for the question! You actually have to define the SampleType within the evalscript that you use to request the data. How you do this, and how this effects the output of your request is excellently explained in Maxim Lamare’s Medium post which you can read here.
Below is an example of how you insert the Sample Type into your evalscript. It’s important to note that using Auto means that the data is automatically scaled to the the range of UINT8 values.
Thank you for your answer.
Where can I change/insert my eval-script parameters in my SentinelHubInputTask-Python-Function? Do you have a tutorial or example for me?
Digging deeper for you, it is not possible to output data from the Sentinel-1 collection in any other SampleType other than FLOAT32, as this is the only supported output type of this collection. The input task defined below will work for you to output the data in FLOAT32.
Thank you very much, I try to follow the given exemple using this code :
import datetime
import numpy as np
from sentinelhub import CRS, BBox, DataCollection, SHConfig
from eolearn.core import EOWorkflow, FeatureType, LoadTask, OutputTask, SaveTask, linearly_connect_tasks
from eolearn.io import SentinelHubDemTask, SentinelHubEvalscriptTask, SentinelHubInputTask
config = SHConfig()
# region of interest
roi_bbox = BBox(bbox=[5.60, 52.68, 5.75, 52.63], crs=CRS.WGS84)
# time interval of downloaded data
time_interval = ("2021-04-01", "2021-05-01")
input_task = SentinelHubInputTask(
data_collection=DataCollection.SENTINEL1_IW,
bands = ['VH'],
bands_feature = (FeatureType.DATA, 'GRD_Data'),
bands_dtype = np.float32,
resolution=10,
time_difference=datetime.timedelta(minutes=120),
config=config,
max_threads=1,
aux_request_args = {
"backCoeff":"SIGMA0_ELLIPSOID",
"orthorectify":True,
"demInstance":"COPERNICUS_30"}
)
save = SaveTask("io_example", overwrite_permission=2, compress_level=1)
output_task = OutputTask("eopatch")
workflow_nodes = linearly_connect_tasks(input_task, save, output_task)
workflow = EOWorkflow(workflow_nodes)
result = workflow.execute(
{
workflow_nodes[0]: {"bbox": roi_bbox, "time_interval": time_interval},
workflow_nodes[-2]: {"eopatch_folder": "eopatch"},
)
eopatch = result.outputs["eopatch"]
```uit
however when I try to open the outputfile, it was like empty and than it has .gz extention with no image in it
Thank you very much for the provided link, Actually I already test some exemples but I was limited with the size image which is 2500*2500 pixels so I thought may be with eo-learn I will not have these restructions