Skip to content

docs(people-and-planet-ai): align wildlife notebook with updated clou… - #14763

Merged
iennae merged 3 commits into
mainfrom
feat/modernize-ppai-image-classification
Nov 6, 2026
Merged

iennae merged 3 commits into
mainfrom
feat/modernize-ppai-image-classification

Conversation

@iennae

@iennae iennae commented Nov 5, 2026

Copy link
Copy Markdown
Contributor

…d-sample-notebook standards

Update people-and-planet-ai/image-classification/README.ipynb to adhere to the updated cloud-sample-notebook lifecycle and formatting guidelines while preserving the original Cell 0 ASF license header:

  • Use the 3-link launch badge bar (Colab, Colab Enterprise via /vertex-ai/colab/import/, and GitHub) and add the Author table.
  • Add Objectives, Costs (with Pricing Calculator link), and Prerequisites subsections under Overview.
  • Guard only !apt-get install libffi-dev behind google.colab and run the idempotent sparse-checkout unconditionally when not already inside people-and-planet-ai/image-classification.
  • Add # fmt: off / # fmt: on around @PARAM configuration blocks.
  • Add a 'Validate target state' programmatic assertion section before 'Cleaning up' and default delete_resources to False.

Description

Fixes #

Checklist

Testing

  • I have tested this change on a live environment and verified it works as intended.

Compliance & Style


Post-Approval Actions

  • Please merge this PR for me once it is approved

…d-sample-notebook standards

Update people-and-planet-ai/image-classification/README.ipynb to adhere
to the updated cloud-sample-notebook lifecycle and formatting guidelines
while preserving the original Cell 0 ASF license header:
- Use the 3-link launch badge bar (Colab, Colab Enterprise via
  /vertex-ai/colab/import/, and GitHub) and add the Author table.
- Add Objectives, Costs (with Pricing Calculator link), and Prerequisites
  subsections under Overview.
- Guard only !apt-get install libffi-dev behind google.colab and run the
  idempotent sparse-checkout unconditionally when not already inside
  people-and-planet-ai/image-classification.
- Add # fmt: off / # fmt: on around @PARAM configuration blocks.
- Add a 'Validate target state' programmatic assertion section before
  'Cleaning up' and default delete_resources to False.
@iennae
iennae requested review from a team as code owners November 5, 2026 04:47
@product-auto-label product-auto-label Bot added samples Issues that are directly related to samples. api: people-and-planet-ai labels Nov 5, 2026

@gemini-code-assist gemini-code-assist Bot left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Code Review

This pull request updates the image classification README notebook by updating the Colab Enterprise import link, adding sections for objectives, costs, and prerequisites, and introducing a validation step for the target state. The feedback suggests a robust improvement to the validation step, recommending that the assertion checks the actual contents of the generated 'embeddings.jsonl' file rather than relying on in-memory variables.

…adge URL in wildlife notebook

Restore https://console.cloud.google.com/agent-platform/colab/import/...
as the Open in Colab Enterprise badge link in
people-and-planet-ai/image-classification/README.ipynb.
… notebook and use patch.object

- Update the Validate target state cell in people-and-planet-ai/image-classification/README.ipynb
  to read and parse embeddings.jsonl from disk and verify all 6 gallery rows (URI, species label,
  and 768-dimensional embedding vector) rather than only checking in-memory variables.
- Replace raw string mock.patch("requests.get") with target-safe mock.patch.object in e2e_test.py.

@amcolin amcolin left a comment

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

LGTM 👍

@iennae
iennae merged commit 355a49d into main Nov 6, 2026
14 of 22 checks passed
@iennae
iennae deleted the feat/modernize-ppai-image-classification branch November 6, 2026 00:15
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

api: people-and-planet-ai samples Issues that are directly related to samples.

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants