Skip to content

Commit

Permalink
Fix frequency range inversion and update y-axis direction in visualiz…
Browse files Browse the repository at this point in the history
…ation

Signed-off-by: samadpls <[email protected]>
  • Loading branch information
samadpls committed Feb 5, 2025
1 parent 5ab4986 commit 0c0d446
Show file tree
Hide file tree
Showing 2 changed files with 7 additions and 0 deletions.
3 changes: 3 additions & 0 deletions doc/whats_new.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,6 +24,9 @@ orphan: true
to prevent overlap, and added an argument for custom cell types, by
[George Dang][] in {gh}`895`

- Added check for invalid Axes object in :func:`~hnn_core.viz.plot_cells`
function, by [Abdul Samad Siddiqui][] in {gh}`744`.

### Bug

- Fix GUI over-plotting of loaded data where the app stalled and did not plot
Expand Down
4 changes: 4 additions & 0 deletions hnn_core/gui/_viz_manager.py
Original file line number Diff line number Diff line change
Expand Up @@ -304,6 +304,10 @@ def _update_ax(fig, ax, single_simulation, sim_name, plot_type, plot_config):
freqs = np.arange(min_f, max_f, step_f)
n_cycles = freqs / 2.

if freqs[0] > freqs[-1]:
freqs = freqs[::-1]
ax.invert_yaxis()

try:
dpls_copied[0].plot_tfr_morlet(
freqs,
Expand Down

0 comments on commit 0c0d446

Please sign in to comment.