Bucket does not exist

I run this code on my local terminal…right ? or is there a remote terminal which i need to use ?

Hi Jens,

The policy looks correct. We have been trying to solve the issue for you. We think to solve this you need to adapt the Bucket Name itself in your request. Currently it is JensContainer. For Creodias, Sentinel Hub needs to know your Project ID. You can find this on the same Cloud Ferro dashboard. If you click on the identity menu below object store in the left hand menu you should see a menu similar to the one screenshotted below:

You can then append the project ID to your bucket path like this with a colon separating them:

BUCKET_NAME = '{project_ID}:{Bucket_name}'

You should then have no problem locating your bucket.

Thanks William,
i tried several formats,

bucket_name = ‘70703b6fe962495a89c5b76190ddf259:JensContainer’ # bucket name

but i always get the error

ParamValidationError: Parameter validation failed:
Invalid bucket name “xxxx:JensContainer”: Bucket name must match the regex “^[a-zA-Z0-9.-_]{1,255}$” or be an ARN matching the regex “^arn:(aws).:(s3|s3-object-lambda):[a-z-0-9]:[0-9]{12}:accesspoint[/:][a-zA-Z0-9-.]{1,63}$|^arn:(aws).*:s3-outposts:[a-z-0-9]+:[0-9]{12}:outpost[/:][a-zA-Z0-9-]{1,63}[/:]accesspoint[/:][a-zA-Z0-9-]{1,63}$”

OK can you please share the full request, you should be able to do this by copying it from Request Builder or wherever you are building your Batch Processing request.

like this ?

curl -X POST https://creodias.sentinel-hub.com/api/v1/batch/process/ \
 -H 'Content-Type: application/json' \
 -H 'Authorization: Bearer \
 -d '{
  "processRequest": {
    "input": {
      "bounds": {
        "bbox": [
          5.719757,
          54.237143,
          6.931,
          54.670655
        ]
      },
      "data": [
        {
          "dataFilter": {
            "timeRange": {
              "from": "2021-07-11T00:00:00Z",
              "to": "2021-07-11T23:59:59Z"
            }
          },
          "type": "sentinel-3-olci",
          "id": "S3OLCI"
        },
        {
          "dataFilter": {
            "timeRange": {
              "from": "2021-07-11T00:00:00Z",
              "to": "2021-07-11T23:59:59Z"
            }
          },
          "type": "sentinel-3-slstr",
          "id": "S3SLSTR"
        }
      ]
    },
    "output": {
      "responses": [
        {
          "identifier": "default",
          "format": {
            "type": "image/tiff"
          }
        }
      ]
    },
    "evalscript": "// VERSION 3\n\nvar option = 1;\n\n// minimum and maximum values for output colour chart red to white for temperature in °C. Option 2 overwrites this selection!\nvar minC = -15;\nvar maxC = 20;\n\n\n\nvar NDVIs = 0.2;\nvar NDVIv = 0.8;\n\n// emissivity\nvar waterE = 0.991;\nvar soilE = 0.966;\nvar vegetationE = 0.973;\n//var buildingE=0.962;\nvar C = 0.009; \n\n\nvar bCent = 0.000010854;\n\n// rho =h*c/sigma=PlanckC*velocityLight/BoltzmannC\nvar rho = 0.01438; // m K\n\n//// visualization\n// if result should be std dev (option=2), overwrite minMaxC.\nif (option == 2) {\n  minC = 0;\n  maxC = 50;\n}\nlet viz = ColorGradientVisualizer.createRedTemperature(minC, maxC);\n\n\n\nfunction setup() {\n  return {\n    input: [\n      { datasource: \"S3SLSTR\", bands: [\"S8\"] },\n      { datasource: \"S3OLCI\", bands: [\"B06\", \"B08\", \"B17\"] }],\n    output: [\n      { id: \"default\", bands: 3, sampleType: SampleType.AUTO }\n    ],\n    mosaicking: \"ORBIT\"\n  }\n}\n\n\n\nfunction LSEcalc(NDVI, Pv) {\n  var LSE;\n  if (NDVI < 0) {\n    //water\n    LSE = waterE;\n  } else if (NDVI < NDVIs) {\n    //soil\n    LSE = soilE;\n  } else if (NDVI > NDVIv) {\n    //vegetation\n    LSE = vegetationE;\n  } else {\n    //mixtures of vegetation and soil\n    LSE = vegetationE * Pv + soilE * (1 - Pv) + C;\n  }\n  return LSE;\n}\n\nfunction evaluatePixel(samples) {\n  // starting values max, avg, stdev, reduce N, N for multi-temporal\n  var LSTmax = -999;\n  var LSTavg = 0;\n  var LSTstd = 0;\n  var reduceNavg = 0;\n  var N = samples.S3SLSTR.length;\n\n  //to caputure all values of one pixel for for whole timeline in mosaic order\n  var LSTarray = [];\n\n  // multi-temporal: loop all samples in selected timeline\n  for (let i = 0; i < N; i++) {\n    //// for LST S8\n    var Bi = samples.S3SLSTR[i].S8;\n    var B06i = samples.S3OLCI[i].B06;\n    var B08i = samples.S3OLCI[i].B08;\n    var B17i = samples.S3OLCI[i].B17;\n\n    if ((Bi > 173 && Bi < 65000) && (B06i > 0 && B08i > 0 && B17i > 0)) {\n\n      var S8BTi = Bi - 273.15;\n\n      var NDVIi = (B17i - B08i) / (B17i + B08i);\n\n      var PVi = Math.pow(((NDVIi - NDVIs) / (NDVIv - NDVIs)), 2);\n\n      var LSEi = LSEcalc(NDVIi, PVi);\n      //5 LST\n      var LSTi = (S8BTi / (1 + (((bCent * S8BTi) / rho) * Math.log(LSEi))));\n\n  \n      LSTavg = LSTavg + LSTi;\n      //max\n      if (LSTi > LSTmax) { LSTmax = LSTi; }\n      //array\n      LSTarray.push(LSTi);\n    } else {\n      // image NOT ok\n      ++reduceNavg;\n    }\n  }\n\n  N = N - reduceNavg;\n\n  // calc final avg value\n  LSTavg = LSTavg / N;\n\n  // calc final stdev value\n  for (let i = 0; i < LSTarray.length; i++) {\n    LSTstd = LSTstd + (Math.pow(LSTarray[i] - LSTavg, 2));\n  }\n  LSTstd = (Math.pow(LSTstd / (LSTarray.length - 1), 0.5));\n\n  let outLST = (option == 0)\n    ? LSTavg\n    : (option == 1)\n      ? LSTmax\n      : LSTstd;\n\n  //// output to image\n  return viz.process(outLST);\n}\n"
  },
  "tilingGrid": {
    "id": 1,
    "resolution": 10
  },
  "bucketName": "70703b6fe962495a89c5b76190ddf259:JensContainer"
}'

