VWIP Topoplot refactor - #5568
jona-sassenhagen wants to merge 2 commits into
Conversation
| type_name = ', '.join(cls.__name__ for cls in iter_types) | ||
| if not isinstance(item, types): | ||
| raise TypeError(item_name, ' must be an instance of ', type_name, | ||
| raise TypeError(item_name + ' must be an instance of ' + type_name + |
There was a problem hiding this comment.
why this change? and either way once we release we would be able to start using fstrings.
There was a problem hiding this comment.
I think it printed weird before.
Don't see how an fstring would be better here. You could already do it with string interpolation right? this is very transparent.
There was a problem hiding this comment.
Also @larsoner fixed the very same bug in your recent PR anyways :) via string interpolation
|
|
||
|
|
||
| def _plot_evoked_topo(evoked, layout=None, layout_scale=0.945, color=None, | ||
| def _handle_grads_for_topos(evokeds, noise_cov=None, scalings=None, |
There was a problem hiding this comment.
can we come up with a better name than handle?
There was a problem hiding this comment.
To be honest, I'm not sure how to call what it's doing. (Note I didn't write that code, only moved it.)
|
Ok the current implementation is bad. Will hopefully solve it better with @drammock :) |
|
Thanks for looking over it though @massich |
Have plot_evoked_topo use plot_compare_evokeds.
Benefits: looks nicer, CIs, code reuse, API consistency.
preemptively tagging @sappelhoff @mmagnuski @cbrnr @choldgraf ...
closes #4746