|
38 | 38 | "collapsed": false |
39 | 39 | }, |
40 | 40 | "outputs": [], |
41 | | - "source": [] |
| 41 | + "source": [ |
| 42 | + "#" |
| 43 | + ] |
42 | 44 | }, |
43 | 45 | { |
44 | 46 | "cell_type": "markdown", |
|
58 | 60 | "cell_type": "markdown", |
59 | 61 | "metadata": {}, |
60 | 62 | "source": [ |
61 | | - "## Mount data with Google Drive\n", |
62 | | - "\n", |
63 | | - "First, open the following Google Drive link:\n", |
64 | | - "https://drive.google.com/drive/folders/1NuxO5_GHgDvjrL2FX5ohzAsvWpZuepIA\n", |
65 | | - "\n", |
66 | | - "Then, click on the directory name (\"vim-5\"), and add a shortcut to your Drive\n", |
67 | | - "(\"Add shortcut to Drive\"). Place the shortcut in the main directory of your\n", |
68 | | - "Google Drive. Do not place it in another folder, or you will have to change \n", |
69 | | - "the code to update the location of the dataset.\n", |
| 63 | + "## Download the data and install all required dependencies\n", |
70 | 64 | "\n", |
71 | | - "Finally, mount Google Drive in Google Colab. To do so, run the following cell,\n", |
72 | | - "and follow the instructions from Google to copy/paste the authorization code.\n", |
| 65 | + "Uncomment and run the following cell to download the tutorial data and\n", |
| 66 | + "install the required dependencies\n", |
73 | 67 | "\n" |
74 | 68 | ] |
75 | 69 | }, |
|
81 | 75 | }, |
82 | 76 | "outputs": [], |
83 | 77 | "source": [ |
84 | | - "from google.colab import drive\n", |
85 | | - "drive.mount(\"/content/drive\")" |
| 78 | + "# !gdown --id 1b0I0Ytj06m6GCmfxfNrZuyF97fDo3NZb && \\\n", |
| 79 | + "# tar xzf vim-5-for-ccn.tar.gz && \\\n", |
| 80 | + "# pip install -q voxelwise_tutorials && \\\n", |
| 81 | + "# git clone https://github.com/gallantlab/pycortex" |
86 | 82 | ] |
87 | 83 | }, |
88 | 84 | { |
89 | 85 | "cell_type": "markdown", |
90 | 86 | "metadata": {}, |
91 | 87 | "source": [ |
92 | | - "Uncomment and run the following command to check that Google Drive was\n", |
93 | | - "correctly mounted.\n", |
94 | | - "\n" |
95 | | - ] |
96 | | - }, |
97 | | - { |
98 | | - "cell_type": "code", |
99 | | - "execution_count": null, |
100 | | - "metadata": { |
101 | | - "collapsed": false |
102 | | - }, |
103 | | - "outputs": [], |
104 | | - "source": [ |
105 | | - "# !ls drive/MyDrive/vim-5" |
106 | | - ] |
107 | | - }, |
108 | | - { |
109 | | - "cell_type": "markdown", |
110 | | - "metadata": {}, |
111 | | - "source": [ |
112 | | - "Tell the voxelwise_tutorials package where the data is. (If you placed the\n", |
113 | | - "shortcut in a different location than the main directory of your Google\n", |
114 | | - "Drive, change this code to point to the correct location.)\n", |
| 88 | + "Now run the following cell to set up the environment variables for the tutorials\n", |
| 89 | + "and pycortex.\n", |
115 | 90 | "\n" |
116 | 91 | ] |
117 | 92 | }, |
|
124 | 99 | "outputs": [], |
125 | 100 | "source": [ |
126 | 101 | "import os\n", |
127 | | - "os.environ['VOXELWISE_TUTORIALS_DATA'] = \"drive/MyDrive/\"" |
128 | | - ] |
129 | | - }, |
130 | | - { |
131 | | - "cell_type": "markdown", |
132 | | - "metadata": {}, |
133 | | - "source": [ |
134 | | - "## Install package helper\n", |
| 102 | + "os.environ['VOXELWISE_TUTORIALS_DATA'] = \"/content\"\n", |
135 | 103 | "\n", |
136 | | - "Finally, install the tutorial helper package, by uncommenting and running\n", |
137 | | - "the install command.\n", |
138 | | - "\n" |
139 | | - ] |
140 | | - }, |
141 | | - { |
142 | | - "cell_type": "code", |
143 | | - "execution_count": null, |
144 | | - "metadata": { |
145 | | - "collapsed": false |
146 | | - }, |
147 | | - "outputs": [], |
148 | | - "source": [ |
149 | | - "# !pip install voxelwise_tutorials" |
150 | | - ] |
151 | | - }, |
152 | | - { |
153 | | - "cell_type": "markdown", |
154 | | - "metadata": {}, |
155 | | - "source": [ |
156 | | - "When using Colab, the install of pycortex might fail to locate the default\n", |
157 | | - "pycortex filestore. Uncomment and run the following line to fix it:\n", |
158 | | - "\n" |
159 | | - ] |
160 | | - }, |
161 | | - { |
162 | | - "cell_type": "code", |
163 | | - "execution_count": null, |
164 | | - "metadata": { |
165 | | - "collapsed": false |
166 | | - }, |
167 | | - "outputs": [], |
168 | | - "source": [ |
169 | | - "# !git clone https://github.com/gallantlab/pycortex" |
170 | | - ] |
171 | | - }, |
172 | | - { |
173 | | - "cell_type": "markdown", |
174 | | - "metadata": {}, |
175 | | - "source": [ |
176 | | - "Now change the pycortex filestore path.\n", |
177 | | - "\n" |
178 | | - ] |
179 | | - }, |
180 | | - { |
181 | | - "cell_type": "code", |
182 | | - "execution_count": null, |
183 | | - "metadata": { |
184 | | - "collapsed": false |
185 | | - }, |
186 | | - "outputs": [], |
187 | | - "source": [ |
188 | 104 | "import cortex\n", |
189 | 105 | "filestore = \"/content/pycortex/filestore/\"\n", |
190 | 106 | "cortex.options.config['basic']['filestore'] = filestore\n", |
|
3520 | 3436 | "name": "python", |
3521 | 3437 | "nbconvert_exporter": "python", |
3522 | 3438 | "pygments_lexer": "ipython3", |
3523 | | - "version": "3.8.3" |
| 3439 | + "version": "3.7.3" |
3524 | 3440 | }, |
3525 | 3441 | "name": "_merged" |
3526 | 3442 | }, |
|
0 commit comments