Skip to content

Commit ad56bd8

Browse files
committed
added plotting viewed compartments
1 parent cbff94b commit ad56bd8

File tree

1 file changed

+3
-3
lines changed

1 file changed

+3
-3
lines changed

ngclearn/components/base_monitor.py

+3-3
Original file line numberDiff line numberDiff line change
@@ -261,7 +261,7 @@ def make_plot(self, compartment, ax=None, ylabel=None, xlabel=None, title=None,
261261
if n is None:
262262
n = vals.shape[2]
263263
if title is None:
264-
title = compartment.display_name
264+
title = compartment.name.split("/")[0] + " " + compartment.display_name
265265

266266
if ylabel is None:
267267
_ylabel = compartment.units
@@ -283,14 +283,14 @@ def make_plot(self, compartment, ax=None, ylabel=None, xlabel=None, title=None,
283283
if _ylabel:
284284
_ax.ylabel(_ylabel)
285285
if _xlabel:
286-
_ax.xlabel("")
286+
_ax.xlabel(_xlabel)
287287
else:
288288
_ax = ax
289289
_ax.set_title(title)
290290
if _ylabel:
291291
_ax.set_ylabel(_ylabel)
292292
if _xlabel:
293-
_ax.set_xlabel("Time Steps")
293+
_ax.set_xlabel(_xlabel)
294294

295295
if plot_func is None:
296296
for k in range(n):

0 commit comments

Comments
 (0)