Skip to content

Commit

Permalink
models/MontagueDayanSejnowski: Use versioned seaborn style
Browse files Browse the repository at this point in the history
Plain names are deprecated in matplotlib.
The versioned name with underscore was introduced in matplotlib==3.7.0,
6608eedfc6f33f723f1e13c6025a5b918c7c9f6d
	("Re-rename builtin seaborn styles to not include a dot.")

Signed-off-by: Jan Vesely <[email protected]>
  • Loading branch information
jvesely committed Jan 25, 2024
1 parent 26f6b64 commit 28383f8
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
6 changes: 3 additions & 3 deletions psyneulink/library/models/MontagueDayanSejnowski96.py
Original file line number Diff line number Diff line change
Expand Up @@ -113,7 +113,7 @@ def figure_5a():
delta_vals = prediction_error_mechanism.log.nparray_dictionary()[composition_name][pnl.VALUE]

# Plot Delta Values form trials 1, 30, and 50
with plt.style.context('seaborn'):
with plt.style.context('seaborn-v0_8'):
plt.plot(delta_vals[0][0], "-o", label="Trial 1")
plt.plot(delta_vals[29][0], "-s", label="Trial 30")
plt.plot(delta_vals[49][0], "-o", label="Trial 50")
Expand Down Expand Up @@ -176,7 +176,7 @@ def figure_5b():
# Get Delta Values from Log
delta_vals = prediction_error_mechanism.log.nparray_dictionary()[composition_name][pnl.VALUE]

with plt.style.context('seaborn'):
with plt.style.context('seaborn-v0_8'):
fig = plt.figure()
ax = fig.add_subplot(111, projection='3d')
x_vals, y_vals = np.meshgrid(np.arange(120), np.arange(40, 60, step=1))
Expand Down Expand Up @@ -240,7 +240,7 @@ def figure_5c():
# Get Delta Values from Log
delta_vals = prediction_error_mechanism.log.nparray_dictionary()[composition_name][pnl.VALUE]

with plt.style.context('seaborn'):
with plt.style.context('seaborn-v0_8'):
fig = plt.figure()
ax = fig.add_subplot(111, projection='3d')
x_vals, y_vals = np.meshgrid(np.arange(150), np.arange(40, 60, step=1))
Expand Down
2 changes: 1 addition & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@ graphviz<0.21.0
grpcio<1.61.0
leabra-psyneulink<0.3.3
llvmlite<0.42
matplotlib<3.7.3
matplotlib<3.7.3, >=3.7.0
modeci_mdf<0.5, >=0.4.3; (platform_machine == 'AMD64' or platform_machine == 'x86_64' or platform_machine == 'arm64' or platform_machine == 'aarch64') and platform_python_implementation == 'CPython' and implementation_name == 'cpython'
networkx<3.3
numpy>=1.21.0, <1.24.5
Expand Down

0 comments on commit 28383f8

Please sign in to comment.