image

Hi Jens, Thanks for your patience. Unfortunately, the Sentinel Hub APIs only supports the WAW2-1 (cf2.cloudferro.com) endpoint. This is the reason why you are not able to find your bucket because it is located in the WAW3-1 endpoint (this supports the Copernicus Data Space Ecosystem deployment of Sentinel Hub).

Therefore, there are two options to move forward:

  1. You can apply to become a Copernicus Services User on Copernicus Data Space Ecosystem by making a request here. You can try out the Batch Processing API in the Copernicus Data Space Ecosystem deployment of Sentinel Hub, this will be fully compatible with your current bucket setup and you can follow the documentation there. There is even a deployment of Request Builder there for you to use.
  2. Apply to Creodias to create a bucket in the WAW2-1 region that you can use with Sentinel Hub APIs, you would need to reach out to Cloud Ferro to do this. A way you could do this is through the Network of Resources which you can obtain sponsorship from ESA to apply for Sentinel Hub access as well as S3 storage on Creodias. For more information, you can visit this website.

If you have more questions, don’t hesitate to reach out.

Hi William,
well…this is kind of confusing
But anyhow, thanks for your 2 ways to move forward!
Option 1 sounds like a good way to go…but i also fail here.
I have a Copernicus Copernicus General User Account and i am logged in.
Still, I cannot submit a request to upgrade…as it says I have to login…and the login button on the site is not doing anything…maybe tomorrow it works…
cheers!
Jens

Hi Jens,

Yes, unfortunately it is a little confusing. That is strange behaviour from the website. There is no problem for me logging in. Can you try clearing your cache and trying again? Which browser/OS are you using?

Hi William,
thanks for asking - after emptying the cache and restarting the firefox 122.0.1 browser on Ubuntu 20.04.06 LTS it worked fine.
best wishes !
Jens

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.