Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
53 commits
Select commit Hold shift + click to select a range
a80e78e
Update run_elastic_blast.ipynb
RamiyapriyaS-NIH Apr 29, 2025
9d03e64
Github Action: Lint Notebooks
Apr 29, 2025
7ea5a8a
Update run_elastic_blast.ipynb
RamiyapriyaS-NIH Apr 29, 2025
754bfa6
Update Part1_GBatch_Nextflow.ipynb
RamiyapriyaS-NIH Apr 29, 2025
ef6b430
Add files via upload
RamiyapriyaS-NIH Apr 29, 2025
ca59be2
Github Action: Lint Notebooks
Apr 29, 2025
e5c6f4f
Update GCP_RAG_for_Structure_Data.ipynb
RamiyapriyaS-NIH Apr 29, 2025
5f61fcd
Add files via upload
RamiyapriyaS-NIH Apr 29, 2025
fcf50ed
Github Action: Lint Notebooks
Apr 29, 2025
98b5b2a
Add files via upload
RamiyapriyaS-NIH Apr 29, 2025
ff23adb
Github Action: Lint Notebooks
Apr 29, 2025
8fa4d32
Add files via upload
RamiyapriyaS-NIH Apr 30, 2025
0c51b6c
Github Action: Lint Notebooks
Apr 30, 2025
c6fc2e1
updated install instructions
RamiyapriyaS-NIH Apr 30, 2025
d218b5a
Github Action: Lint Notebooks
Apr 30, 2025
def870e
Update SRA-Download.ipynb
RamiyapriyaS-NIH Apr 30, 2025
6f49bc1
updated installation instructions
RamiyapriyaS-NIH Apr 30, 2025
24e54be
Github Action: Lint Notebooks
Apr 30, 2025
ef413de
Update compute-engine-idle-shutdown.md
RamiyapriyaS-NIH Apr 30, 2025
d0d8a18
Update 1-d10-run-first.ipynb
RamiyapriyaS-NIH Apr 30, 2025
bfa9b52
Add files via upload
RamiyapriyaS-NIH Apr 30, 2025
3d52541
Update vertexai.md
RamiyapriyaS-NIH Apr 30, 2025
81217dc
Update idle-shutdown.sh
RamiyapriyaS-NIH Apr 30, 2025
747ad90
Update example_langchain_chat_llama_2_zeroshot.py
RamiyapriyaS-NIH Apr 30, 2025
f216c90
Update example_vectorsearch_chat_llama_2_zeroshot.py
RamiyapriyaS-NIH Apr 30, 2025
2fbe29e
Update protein_setup.md
RamiyapriyaS-NIH May 1, 2025
69976c5
updating installation instructions
RamiyapriyaS-NIH May 1, 2025
6557701
Github Action: Lint Notebooks
May 1, 2025
5415d07
Update README.md
RamiyapriyaS-NIH May 1, 2025
cb5984a
Add files via upload
RamiyapriyaS-NIH May 1, 2025
2c96bcf
Github Action: Lint Notebooks
May 1, 2025
d21dc13
Add files via upload
RamiyapriyaS-NIH May 1, 2025
97fb8ba
Github Action: Lint Notebooks
May 1, 2025
8faeaa4
Add files via upload
RamiyapriyaS-NIH May 1, 2025
c93d9db
Github Action: Lint Notebooks
May 1, 2025
1d556f6
Add files via upload
RamiyapriyaS-NIH May 1, 2025
94f8e62
Update GCP_Grounding.ipynb
RamiyapriyaS-NIH May 1, 2025
0468b7e
Add files via upload
RamiyapriyaS-NIH May 1, 2025
d5d7449
Add files via upload
RamiyapriyaS-NIH May 1, 2025
d813b63
Github Action: Lint Notebooks
May 1, 2025
0c042e8
Add files via upload
RamiyapriyaS-NIH May 2, 2025
5bb3b23
Github Action: Lint Notebooks
May 2, 2025
026120b
Add files via upload
RamiyapriyaS-NIH May 2, 2025
54ebd58
Update GCP_Code_Chatbot_wGrounding.ipynb
RamiyapriyaS-NIH May 2, 2025
82d7eeb
Add files via upload
RamiyapriyaS-NIH May 2, 2025
66cedfc
Github Action: Lint Notebooks
May 2, 2025
539303c
Add files via upload
RamiyapriyaS-NIH May 2, 2025
74b96b2
Add files via upload
RamiyapriyaS-NIH May 2, 2025
401bf66
Github Action: Lint Notebooks
May 2, 2025
4817ef5
Add files via upload
RamiyapriyaS-NIH May 2, 2025
7615495
Github Action: Lint Notebooks
May 2, 2025
9dfc7dd
added variables back
zbyosufzai May 2, 2025
99c1c57
added variable back
zbyosufzai May 2, 2025
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
4 changes: 3 additions & 1 deletion docs/compute-engine-idle-shutdown.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,7 +2,9 @@
This guide walks you through how to automatically configure auto-shutdown capabilities on any GCP virtual machine. Put simply, you only need to add a startup script that shuts down the VM after a specified period of inactivity. This safeguard helps ensure you don't forget to shut off your VM over the weekend, and accidentally burn through a big chunk of your budget.

