Skip to content

Commit

Permalink
Update course book
Browse files Browse the repository at this point in the history
  • Loading branch information
actions-user committed Dec 5, 2023
1 parent 46c6761 commit 5b15ece
Show file tree
Hide file tree
Showing 351 changed files with 3,095 additions and 3,116 deletions.
2 changes: 1 addition & 1 deletion .buildinfo
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: a191cef158ca8665d684bbe58bbd4944
config: 1d4a1935b67cccc1c42ac01a9e6bf7f4
tags: 645f666f9bcd5a90fca523b33c5a78b7
Binary file added _images/Bonus_Tutorial1_28_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified _images/Bonus_Tutorial1_28_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed _images/Bonus_Tutorial1_28_2.png
Binary file not shown.
Binary file modified _images/Bonus_Tutorial1_53_11.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added _images/Bonus_Tutorial1_54_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified _images/Bonus_Tutorial1_54_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed _images/Bonus_Tutorial1_54_2.png
Binary file not shown.
Binary file modified _images/Bonus_Tutorial1_56_4.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added _images/Bonus_Tutorial1_57_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified _images/Bonus_Tutorial1_57_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed _images/Bonus_Tutorial1_57_2.png
Binary file not shown.
Binary file modified _images/Bonus_Tutorial1_58_4.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added _images/Bonus_Tutorial1_59_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified _images/Bonus_Tutorial1_59_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed _images/Bonus_Tutorial1_59_2.png
Binary file not shown.
Binary file modified _images/Bonus_Tutorial1_65_11.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified _images/Bonus_Tutorial1_66_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified _images/Bonus_Tutorial1_76_11.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified _images/Bonus_Tutorial1_77_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added _images/Bonus_Tutorial1_77_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified _images/Bonus_Tutorial1_77_2.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file removed _images/Bonus_Tutorial1_77_3.png
Binary file not shown.
Binary file modified _images/Bonus_Tutorial1_78_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified _images/Bonus_Tutorial1_84_0.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file added _images/Bonus_Tutorial1_84_1.png
Loading
Sorry, something went wrong. Reload?
Sorry, we cannot display this file.
Sorry, this file is invalid so it cannot be displayed.
Binary file modified _images/Bonus_Tutorial1_84_2.png
Binary file removed _images/Bonus_Tutorial1_84_3.png
Diff not rendered.
Binary file modified _images/Bonus_Tutorial1_85_0.png
Binary file modified _images/Bonus_Tutorial1_87_11.png
Binary file modified _images/Bonus_Tutorial1_88_0.png
Binary file modified _images/Bonus_Tutorial1_89_0.png
Binary file modified _images/Bonus_Tutorial1_91_1.png
Binary file added _images/Bonus_Tutorial1_93_0.png
Binary file modified _images/Bonus_Tutorial1_93_1.png
Binary file removed _images/Bonus_Tutorial1_93_2.png
Diff not rendered.
Binary file modified _images/Bonus_Tutorial2_35_11.png
Binary file modified _images/Bonus_Tutorial2_47_11.png
Binary file modified _images/Bonus_Tutorial2_50_0.png
Binary file modified _images/Bonus_Tutorial2_50_1.png
Binary file modified _images/Bonus_Tutorial2_50_2.png
Binary file modified _images/Bonus_Tutorial3_22_0.png
Binary file modified _images/Bonus_Tutorial3_22_1.png
Binary file modified _images/Bonus_Tutorial3_22_2.png
Binary file modified _images/Bonus_Tutorial3_28_0.png
Binary file modified _images/Bonus_Tutorial3_28_1.png
Binary file modified _images/Bonus_Tutorial3_28_2.png
Binary file modified _images/Bonus_Tutorial3_30_0.png
Binary file modified _images/Bonus_Tutorial3_32_4.png
Binary file modified _images/Bonus_Tutorial3_33_0.png
Binary file modified _images/Bonus_Tutorial3_33_1.png
Binary file modified _images/Bonus_Tutorial3_33_2.png
Binary file modified _images/Bonus_Tutorial3_33_3.png
Binary file modified _images/Bonus_Tutorial3_35_0.png
Binary file modified _images/Bonus_Tutorial3_40_0.png
Binary file modified _images/Bonus_Tutorial3_40_1.png
Binary file modified _images/Bonus_Tutorial3_40_2.png
Binary file modified _images/Bonus_Tutorial3_40_3.png
Binary file modified _images/Bonus_Tutorial3_42_4.png
Binary file modified _images/Bonus_Tutorial3_43_0.png
Binary file modified _images/Bonus_Tutorial3_43_1.png
Binary file modified _images/Bonus_Tutorial3_43_2.png
Binary file modified _images/Bonus_Tutorial3_43_3.png
Binary file modified _images/Bonus_Tutorial3_44_0.png
Binary file modified _images/Bonus_Tutorial3_49_0.png
Binary file modified _images/Bonus_Tutorial3_49_1.png
Binary file modified _images/Bonus_Tutorial3_49_2.png
Binary file modified _images/Bonus_Tutorial3_49_3.png
Binary file modified _images/Bonus_Tutorial3_51_6.png
Binary file modified _images/Bonus_Tutorial3_52_0.png
Binary file modified _images/Bonus_Tutorial3_52_1.png
Binary file modified _images/Bonus_Tutorial3_52_2.png
Binary file modified _images/Bonus_Tutorial3_52_3.png
Binary file modified _images/Bonus_Tutorial3_53_0.png
Binary file modified _images/Bonus_Tutorial3_57_4.png
Binary file modified _images/Bonus_Tutorial3_58_0.png
Binary file modified _images/Bonus_Tutorial3_58_1.png
Binary file modified _images/Bonus_Tutorial3_58_2.png
Binary file modified _images/Bonus_Tutorial3_64_4.png
Binary file modified _images/Bonus_Tutorial3_65_0.png
Binary file modified _images/Bonus_Tutorial3_65_1.png
Binary file modified _images/Bonus_Tutorial3_65_2.png
Binary file modified _images/Bonus_Tutorial3_65_3.png
Binary file modified _images/Bonus_Tutorial3_65_4.png
Binary file modified _images/Bonus_Tutorial3_69_0.png
Binary file modified _images/Bonus_Tutorial3_69_1.png
Binary file modified _images/Bonus_Tutorial3_70_0.png
Binary file modified _images/Bonus_Tutorial3_70_1.png
Binary file modified _images/Bonus_Tutorial3_72_4.png
Binary file modified _images/Bonus_Tutorial3_74_0.png
Binary file modified _images/Bonus_Tutorial3_74_1.png
Binary file modified _images/Bonus_Tutorial3_74_2.png
Binary file modified _images/Bonus_Tutorial3_74_3.png
Binary file modified _images/TrainIllusionDataProject_18_0.png
Binary file modified _images/TrainIllusionDataProject_20_0.png
Binary file modified _images/TrainIllusionDataProject_20_1.png
Binary file modified _images/TrainIllusionDataProject_20_2.png
Binary file modified _images/TrainIllusionDataProject_32_0.png
Binary file modified _images/TrainIllusionDataProject_34_0.png
Binary file modified _images/TrainIllusionDataProject_40_0.png
Binary file modified _images/TrainIllusionModel_14_1.png
Binary file modified _images/TrainIllusionModel_18_1.png
Binary file modified _images/TrainIllusionModel_31_0.png
Binary file modified _images/TrainIllusionModel_37_0.png
Binary file modified _images/W0D3_Tutorial1_63_0.png
Binary file modified _images/W0D3_Tutorial2_49_0.png
Binary file modified _images/W0D3_Tutorial2_49_1.png
Binary file modified _images/W0D3_Tutorial2_62_0.png
Binary file modified _images/W0D3_Tutorial2_65_0.png
Binary file modified _images/W0D4_Tutorial1_107_1.png
Binary file modified _images/W0D4_Tutorial1_113_0.png
Binary file modified _images/W0D4_Tutorial1_118_0.png
Binary file modified _images/W0D4_Tutorial2_26_0.png
Binary file modified _images/W0D4_Tutorial2_35_0.png
Binary file modified _images/W0D4_Tutorial2_53_0.png
Binary file modified _images/W0D4_Tutorial2_74_0.png
Binary file modified _images/W0D4_Tutorial2_83_0.png
Binary file modified _images/W0D4_Tutorial2_92_0.png
Binary file modified _images/W0D4_Tutorial3_38_0.png
Binary file modified _images/W0D4_Tutorial3_87_0.png
Binary file modified _images/W0D4_Tutorial3_93_0.png
Binary file modified _images/W0D5_Tutorial1_56_0.png
Binary file modified _images/W0D5_Tutorial2_59_0.png
Binary file modified _images/W0D5_Tutorial2_99_1.png
Binary file modified _images/W0D5_Tutorial2_99_2.png
Binary file modified _images/W1D1_Tutorial1_43_0.png
Binary file modified _images/W1D1_Tutorial1_47_0.png
Binary file modified _images/W1D1_Tutorial1_65_0.png
Binary file modified _images/W1D1_Tutorial1_67_0.png
Binary file modified _images/W1D1_Tutorial1_69_0.png
Binary file modified _images/W1D1_Tutorial3_22_0.png
Binary file modified _images/W1D1_Tutorial3_32_0.png
Binary file modified _images/W1D1_Tutorial3_35_0.png
Binary file modified _images/W1D1_Tutorial3_42_0.png
Binary file modified _images/W1D1_Tutorial3_52_0.png
Binary file modified _images/W1D2_Tutorial1_22_0.png
Binary file modified _images/W1D2_Tutorial1_32_0.png
Binary file modified _images/W1D2_Tutorial2_32_0.png
Binary file modified _images/W1D2_Tutorial2_42_1.png
Binary file modified _images/W1D2_Tutorial2_47_1.png
Binary file modified _images/W1D2_Tutorial3_21_0.png
Binary file modified _images/W1D2_Tutorial3_38_1.png
Binary file modified _images/W1D2_Tutorial4_20_0.png
Binary file modified _images/W1D2_Tutorial4_35_0.png
Binary file modified _images/W1D2_Tutorial5_22_0.png
Binary file modified _images/W1D3_Tutorial1_23_0.png
Binary file modified _images/W1D3_Tutorial1_50_0.png
Binary file modified _images/W1D3_Tutorial1_52_0.png
Binary file modified _images/W1D3_Tutorial2_22_1.png
Binary file modified _images/W1D3_Tutorial2_53_0.png
Binary file modified _images/W1D3_Tutorial2_64_0.png
Binary file modified _images/W1D3_Tutorial2_67_0.png
Binary file modified _images/W1D3_Tutorial2_69_0.png
Binary file modified _images/W1D3_Tutorial2_75_0.png
Binary file modified _images/W1D3_Tutorial2_79_0.png
Binary file modified _images/W1D4_Tutorial3_21_0.png
Binary file modified _images/W1D5_Tutorial1_25_0.png
Binary file modified _images/W1D5_Tutorial2_33_0.png
Binary file modified _images/W1D5_Tutorial2_38_0.png
Binary file modified _images/W1D5_Tutorial3_24_0.png
Binary file modified _images/W1D5_Tutorial3_59_0.png
Binary file modified _images/W1D5_Tutorial3_62_0.png
Binary file modified _images/W1D5_Tutorial4_21_0.png
Binary file modified _images/W1D5_Tutorial4_28_1.png
Binary file modified _images/W1D5_Tutorial4_30_0.png
Binary file modified _images/W1D5_Tutorial4_44_0.png
Binary file modified _images/W1D5_Tutorial4_49_0.png
Binary file modified _images/W1D5_Tutorial4_91_1.png
Binary file modified _images/W2D2_Tutorial1_68_0.png
Binary file modified _images/W2D2_Tutorial2_21_0.png
Binary file modified _images/W2D2_Tutorial2_29_0.png
Binary file modified _images/W2D2_Tutorial2_32_0.png
Binary file modified _images/W2D2_Tutorial3_21_0.png
Binary file modified _images/W2D2_Tutorial3_50_0.png
Binary file modified _images/W2D2_Tutorial3_52_0.png
Binary file modified _images/W2D2_Tutorial4_22_1.png
Binary file modified _images/W2D2_Tutorial4_25_0.png
Binary file modified _images/W2D2_Tutorial4_28_0.png
Binary file modified _images/W2D2_Tutorial4_43_0.png
Binary file modified _images/W2D2_Tutorial4_52_0.png
Binary file modified _images/W2D2_Tutorial4_65_0.png
Binary file modified _images/W2D3_Tutorial2_34_0.png
Binary file modified _images/W2D3_Tutorial3_54_0.png
Binary file modified _images/W2D3_Tutorial3_62_0.png
Binary file modified _images/W2D3_Tutorial4_40_1.png
Binary file modified _images/W2D4_Tutorial1_112_0.png
Binary file modified _images/W2D4_Tutorial1_123_0.png
Binary file modified _images/W2D4_Tutorial2_59_1.png
Binary file modified _images/W2D4_Tutorial3_22_0.png
Binary file modified _images/W2D4_Tutorial3_48_0.png
Binary file modified _images/W2D4_Tutorial3_51_0.png
Binary file modified _images/W2D4_Tutorial3_54_1.png
Binary file modified _images/W2D4_Tutorial3_77_0.png
Binary file modified _images/W2D4_Tutorial3_80_0.png
Binary file modified _images/W3D1_Tutorial3_85_0.png
Binary file modified _images/W3D2_Tutorial4_80_0.png
Binary file modified _images/W3D2_Tutorial5_30_0.png
Binary file modified _images/W3D2_Tutorial5_63_0.png
Binary file modified _images/W3D4_Tutorial2_47_1.png
Binary file modified _images/W3D4_Tutorial3_32_0.png
Binary file modified _images/W3D5_Tutorial1_35_0.png
Binary file modified _images/W3D5_Tutorial1_51_1.png
Binary file modified _images/W3D5_Tutorial1_69_0.png
Binary file modified _images/W3D5_Tutorial2_30_0.png
Binary file modified _images/W3D5_Tutorial2_42_0.png
Binary file modified _images/W3D5_Tutorial2_53_6.png
Binary file modified _images/W3D5_Tutorial3_46_0.png
1 change: 1 addition & 0 deletions _sources/tutorials/Schedule/daily_schedules.md
Original file line number Diff line number Diff line change
@@ -1,4 +1,5 @@
# General schedule
# Pilot Test

