diff --git a/colabs/wandb_registry/zoo_wandb.ipynb b/colabs/wandb_registry/zoo_wandb.ipynb
index 1a0ed40b..b4302111 100644
--- a/colabs/wandb_registry/zoo_wandb.ipynb
+++ b/colabs/wandb_registry/zoo_wandb.ipynb
@@ -2,6 +2,7 @@
"cells": [
{
"cell_type": "markdown",
+ "id": "822e8bc6",
"metadata": {},
"source": [
"\n",
@@ -33,7 +34,7 @@
"source": [
"The goal of this notebook is to demonstrate how you and other members of your organization can use W&B Registry to track, share, and use dataset and model artifacts in your machine learning workflows. By the end of this notebook, you will know how to use W&B to:\n",
"\n",
- "1. Create [collections](https://docs.wandb.ai/guides/registry/create_collection) within the [W&B Registry](https://docs.wandb.ai/guides/registry)\n",
+ "1. Create [collections](https://docs.wandb.ai/guides/registry/create_collection) within [W&B Registry](https://docs.wandb.ai/guides/registry)\n",
"2. Make dataset and model artifacts available to other members of your organization, and\n",
"3. Download your trained model and dataset artifacts from the registry for inference\n",
"\n",
@@ -194,7 +195,7 @@
"#### Define target path of the collection\n",
"\n",
"The target path of a collection consists of three parts:\n",
- "* The name of the organization\n",
+ "* The name of your W&B Organization\n",
"* The name of the registry\n",
"* The name of the collection within the registry\n",
"\n",
@@ -217,7 +218,9 @@
"1. Initialize a run\n",
"1. Create an Artifact object\n",
"2. Add each split dataset as individual files to the artifact object\n",
- "3. Link the artifact object to the collection with `run.link_artifact()`. Here we specify the target path and the artifact we want to link."
+ "3. Link the artifact object to the collection with `run.link_artifact()`. Here we specify the target path and the artifact we want to link.\n",
+ "\n",
+ "First, let's create the target path. In the following code cell, replace the values specified in `<>` with the name of your organization:"
]
},
{
@@ -227,7 +230,7 @@
"metadata": {},
"outputs": [],
"source": [
- "ORG_NAME = \"smle-registries-bug-bash\"\n",
+ "ORG_NAME = \"\"\n",
"REGISTRY_NAME = \"Dataset\"\n",
"COLLECTION_NAME = \"zoo-dataset-tensors\"\n",
"\n",
@@ -235,6 +238,14 @@
"dataset_target_path = f\"{ORG_NAME}/wandb-registry-{REGISTRY_NAME}/{COLLECTION_NAME}\""
]
},
+ {
+ "cell_type": "markdown",
+ "id": "66d03210-1de4-44a4-9773-67b4f5d71dfc",
+ "metadata": {},
+ "source": [
+ "Now that we have the target path, let's publish the dataset to the \"Dataset\" registry. In the following code cell, ensure to replace the values enclosed in `<>` with your team's entity:"
+ ]
+ },
{
"cell_type": "code",
"execution_count": null,
@@ -242,8 +253,8 @@
"metadata": {},
"outputs": [],
"source": [
+ "TEAM_ENTITY = \"\"\n",
"PROJECT = \"zoo_experiment\"\n",
- "TEAM_ENTITY = \"smle-reg-team-2\"\n",
"\n",
"run = wandb.init(\n",
" entity=TEAM_ENTITY,\n",
@@ -253,7 +264,7 @@
"\n",
"artifact = wandb.Artifact(\n",
" name=\"zoo_dataset\",\n",
- " type=\"dataset\", \n",
+ " type=\"dataset\", \n",
" description=\"Processed dataset and labels.\"\n",
")\n",
"\n",
@@ -615,7 +626,6 @@
"metadata": {},
"outputs": [],
"source": [
- "ORG_NAME = \"smle-registries-bug-bash\"\n",
"REGISTRY_NAME = \"Model\"\n",
"COLLECTION_NAME = \"Zoo_Classifier_Models\"\n",
"\n",
@@ -686,12 +696,11 @@
"---\n",
"## Download artifacts from registry for inference\n",
"\n",
- "For this last section, suppose you are in a different user on a different team (within the same organiztion) than the user who uploaded the artifact. You want to retrieve the model and dataset artifact pushed to the registry and make predictions with a new test set. Your team is called \"smle-reg-team-1\" (previously the team was \"smle-reg-team-2\") and your team is working on analyzing zoo models in a project called \"Compare_Zoo_Models\".\n",
+ "For this last section, suppose you are a different user in a different team within the same organization. You and your team want to download the model and test dataset that was published to your organization's registry by a different team. You and your team will use the model and test dataset for inference and store those findings in a project called \"Check_Zoo_Model\".\n",
"\n",
+ "Note: The team member that wants do use and download published artifacts has [member role permissions](https://docs.wandb.ai/guides/registry/configure_registry#registry-roles-permissions). This means they can view and download artifacts from the registry.\n",
"\n",
- "Also suppose that this user has [member role permissions](https://docs.wandb.ai/guides/registry/configure_registry#registry-roles-permissions) which means they can view and download artifacts from our registry.\n",
- "\n",
- "How can you retrieve the artifacts version that were published by another user in another team? Simple:\n",
+ "How can you retrieve the artifacts version that were published by another team? Simple:\n",
"\n",
"1. Get the full name of the artifact version programmatically or interactively with the W&B App UI\n",
"2. Use the W&B Python SDK to download the artifacts\n",
@@ -723,7 +732,6 @@
"outputs": [],
"source": [
"# Create model artifact name\n",
- "ORG_NAME = \"smle-registries-bug-bash\"\n",
"REGISTRY_NAME = \"model\"\n",
"COLLECTION_NAME = \"Zoo_Classifier_Models\"\n",
"VERSION = 0\n",
@@ -732,6 +740,16 @@
"print(f\"Model artifact name: {model_artifact_name}\")"
]
},
+ {
+ "cell_type": "markdown",
+ "id": "c6953db2-aad2-484f-8dfa-f88180288682",
+ "metadata": {},
+ "source": [
+ "In the following code cell, ensure to replace the values enclosed in `<>` with the entity of a different team in your organization than the one you specified earlier in this notebook.\n",
+ "\n",
+ "Note: If you do not have another team entity, you can re-use the entity you specified earlier."
+ ]
+ },
{
"cell_type": "code",
"execution_count": null,
@@ -740,8 +758,8 @@
"outputs": [],
"source": [
"# Enter information about your team and your team's project\n",
- "DIFFERENT_TEAM_ENTITY = \"smle-reg-team-1\"\n",
- "DIFFERENT_PROJECT = \"Compare_Zoo_Models\"\n",
+ "DIFFERENT_TEAM_ENTITY = \"\"\n",
+ "DIFFERENT_PROJECT = \"Check_Zoo_Model\"\n",
"\n",
"run = wandb.init(entity=DIFFERENT_TEAM_ENTITY, project=DIFFERENT_PROJECT)\n",
"registry_model = run.use_artifact(artifact_or_name=model_artifact_name)\n",
@@ -1014,8 +1032,21 @@
"toc_visible": true
},
"kernelspec": {
- "display_name": "Python 3",
- "name": "python3"
+ "display_name": "example_notebooks",
+ "language": "python",
+ "name": "example_notebooks"
+ },
+ "language_info": {
+ "codemirror_mode": {
+ "name": "ipython",
+ "version": 3
+ },
+ "file_extension": ".py",
+ "mimetype": "text/x-python",
+ "name": "python",
+ "nbconvert_exporter": "python",
+ "pygments_lexer": "ipython3",
+ "version": "3.10.0"
}
},
"nbformat": 4,