Questions about s2cloudess

I met some problems when I use s2cloudless code:

  1. When I use code in sentinel2-cloud-detector/examples/sentinel2-cloud-detector-example.ipynb at master · sentinel-hub/sentinel2-cloud-detector · GitHub, there is an error about “(invalid_client) Invalid client or Invalid client credentials”. I input my ID and password for Sentinel-2, what’s the problem? Should I input something else?
  2. The input data of s2cloudless is obtained from API. However, because of my work, I cannot use API to download data (I need to select first and have a strict standard). I have to download the Sentinel-2 data and get “.tiff” file by myself. In this way, how could I use s2cloudless?

Hi @mqqqqqq!

Thanks for the question, and welcome to the SH Forum!

When I use code in sentinel2-cloud-detector/examples/sentinel2-cloud-detector-example.ipynb at master · sentinel-hub/sentinel2-cloud-detector · GitHub , there is an error about “(invalid_client) Invalid client or Invalid client credentials”. I input my ID and password for Sentinel-2, what’s the problem? Should I input something else?

When you say input ID and password, do you mean your login credentials? If yes, then this is the problem, since you should provide your access and secret key pair, which you can create on your SH dashboard. You can find more information in the third paragraph here. Let me know if this works for you :slight_smile:

The input data of s2cloudless is obtained from API. However, because of my work, I cannot use API to download data (I need to select first and have a strict standard). I have to download the Sentinel-2 data and get “.tiff” file by myself. In this way, how could I use s2cloudless?

OK, so assuming you already have bands in the form of .tif files, I suggest you load the band data as numpy arrays (with rasterio) and put them in a shape which is the same as the shape of the bands variable used in the notebook you linked. Then the code should work for you from the Initialize the cloud detector and make classification section onward.

Let me know if you need any help with this part as well.

Good luck!
Matic