Hi,
I am trying to save a combined tiff image for the following bands for a specific bounding box. When outputting just the RGB bands I am able to see the image without any issues. However, as soon as I add the other bands the image is no longer visible (it is black with a white bar in the middle).
What am I doing wrong here? I tried playing with different scaling factor etc.
Should be using different unit or scaling factor?
function setup() {{
return {{
input: ["B02", "B03", "B04", "B08", "B11", "B12", "dataMask"],
output: [{truecolor_str}],
mosaicking: "TILE"
}};
}}
function evaluatePixel(samples) {{
var scaleFactor = 2.5;
var b02_array = [];
var b03_array = [];
var b04_array = [];
var b08_array = [];
var datamask_array = [];
samples.forEach((sample, index) => {{
b02_array[index] = sample.B02 * scaleFactor;
b03_array[index] = sample.B03 * scaleFactor;
b04_array[index] = sample.B04 * scaleFactor;
b08_array[index] = sample.B08 * scaleFactor;
datamask_array[index] = sample.dataMask;
}});
I am using sentinelHubRequest API
response = SentinelHubRequest(
data_folder="test_dir",
evalscript=evalscript,
input_data=[
SentinelHubRequest.input_data(
data_collection=collection,
time_interval=time_interval,
mosaicking_order=MosaickingOrder.LEAST_CC
)
],
responses=response_list,
bbox=bbox,
size=bbox_size,
config=config,
)