Skip to content

Commit

Permalink
Convert more notebooks to the new approach
Browse files Browse the repository at this point in the history
  • Loading branch information
mrakitin committed Jun 13, 2023
1 parent cdd033c commit 598a4c8
Show file tree
Hide file tree
Showing 3 changed files with 13 additions and 4 deletions.
2 changes: 1 addition & 1 deletion examples/material/create_material.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -4,7 +4,7 @@
"cell_type": "markdown",
"metadata": {},
"source": [
"<a href=\"https://colab.research.google.com/github/Exabyte-io/exabyte-api-examples/blob/dev/examples/material/create_material.ipynb\" target=\"_parent\">\n",
"<a href=\"https://colab.research.google.com/github/Exabyte-io/api-examples/blob/dev/examples/material/create_material.ipynb\" target=\"_parent\">\n",
"<img alt=\"Open in Google Colab\" src=\"https://user-images.githubusercontent.com/20477508/128780728-491fea90-9b23-495f-a091-11681150db37.jpeg\" width=\"150\" border=\"0\">\n",
"</a>"
]
Expand Down
13 changes: 11 additions & 2 deletions examples/material/import_materials_from_materialsproject.ipynb
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
{
"cells": [
{
"attachments": {},
"cell_type": "markdown",
"metadata": {
"id": "y_SM_JBc9vrV"
Expand All @@ -12,6 +13,7 @@
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {
"id": "amffxwKY9vrX"
Expand All @@ -23,6 +25,7 @@
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {
"id": "c-nHvPSy9vrY"
Expand Down Expand Up @@ -59,11 +62,13 @@
"ORGANIZATION_ID = \"ORGANIZATION_ID\" #@param {type:\"string\"}\n",
"import os, glob, sys, importlib, urllib.request\n",
"\n",
"# The below execution sets up runtime using code stored remotely in a url\n",
"exec(urllib.request.urlopen('https://raw.githubusercontent.com/Exabyte-io/exabyte-api-examples/dev/examples/utils/initialize_settings.py').read())"
"# The below execution sets up runtime using code stored remotely\n",
"!git clone https://github.com/Exabyte-io/api-examples && cd api-examples && git checkout dev\n",
"%run -i api-examples/examples/utils/initialize_settings.py"
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {
"id": "5wAnsWE-9vrZ"
Expand All @@ -80,6 +85,7 @@
},
"outputs": [],
"source": [
"%cd ..\n",
"from utils.generic import display_JSON\n",
"import settings; importlib.reload(settings)\n",
"from settings import ENDPOINT_ARGS, MATERIALS_PROJECT_API_KEY\n",
Expand All @@ -88,6 +94,7 @@
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {
"id": "C2Dxa1qZ9vra"
Expand All @@ -113,6 +120,7 @@
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {
"id": "11YzfvYk9vrb"
Expand All @@ -136,6 +144,7 @@
]
},
{
"attachments": {},
"cell_type": "markdown",
"metadata": {
"id": "DPMW1MDy9vrc"
Expand Down
2 changes: 1 addition & 1 deletion examples/system/get_authentication_params.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -69,7 +69,7 @@
{
"attachments": {},
"cell_type": "markdown",
"metadata": {},
"metadata": {"cellView": "form"},
"source": [
"## Set Parameters\n",
"\n",
Expand Down

0 comments on commit 598a4c8

Please sign in to comment.