Browse Source

last touches on day 3

sprenger 2 years ago
parent
commit
8af8c8adcc
3 changed files with 30 additions and 14 deletions
  1. 3 2
      day_3/hands_on_1_solution.ipynb
  2. 17 0
      day_3/hands_on_2_solution.ipynb
  3. 10 12
      day_3/tutorial_1.ipynb

+ 3 - 2
day_3/hands_on_1_solution.ipynb

@@ -83,7 +83,7 @@
   },
   {
    "cell_type": "code",
-   "execution_count": 19,
+   "execution_count": 1,
    "id": "4fa3decf",
    "metadata": {},
    "outputs": [
@@ -102,6 +102,7 @@
     "import neo\n",
     "io = neo.io.BlackrockIO('l101210-001')\n",
     "block = io.read_block()\n",
+    "\n",
     "print(f'Number of segments: {len(block.segments)}')\n",
     "for anasig in block.segments[0].analogsignals:\n",
     "    print(f'Number of channels with sampling rate {anasig.sampling_rate}: {anasig.shape[-1]}')\n",
@@ -168,7 +169,7 @@
    "id": "766cb710",
    "metadata": {},
    "source": [
-    "## Exercise 3: Save the dataset using NIX\n",
+    "## Exercise 3: Saving the dataset using NIX\n",
     "- Save the complete dataset in a new file named `l101210-001.nix`\n",
     "- What is the size of the resulting nix file?\n",
     "\n",

+ 17 - 0
day_3/hands_on_2_solution.ipynb

@@ -167,6 +167,23 @@
     "        plt.axvline(event.times[ev_idx])\n",
     "        plt.text(event.times[ev_idx], -1.5, event_label, fontsize=12)"
    ]
+  },
+  {
+   "cell_type": "markdown",
+   "id": "544d74f6",
+   "metadata": {},
+   "source": [
+    "## Bonus Exercise\n",
+    "Did you bring your own data? Visualize your own data. Note that it might be useful to load the data in lazy mode to spare your memory."
+   ]
+  },
+  {
+   "cell_type": "code",
+   "execution_count": null,
+   "id": "24b21014",
+   "metadata": {},
+   "outputs": [],
+   "source": []
   }
  ],
  "metadata": {

+ 10 - 12
day_3/tutorial_1.ipynb

@@ -409,7 +409,7 @@
     }
    },
    "source": [
-    "## Relations between data objects\n",
+    "## Relations between data objects - Container Classes\n",
     "- `ChannelView`: select a subset of channels of a signal, e.g. all even channels of an `AnalogSignal`\n",
     "- **`Segment`**: contains data objects with a shared clock, e.g. a trial\n",
     "- `Group`: groups data objects logically (no common clock required, e.g. `SpikeTrain`s of a neuronal unit)\n",
@@ -834,17 +834,15 @@
    },
    "source": [
     "- selected open formats are supported for writing\n",
-    " - **NIX**[<sup>1</sup>](#fn1)\n",
-    " - NWB[<sup>1</sup>](#fn1)\n",
-    " - Matlab[<sup>2</sup>](#fn2)\n",
-    " - Ascii[<sup>2</sup>](#fn2)\n",
-    " - Numpy Pickle[<sup>3</sup>](#fn3)\n",
+    " - **NIX**<sup>1</sup>\n",
+    " - NWB<sup>1</sup>\n",
+    " - Matlab<sup>2</sup>\n",
+    " - Ascii<sup>2</sup>\n",
+    " - Numpy Pickle<sup>3</sup>\n",
     " \n",
-    "<sup>1</sup><span id=\"fn1\"> Support of neo-compatible format aspects</span>\n",
-    "\n",
-    "<sup>2</sup><span id=\"fn2\"> Does not capture complete set of metadata</span>\n",
-    "\n",
-    "<sup>3</sup><span id=\"fn3\"> Strong dependency on Numpy and Neo version</span>"
+    "1. Support of neo-compatible files\n",
+    "2. Does not capture complete set of metadata\n",
+    "3. Strong dependency on Numpy and Neo version"
    ]
   },
   {
@@ -887,7 +885,7 @@
    },
    "source": [
     "### Why two NixIOs in Neo?\n",
-    "`neo.io.NixIO`\n",
+    "**`neo.io.NixIO`**\n",
     "- non-RawIO implementation\n",
     "- can read and write arbitrary Neo object structures\n",
     "\n",