## Course overview

Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"\n",
"**Content reviewers**: Lina Teichmann, Saeed Salehi, Patrick Mineault, Ella Batty, Michael Waskom\n",
"\n",
"**Production editors:** Spiros Chavlis"
"**Production editors:** Spiros Chavlis\n"
]
},
{
Expand Down Expand Up @@ -774,7 +774,7 @@
"*Estimated timing of tutorial: 23 minutes*\n",
"\n",
"- Bootstrapping is a resampling procedure that allows to build confidence intervals around inferred parameter values\n",
"- it is a widely applicable and very practical method that relies on computational power and pseudo-random number generators (as opposed to more classical approaches than depend on analytical derivations)"
"- it is a widely applicable and very practical method that relies on computational power and pseudo-random number generators (as opposed to more classical approaches that depend on analytical derivations)"
]
},
{
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -247,7 +247,7 @@
" best_C = C_values[np.argmax(accuracies)]\n",
" ax.set(\n",
" xticks=C_values,\n",
" xlabel=\"$C$\",\n",
" xlabel=\"C\",\n",
" ylabel=\"Cross-validated accuracy\",\n",
" title=f\"Best C: {best_C:1g} ({np.max(accuracies):.2%})\",\n",
" )\n",
Expand All @@ -261,7 +261,7 @@
" ax.plot(C_values, non_zero_l1, marker=\"o\")\n",
" ax.set(\n",
" xticks=C_values,\n",
" xlabel=\"$C$\",\n",
" xlabel=\"C\",\n",
" ylabel=\"Number of non-zero coefficients\",\n",
" )\n",
" ax.axhline(n_voxels, color=\".1\", linestyle=\":\")\n",
Expand Down Expand Up @@ -725,7 +725,7 @@
"\n",
"*Estimated timing to here from start of tutorial: 30 min*\n",
"\n",
"Now we need to evaluate the model's predictions. We'll do that with an *accuracy* score. The accuracy of the classifier is the proportion of trials where the predicted label matches the true label.\n"
"Now, we need to evaluate the predictions of the model. We will use an *accuracy* score for this purpose. The accuracy of a classifier is determined by the proportion of correct trials, where the predicted label matches the true label, out of the total number of trials."
]
},
{
Expand Down Expand Up @@ -794,7 +794,7 @@
"execution": {}
},
"source": [
"[*Click for solution*](https://github.com/NeuromatchAcademy/course-content/tree/main/tutorials/W1D3_GeneralizedLinearModels/solutions/W1D3_Tutorial2_Solution_bfe654b0.py)\n",
"[*Click for solution*](https://github.com/NeuromatchAcademy/course-content/tree/main/tutorials/W1D3_GeneralizedLinearModels/solutions/W1D3_Tutorial2_Solution_1485808c.py)\n",
"\n"
]
},
Expand Down Expand Up @@ -933,7 +933,7 @@
},
"outputs": [],
"source": [
"X.shape"
"print(X.shape)"
]
},
{
Expand Down Expand Up @@ -1211,10 +1211,10 @@
" penalized_models[log_C] = m.fit(X, y)\n",
"\n",
"@widgets.interact\n",
"def plot_observed(log_C = widgets.FloatSlider(value=1, min=1, max=10, step=1)):\n",
"def plot_observed(log_C = widgets.IntSlider(value=1, min=1, max=10, step=1)):\n",
" models = {\n",
" \"No regularization\": log_reg,\n",
" f\"$L_2$ (C = $10^{log_C}$)\": penalized_models[log_C]\n",
" f\"$L_2$ (C = $10^{{{log_C}}}$)\": penalized_models[log_C]\n",
" }\n",
" plot_weights(models)"
]
Expand All @@ -1225,7 +1225,7 @@
"execution": {}
},
"source": [
"Recall from above that $C=\\frac1\\beta$ so larger `C` is less regularization. The top panel corresponds to $C=\\infty$."
"Recall from above that $C=\\frac1\\beta$ so larger $C$ is less regularization. The top panel corresponds to $C \\rightarrow \\infty$."
]
},
{
Expand Down Expand Up @@ -1453,7 +1453,7 @@
"execution": {}
},
"source": [
"Smaller `C` (bigger $\\beta$) leads to sparser solutions.\n",
"Smaller $C$ (bigger $\\beta$) leads to sparser solutions.\n",
"\n",
"**Link to neuroscience**: When is it OK to assume that the parameter vector is sparse? Whenever it is true that most features don't affect the outcome. One use-case might be decoding low-level visual features from whole-brain fMRI: we may expect only voxels in V1 and thalamus should be used in the prediction.\n",
"\n",
Expand Down Expand Up @@ -1647,7 +1647,7 @@
"\n",
"**The logistic link function**\n",
"\n",
"You've seen $\\theta^T x_i$ before, but the $\\sigma$ is new. It's the *sigmoidal* or *logistic* link function that \"squashes\" $\\theta^T x_i$ to keep it between $0$ and $1$:\n",
"You've seen $\\theta^T x_i$ before, but the $\\sigma$ is new. It's the *sigmoidal* or *logistic* link function that \"squashes\" $\\theta^\\top x_i$ to keep it between $0$ and $1$:\n",
"\n",
"\\begin{equation}\n",
"\\sigma(z) = \\frac{1}{1 + \\textrm{exp}(-z)}\n",
Expand Down Expand Up @@ -1753,7 +1753,7 @@
"name": "python",
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.9.17"
"version": "3.9.18"
}
},
"nbformat": 4,
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -27,7 +27,7 @@
"\n",
"**Content reviewers:** Roozbeh Farhoudi, Matt Krause, Spiros Chavlis, Richard Gao, Michael Waskom, Siddharth Suresh, Natalie Schaworonkow, Ella Batty\n",
"\n",
"**Production editors:** Spiros Chavlis"
"**Production editors:** Gagana B, Spiros Chavlis"
]
},
{
Expand Down Expand Up @@ -971,7 +971,7 @@
" # Normalize vector u\n",
" u = ...\n",
"\n",
" # Calculate vector w that is orthogonal to w\n",
" # Calculate vector w that is orthogonal to u\n",
" w = ...\n",
"\n",
" # Put in matrix form\n",
Expand Down Expand Up @@ -1007,11 +1007,11 @@
"execution": {}
},
"source": [
"[*Click for solution*](https://github.com/NeuromatchAcademy/course-content/tree/main/tutorials/W1D4_DimensionalityReduction/solutions/W1D4_Tutorial1_Solution_25e1d102.py)\n",
"[*Click for solution*](https://github.com/NeuromatchAcademy/course-content/tree/main/tutorials/W1D4_DimensionalityReduction/solutions/W1D4_Tutorial1_Solution_590fa120.py)\n",
"\n",
"*Example output:*\n",
"\n",
"<img alt='Solution hint' align='left' width=379.0 height=378.0 src=https://raw.githubusercontent.com/NeuromatchAcademy/course-content/main/tutorials/W1D4_DimensionalityReduction/static/W1D4_Tutorial1_Solution_25e1d102_0.png>\n",
"<img alt='Solution hint' align='left' width=379.0 height=378.0 src=https://raw.githubusercontent.com/NeuromatchAcademy/course-content/main/tutorials/W1D4_DimensionalityReduction/static/W1D4_Tutorial1_Solution_590fa120_0.png>\n",
"\n"
]
},
Expand Down
20 changes: 10 additions & 10 deletions _sources/tutorials/W2D2_LinearSystems/student/W2D2_Tutorial2.ipynb
Original file line number Diff line number Diff line change
Expand Up @@ -216,8 +216,8 @@
"\n",
"def plot_state_probabilities(time, states):\n",
" plt.figure()\n",
" plt.plot(time, states[:, 0], label='Closed to open')\n",
" plt.plot(time, states[:, 1], label='Open to closed')\n",
" plt.plot(time, states[:, 0], label='Closed')\n",
" plt.plot(time, states[:, 1], label='Open')\n",
" plt.xlabel('time')\n",
" plt.ylabel('prob(open OR closed)')\n",
" plt.legend()\n",
Expand Down Expand Up @@ -853,12 +853,12 @@
"dt = 0.1 # timestep of our simulation\n",
"\n",
"# same parameters as above\n",
"# c2o: closed to open rate\n",
"# o2c: open to closed rate\n",
"c2o = 0.02\n",
"o2c = 0.1\n",
"A = np.array([[1 - c2o*dt, o2c*dt],\n",
" [c2o*dt, 1 - o2c*dt]])\n",
"# c: closed rate\n",
"# o: open rate\n",
"c = 0.02\n",
"o = 0.1\n",
"A = np.array([[1 - c*dt, o*dt],\n",
" [c*dt, 1 - o*dt]])\n",
"\n",
"# Initial condition: start as Closed\n",
"x0 = np.array([[1, 0]])\n",
Expand All @@ -877,11 +877,11 @@
"execution": {}
},
"source": [
"[*Click for solution*](https://github.com/NeuromatchAcademy/course-content/tree/main/tutorials/W2D2_LinearSystems/solutions/W2D2_Tutorial2_Solution_67f681fa.py)\n",
"[*Click for solution*](https://github.com/NeuromatchAcademy/course-content/tree/main/tutorials/W2D2_LinearSystems/solutions/W2D2_Tutorial2_Solution_41ec6e01.py)\n",
"\n",
"*Example output:*\n",
"\n",
"<img alt='Solution hint' align='left' width=778.0 height=577.0 src=https://raw.githubusercontent.com/NeuromatchAcademy/course-content/main/tutorials/W2D2_LinearSystems/static/W2D2_Tutorial2_Solution_67f681fa_0.png>\n",
"<img alt='Solution hint' align='left' width=778.0 height=577.0 src=https://raw.githubusercontent.com/NeuromatchAcademy/course-content/main/tutorials/W2D2_LinearSystems/static/W2D2_Tutorial2_Solution_41ec6e01_0.png>\n",
"\n"
]
},
Expand Down
Loading

0 comments on commit 5b15ece

Please sign in to comment.