File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change 99 },
1010 "outputs" : [],
1111 "source" : [
12- " # Copyright 2025 Google LLC\n " ,
12+ " # Copyright 2026 Google LLC\n " ,
1313 " #\n " ,
1414 " # Licensed under the Apache License, Version 2.0 (the \" License\" );\n " ,
1515 " # you may not use this file except in compliance with the License.\n " ,
125125 " \n " ,
126126 " def to_b64_png(img: Image.Image) -> str:\n " ,
127127 " \"\"\" Converts the `img` to a b64 encoded PNG bytes.\"\"\"\n " ,
128- " return base64.b64encode (to_png_bytes(img)).decode()\n " ,
128+ " return base64.urlsafe_b64encode (to_png_bytes(img)).decode()\n " ,
129129 " \n " ,
130130 " \n " ,
131131 " def write_jsonl_instances(\n " ,
Original file line number Diff line number Diff line change 9595 " )\n " ,
9696 " \n " ,
9797 " # Model configuration & utils\n " ,
98- " SERVE_DOCKER_URI = \" us-docker.pkg.dev/vertex-ai-restricted/vertex-vision-model-garden-dockers/remote-sensing-serve-tf-gpu:latest \"\n " ,
98+ " SERVE_DOCKER_URI = \" us-docker.pkg.dev/vertex-ai-restricted/vertex-vision-model-garden-dockers/remote-sensing-serve-tf-gpu:release \"\n " ,
9999 " MODEL_CONFIGS = {\n " ,
100100 " \" OWLVIT\" : (\n " ,
101101 " \" earth-ai-imagery-owlvit-eap-10-2025\" ,\n " ,
268268 " def _b64_png(image: Image.Image) -> str:\n " ,
269269 " arr_bytes = io.BytesIO()\n " ,
270270 " image.save(arr_bytes, format=\" PNG\" )\n " ,
271- " return base64.b64encode (arr_bytes.getvalue()).decode(\" utf-8\" )\n " ,
271+ " return base64.urlsafe_b64encode (arr_bytes.getvalue()).decode(\" utf-8\" )\n " ,
272272 " \n " ,
273273 " \n " ,
274274 " # Download sample images\n " ,
You can’t perform that action at this time.
0 commit comments