|
30 | 30 | "\n", |
31 | 31 | "2. **Set up the necessary software:** Students will install and configure essential tools including:\n", |
32 | 32 | " * Java (a prerequisite for Nextflow).\n", |
33 | | - " * Mambaforge (a package manager for bioinformatics tools).\n", |
| 33 | + " * Miniforge (a package manager for bioinformatics tools).\n", |
34 | 34 | " * `sra-tools`, `perl-dbd-sqlite`, and `perl-dbi` (specific bioinformatics packages).\n", |
35 | 35 | " * Nextflow (a workflow management system).\n", |
36 | | - " * `aws s3` (for interacting with AWS S3 Storage).\n", |
| 36 | + " * `gsutil` (for interacting with Google Cloud Storage).\n", |
37 | 37 | "\n", |
38 | | - "3. **Download and organize necessary data:** Students will download the TransPi transcriptome assembly software and its associated resources (databases, scripts, configuration files) from an S3 bucket. This includes understanding the directory structure and file organization.\n", |
| 38 | + "3. **Download and organize necessary data:** Students will download the TransPi transcriptome assembly software and its associated resources (databases, scripts, configuration files) from a Google Cloud Storage bucket. This includes understanding the directory structure and file organization.\n", |
39 | 39 | "\n", |
40 | 40 | "4. **Manage file permissions:** Students will use the `chmod` command to set executable permissions for the necessary files and directories within the TransPi software.\n", |
41 | 41 | "\n", |
|
53 | 53 | "* **Shell Access:** The ability to execute shell commands from within the Jupyter Notebook environment (using `!` and `%`).\n", |
54 | 54 | "* **Java Development Kit (JDK):** Required for Nextflow.\n", |
55 | 55 | "* **Miniforge** A package manager for installing bioinformatics tools.\n", |
56 | | - "* **`aws s3`:** The AWS command-line tool. This is crucial for downloading data from an S3 storage bucket." |
| 56 | + "* **`gsutil`:** The Google Cloud Storage command-line tool. This is crucial for downloading data from Google Cloud Storage." |
57 | 57 | ] |
58 | 58 | }, |
59 | 59 | { |
|
104 | 104 | "## Time to begin!\n", |
105 | 105 | "\n", |
106 | 106 | "**Step 1:** To start, make sure that you are in the right starting place with a `cd`.\n", |
107 | | - "> `pwd` prints our current local working directory. Make sure the output from the command is: `/home/ec2-user/SageMaker`" |
| 107 | + "> `pwd` prints our current local working directory. Make sure the output from the command is: `/home/jupyter`" |
108 | 108 | ] |
109 | 109 | }, |
110 | 110 | { |
|
114 | 114 | "metadata": {}, |
115 | 115 | "outputs": [], |
116 | 116 | "source": [ |
117 | | - "%cd /home/ec2-user/SageMaker" |
| 117 | + "%cd /home/jupyter" |
118 | 118 | ] |
119 | 119 | }, |
120 | 120 | { |
|
147 | 147 | "! java -version" |
148 | 148 | ] |
149 | 149 | }, |
| 150 | + { |
| 151 | + "cell_type": "markdown", |
| 152 | + "id": "7b3ffb16-3395-4c01-9774-ee568e815490", |
| 153 | + "metadata": {}, |
| 154 | + "source": [ |
| 155 | + "**Step 3:** Install Miniforge (a package manager), which is needed to support the information held within the TransPi databases." |
| 156 | + ] |
| 157 | + }, |
| 158 | + { |
| 159 | + "cell_type": "code", |
| 160 | + "execution_count": null, |
| 161 | + "id": "ac5b204a-f0db-4ceb-bf37-57eca6d77974", |
| 162 | + "metadata": {}, |
| 163 | + "outputs": [], |
| 164 | + "source": [ |
| 165 | + "! curl -L -O https://github.com/conda-forge/miniforge/releases/latest/download/Miniforge3-$(uname)-$(uname -m).sh\n", |
| 166 | + "! bash Miniforge3-$(uname)-$(uname -m).sh -b -p $HOME/miniforge" |
| 167 | + ] |
| 168 | + }, |
| 169 | + { |
| 170 | + "cell_type": "markdown", |
| 171 | + "id": "c5584e2e", |
| 172 | + "metadata": {}, |
| 173 | + "source": [ |
| 174 | + "Next, add it to the path." |
| 175 | + ] |
| 176 | + }, |
| 177 | + { |
| 178 | + "cell_type": "code", |
| 179 | + "execution_count": null, |
| 180 | + "id": "ad030cd1", |
| 181 | + "metadata": {}, |
| 182 | + "outputs": [], |
| 183 | + "source": [ |
| 184 | + "import os\n", |
| 185 | + "os.environ[\"PATH\"] += os.pathsep + os.environ[\"HOME\"]+\"/miniforge/bin\"" |
| 186 | + ] |
| 187 | + }, |
150 | 188 | { |
151 | 189 | "cell_type": "markdown", |
152 | 190 | "id": "7b930ad7", |
153 | 191 | "metadata": {}, |
154 | 192 | "source": [ |
155 | | - "**Step 3:** Using Mamba and bioconda, install the tools that will be used in this tutorial." |
| 193 | + "Next, using Miniforge and bioconda, install the tools that will be used in this tutorial." |
156 | 194 | ] |
157 | 195 | }, |
158 | 196 | { |
|
201 | 239 | "metadata": {}, |
202 | 240 | "outputs": [], |
203 | 241 | "source": [ |
204 | | - "! aws s3 cp --recursive s3://nigms-sandbox/nosi-inbremaine-storage/TransPi ./TransPi" |
| 242 | + "! gsutil -m cp -r gs://nigms-sandbox/nosi-inbremaine-storage/TransPi ./" |
205 | 243 | ] |
206 | 244 | }, |
207 | 245 | { |
|
211 | 249 | "source": [ |
212 | 250 | "<div class=\"alert alert-block alert-success\">\n", |
213 | 251 | " <i class=\"fa fa-hand-paper-o\" aria-hidden=\"true\"></i>\n", |
214 | | - " <b>Note: </b> aws\n", |
| 252 | + " <b>Note: </b> gsutil\n", |
215 | 253 | "</div>\n", |
216 | 254 | "\n", |
217 | | - ">`aws s3` is a tool allows you to interact with S3 Storage through the command line." |
| 255 | + ">`gsutil` is a tool allows you to interact with Google Cloud Storage through the command line." |
218 | 256 | ] |
219 | 257 | }, |
220 | 258 | { |
|
239 | 277 | "metadata": {}, |
240 | 278 | "outputs": [], |
241 | 279 | "source": [ |
242 | | - "! aws s3 cp --recursive s3://nigms-sandbox/nosi-inbremaine-storage/resources ./resources" |
| 280 | + "! gsutil -m cp -r gs://nigms-sandbox/nosi-inbremaine-storage/resources ./" |
243 | 281 | ] |
244 | 282 | }, |
245 | 283 | { |
|
264 | 302 | "> - They can also be stacked so `../../` will take you two layers up.\n", |
265 | 303 | ">\n", |
266 | 304 | ">- If you were to type `!ls ./nextWeek/` it would return the contents of the `nextWeek` directory which is one layer down from the current directory, so it would return `manyThings.txt`.\n", |
267 | | - ">" |
| 305 | + ">\n", |
| 306 | + ">**This means that in the second line of the code cell above, the file `TransPi.nf` will be copied from the Google Cloud Storage bucket to the current directory.**" |
268 | 307 | ] |
269 | 308 | }, |
270 | 309 | { |
|
338 | 377 | "outputs": [], |
339 | 378 | "source": [ |
340 | 379 | "from jupyterquiz import display_quiz\n", |
341 | | - "display_quiz(\"Transcriptome-Assembly-Refinement-and-Applications/quiz-material/01-cp1.json\", shuffle_questions = True)" |
| 380 | + "display_quiz(\"../quiz-material/01-cp1.json\", shuffle_questions = True)" |
342 | 381 | ] |
343 | 382 | }, |
344 | 383 | { |
|
0 commit comments