## 1. Configure auto-shutdown on Vertex AI Notebook Instance
When starting a new VertexAI notebook, you can enable idle shutdown by simply clicking a box and specifying the amount of time you want your machine idle before it shuts down. See our [VertexAI startup guide](/docs/vertexai.md) to see how to enable this important feature.
When starting a new VertexAI notebook, you can enable idle shutdown by navigating to **Advanced options** and checking the box for enabling auto-shutdown. You must specify the amount of time you want your machine idle before it shuts down. See our [VertexAI startup guide](/docs/vertexai.md) to see how to enable this important feature.

![image showing idle shutdown selection](/images/images_for_creating_GCP_instances/6_instance_idle_shutdown.png)

For additional details on the other settings for user managed notebooks, see [this VertexAI Quickstart](https://cloud.google.com/vertex-ai/docs/workbench/user-managed/create-user-managed-notebooks-instance-console-quickstart).

Expand Down
2 changes: 1 addition & 1 deletion docs/idle-shutdown.sh
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
# NOTE: requires `bc`, eg, sudo apt-get install bc
# Modified from https://stackoverflow.com/questions/30556920/how-can-i-automatically-kill-idle-gce-instances-based-on-cpu-usage

sudo apt-get install bc
sudo apt-get install bc -y

# This is the CPU usage threshold. If activity falls below 10% for the specified time below, the VM shutsdown.
# If you want the shutdown to be more sensitive, you can set this higher, so that a smaller drop in CPU activity will cause shutdown.
Expand Down
20 changes: 17 additions & 3 deletions docs/protein_setup.md
Original file line number Diff line number Diff line change
@@ -1,7 +1,21 @@
!curl -L -O https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-$(uname)-$(uname -m).sh
# Setting Up the Environment to Run AlphaFold on Vertex AI

!bash Mambaforge-$(uname)-$(uname -m).sh -b -p $HOME/mambaforge
## 1. Install Mamba (via Mambaforge)
Use the following commands to install Mambaforge:

!../../mambaforge/bin/mamba install -y -c conda-forge pandas-gbq pandas
```bash
# Download the Mambaforge installer
curl -L -O https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-$(uname)-$(uname -m).sh

# Install Mambaforge to your home directory
bash Mambaforge-$(uname)-$(uname -m).sh -b -p $HOME/mambaforge

# Use mamba to install required Python packages
$HOME/mambaforge/bin/mamba install -y -c conda-forge pandas-gbq pandas
```
## 2. Install Google Colab Package
Use the following command to install google-colab:

```bash
pip install google-colab
```
4 changes: 2 additions & 2 deletions docs/vertexai.md
Original file line number Diff line number Diff line change
@@ -1,9 +1,9 @@
# Using VertexAI Notebooks

### 1. Spin up an Instance
1. Start by clicking the `hamburger menu` (the three horizontal lines in the top left of your console). Go to `Artificial Intelligence > Vertex AI > Workbench`.
1. Start by clicking the `hamburger menu` (the three horizontal lines in the top left of your console). Go to `Vertex AI > Workbench`.

![screenshot showing how to select Vertex AI workbench](/images/images_for_creating_GCP_instances/1_select_vertexAI.png)
![screenshot showing how to select Vertex AI workbench](../images/1_select_vertexAI.jpeg)

2. If not already selected, click **Instances**, then **Instances**
3. Click **+ Create New**
Expand Down
Binary file added images/10_chatbot_grounding.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/12_chatbot_grounding.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/13_chatbot_grounding.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/14_chatbot_grounding.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/1_select_vertexAI.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/7_chatbot_grounding.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/8_chatbot_grounding.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/9_chatbot_grounding.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/agent_builder1.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/agent_builder2.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/create-prompt.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added images/vertex-ai-create-prompt.jpeg
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
2 changes: 1 addition & 1 deletion notebooks/DL-gwas-gcp-example/1-d10-run-first.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@
"metadata": {},
"source": [
"## Prerequisites\n",
"See the [README](/notebooks/DL-gwas-gcp-example/README.md) in this directory. "
"See the [README](./README.md) in this directory. "
]
},
{
Expand Down
57 changes: 55 additions & 2 deletions notebooks/GWASCoatColor/GWAS_coat_color.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,16 @@
"metadata": {},
"source": [
"#### Install dependencies\n",
"Here we install mamba, which is faster than conda, but it can be tricky to add to path in a Sagemaker notebook so we just call the whole path. You could also skip this install and just use conda since that is preinstalled in the kernel."
"\n",
"The dependencies required to run this tutorial are `plink` and `vcftools`. A few different installation methods are given below. \n"
]
},
{
"cell_type": "markdown",
"id": "aa39cb82-ad03-4427-8173-2d5738e3eff5",
"metadata": {},
"source": [
"##### Method 1: Install with Mamba "
]
},
{
Expand All @@ -91,6 +100,7 @@
"metadata": {},
"outputs": [],
"source": [
"#If you don't have mamba installed, you can install it with the following command: \n",
"! curl -L -O https://github.com/conda-forge/miniforge/releases/latest/download/Mambaforge-$(uname)-$(uname -m).sh\n",
"! bash Mambaforge-$(uname)-$(uname -m).sh -b -p $HOME/mambaforge"
]
Expand All @@ -102,7 +112,7 @@
"metadata": {},
"outputs": [],
"source": [
"#add to your path\n",
"#add mamba to your path\n",
"import os\n",
"os.environ[\"PATH\"] += os.pathsep + os.environ[\"HOME\"]+\"/mambaforge/bin\""
]
Expand All @@ -114,9 +124,52 @@
"metadata": {},
"outputs": [],
"source": [
"#Install dependencies with mamba\n",
"! mamba install -y -c bioconda plink vcftools"
]
},
{
"cell_type": "markdown",
"id": "720c6daa-4ee0-4db1-a94f-1f2b01e2f9f3",
"metadata": {},
"source": [
"##### Method 2: Install manually"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "1718f0a0-00b8-4d8b-8049-1bf705d1a8da",
"metadata": {},
"outputs": [],
"source": [
"#Plink installation \n",
"\n",
"# Please run these steps in the terminal\n",
"# 1. Download the PLINK 1.9 binary (Linux 64-bit)\n",
"! wget http://s3.amazonaws.com/plink1-assets/plink_linux_x86_64_20210606.zip\n",
"\n",
"# 2. Unzip the archive\n",
"! unzip plink_linux_x86_64_20210606.zip\n",
"\n",
"# 5. Move it to /usr/local/bin for global access (requires sudo)\n",
"! sudo mv plink /usr/local/bin/\n",
"\n",
"# 6. Check that it's installed correctly\n",
"! plink --version"
]
},
{
"cell_type": "code",
"execution_count": null,
"id": "891ccfbd-472d-4ebc-b326-6a81e19c2e6c",
"metadata": {},
"outputs": [],
"source": [
"# VCFTools Installation\n",
"! sudo apt-get -y install vcftools"
]
},
{
"cell_type": "markdown",
"id": "3de2fc4c",
Expand Down
14 changes: 7 additions & 7 deletions notebooks/GenAI/GCP_AI_Applications.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -79,7 +79,7 @@
"metadata": {},
"source": [
"This tutorial will cost up to ~$6, pricing is based on the cost of AI Applications and Jupyter notebooks.\n",
"For this tutorial we used a n2-standard-2 instance to run the python commands and created a App [Google Cloud Pricing Calculator](https://cloud.google.com/products/calculator?hl=en)."
"For this tutorial we used a n2-standard-2 instance to run the python commands and create an App. For more detailed information on how to calculate the price of various services on GCP, please access the [Google Cloud Pricing Calculator](https://cloud.google.com/products/calculator?hl=en)."
]
},
{
Expand Down Expand Up @@ -200,7 +200,7 @@
" doc_name=i.split(r'/')[-1]\n",
" x = requests.get(i)\n",
" doc = x.text\n",
" upload_blob_from_memory(bucket, doc, {doc_name})"
" upload_blob_from_memory(bucket, doc, doc_name)"
]
},
{
Expand All @@ -220,7 +220,7 @@
"- Chatbots\n",
"- Search engine\n",
"- Recommendations bot\n",
"- Agent development\n",
"- Conversational Agents\n",
"\n",
"For this tutorial we are creating a GenAI agent to help guide our chatbot in certain situations. Start by searching up **'AI Applications'** on the console. Then once you are on the page shown below click **'CREATE APP'**."
]
Expand All @@ -238,31 +238,31 @@
"id": "e6906e34-31a0-4e88-85e9-62abee5ed6cd",
"metadata": {},
"source": [
"Click **'SELECT'** for the app named **Agent**."
"Click **'SELECT'** for the app named **Conversational Agent**."
]
},
{
"cell_type": "markdown",
"id": "39beb2ac-c377-4201-9973-5fdb738159d8",
"metadata": {},
"source": [
"![agent_builder1](../../images/agent_builder1.png)"
"![agent_builder1](../../images/agent_builder1.jepg)"
]
},
{
"cell_type": "markdown",
"id": "8d32f806-cef5-401b-be7b-b60ff2686a76",
"metadata": {},
"source": [
"Give your agent a name, select your region, then click **'CREATE'**."
"Select **Build your own**. Give your agent a name, select your region, select **Playbook** and the conversation start method, then click **'CREATE'**."
]
},
{
"cell_type": "markdown",
"id": "0b59fa7c-b082-4372-9d9d-c299565f67dd",
"metadata": {},
"source": [
"![agent_builder2](../../images/agent_builder2.png)"
"![agent_builder2](../../images/agent_builder2.jpeg)"
]
},
{
Expand Down
Loading
Loading