Skip to content

Commit

Permalink
Fix broken links in notebook Colab setup.
Browse files Browse the repository at this point in the history
  • Loading branch information
ericmintun committed Apr 5, 2023
1 parent 5717941 commit b47d02d
Show file tree
Hide file tree
Showing 3 changed files with 14 additions and 14 deletions.
8 changes: 4 additions & 4 deletions notebooks/automatic_mask_generator_example.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -74,7 +74,7 @@
"id": "47e5a78f",
"metadata": {},
"source": [
"If running locally using jupyter, first install `segment_anything` in your environment using the [installation instructions](https://github.com/facebookresearch/segment-anything#installation) in the repository. If running from Google collab, set `using_collab=True` below and run the cell."
"If running locally using jupyter, first install `segment_anything` in your environment using the [installation instructions](https://github.com/facebookresearch/segment-anything#installation) in the repository. If running from Google Colab, set `using_collab=True` below and run the cell. In Colab, be sure to select 'GPU' under 'Edit'->'Notebook Settings'->'Hardware accelerator'."
]
},
{
Expand All @@ -84,7 +84,7 @@
"metadata": {},
"outputs": [],
"source": [
"using_collab = False"
"using_colab = False"
]
},
{
Expand All @@ -94,7 +94,7 @@
"metadata": {},
"outputs": [],
"source": [
"if using_collab:\n",
"if using_colab:\n",
" import torch\n",
" import torchvision\n",
" print(\"PyTorch version:\", torch.__version__)\n",
Expand All @@ -105,7 +105,7 @@
" !{sys.executable} -m pip install 'git+https://github.com/facebookresearch/segment-anything.git'\n",
" \n",
" !mkdir images\n",
" !wget -P images https://github.com/facebookresearch/segment-anything/blob/main/notebooks/images/dog.jpg\n",
" !wget -P images https://raw.githubusercontent.com/facebookresearch/segment-anything/main/notebooks/images/dog.jpg\n",
" \n",
" !wget https://dl.fbaipublicfiles.com/segment_anything/sam_vit_h_4b8939.pth"
]
Expand Down
8 changes: 4 additions & 4 deletions notebooks/onnx_model_example.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -72,7 +72,7 @@
"id": "109a5cc2",
"metadata": {},
"source": [
"If running locally using jupyter, first install `segment_anything` in your environment using the [installation instructions](https://github.com/facebookresearch/segment-anything#installation) in the repository. The latest stable versions of PyTorch and ONNX are recommended for this notebook. If running from Google collab, set `using_collab=True` below and run the cell."
"If running locally using jupyter, first install `segment_anything` in your environment using the [installation instructions](https://github.com/facebookresearch/segment-anything#installation) in the repository. The latest stable versions of PyTorch and ONNX are recommended for this notebook. If running from Google Colab, set `using_collab=True` below and run the cell. In Colab, be sure to select 'GPU' under 'Edit'->'Notebook Settings'->'Hardware accelerator'."
]
},
{
Expand All @@ -82,7 +82,7 @@
"metadata": {},
"outputs": [],
"source": [
"using_collab = False"
"using_colab = False"
]
},
{
Expand All @@ -92,7 +92,7 @@
"metadata": {},
"outputs": [],
"source": [
"if using_collab:\n",
"if using_colab:\n",
" import torch\n",
" import torchvision\n",
" print(\"PyTorch version:\", torch.__version__)\n",
Expand All @@ -103,7 +103,7 @@
" !{sys.executable} -m pip install 'git+https://github.com/facebookresearch/segment-anything.git'\n",
" \n",
" !mkdir images\n",
" !wget -P images https://github.com/facebookresearch/segment-anything/blob/main/notebooks/images/truck.jpg\n",
" !wget -P images https://raw.githubusercontent.com/facebookresearch/segment-anything/main/notebooks/images/truck.jpg\n",
" \n",
" !wget https://dl.fbaipublicfiles.com/segment_anything/sam_vit_h_4b8939.pth"
]
Expand Down
12 changes: 6 additions & 6 deletions notebooks/predictor_example.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -74,17 +74,17 @@
"id": "07fabfee",
"metadata": {},
"source": [
"If running locally using jupyter, first install `segment_anything` in your environment using the [installation instructions](https://github.com/facebookresearch/segment-anything#installation) in the repository. If running from Google collab, set `using_collab=True` below and run the cell."
"If running locally using jupyter, first install `segment_anything` in your environment using the [installation instructions](https://github.com/facebookresearch/segment-anything#installation) in the repository. If running from Google Colab, set `using_collab=True` below and run the cell. In Colab, be sure to select 'GPU' under 'Edit'->'Notebook Settings'->'Hardware accelerator'."
]
},
{
"cell_type": "code",
"execution_count": 3,
"execution_count": 1,
"id": "5ea65efc",
"metadata": {},
"outputs": [],
"source": [
"using_collab = False"
"using_colab = False"
]
},
{
Expand All @@ -94,7 +94,7 @@
"metadata": {},
"outputs": [],
"source": [
"if using_collab:\n",
"if using_colab:\n",
" import torch\n",
" import torchvision\n",
" print(\"PyTorch version:\", torch.__version__)\n",
Expand All @@ -105,8 +105,8 @@
" !{sys.executable} -m pip install 'git+https://github.com/facebookresearch/segment-anything.git'\n",
" \n",
" !mkdir images\n",
" !wget -P images https://github.com/facebookresearch/segment-anything/blob/main/notebooks/images/truck.jpg\n",
" !wget -P images https://github.com/facebookresearch/segment-anything/blob/main/notebooks/images/groceries.jpg\n",
" !wget -P images https://raw.githubusercontent.com/facebookresearch/segment-anything/main/notebooks/images/truck.jpg\n",
" !wget -P images https://raw.githubusercontent.com/facebookresearch/segment-anything/main/notebooks/images/groceries.jpg\n",
" \n",
" !wget https://dl.fbaipublicfiles.com/segment_anything/sam_vit_h_4b8939.pth"
]
Expand Down

0 comments on commit b47d02d

Please sign in to comment.