New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
MRG, VIZ, MAINT: Use new figure class for epochs.plot and ICA.plot_sources #8381
Conversation
Hello @drammock, maybe I'm doing something wrong – and I really haven't looked at the code changes here – but right-clicking on an IC "channel" name in a plot produced by |
at the moment only |
Thanks @drammock! It's beautiful! What I've noticed:
|
d1d68c1
to
7743e89
Compare
7743e89
to
e4cc537
Compare
13e4d7c
to
8142e8d
Compare
@jasmainak is it easy for you to test the autoreject package with this branch, to make sure that |
48752f6
to
cc4dff9
Compare
OK, now
of these, I think items 3, 4, 5, and 7 are prominent (non-cosmetic) changes which I think should get buy-in from at least a couple other devs before merge, and some of them probably deserve changelog entries. Anything else you notice that seems weird --- anything at all --- please mention it now. |
We could allow
This appeared to just be about 0- versus 1-based indexing so I think it's fine / complementary Otherwise all these API changes sound like improvements to me, +1 for all of them. I'll wait to do a thorough review until we see if others agree and no other major changes are needed. @hoechenberger I see a heart, does that mean you're happy with all points? |
Yes I’m quite happy! Still got to actually try it out, but I do love the list of changes |
WDYT about just always showing an x-axis label, regardless of whether scrollbars are visible or hidden? |
I'm not sure how that interacts with |
|
I have no strong opinion, up to you. I would say if you want to go with as much backward compat as possible add |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
it works like a charm !!!! and with 2000 lines removed
@drammock you are like
LOL I can imagine that scene!! |
And longstanding functionality added (such as butterfly mode for epochs, right?) and waaaay more DRY code, etc. Bravo! I'll take a look and try things Monday. @hoechenberger do you want to test it out? I don't use the epochs or ICA very much so I'm not the best person to do it. |
Does this close #4850, or is more needed for that? |
Yes but won't be able to do it before tonight or tomorrow UTC+1 |
No but it should be quite easy to do. Will add that. |
@drammock I will try to give it another shot tomorrow, going to bed now :) But if you feel ready to get this merged, don't wait for me! |
Thanks for addressing #8304, @drammock! This seems to be fixed for me now. However, bad news is, instead of this traceback plus (sometimes) a segfault I now only receive the segfault |
But I don't intend to filibuster this PR just because my old computer is having some troubles. If I'm the only one experiencing this, maybe we can just go ahead and merge for now… I unfortunately won't be able to provide feedback / test again, though. But we can always iterate later. (Will hopefully have my 2019 MBP again in a week or two) |
Exceptions thrown during a callback will cause PyQt to abort. This should in theory be handled by @hoechenberger are you on the latest matplotlib version? And what version of PyQt5? |
Pushed a commit to showcase |
@larsoner |
0798bcf
to
68bca25
Compare
show ICA properties on right-click of component name renable right-click on ch name fix EOG scaling better pageup behavior when at bottom of channel list disable butterfly for ICA better keypress testing travis old deps debugging refactor plot_properties integration make bads color consistent with plot_raw fix _fake_click location to work when MNE_BROWSE_RAW_SIZE not set touch tutorial update what's new remove unreachable condition persist changes to ICA exclude WIP: handle epochs too take advantage of numpy version bump fix ticks fix scrolling click to mark bad; refactor allow bad epoch marking fix instructions get vlines working add image plot on right-click add epoch histogram bad ch color trumps bad epoch color use plt_show for epochs support custom colors for (autoreject compatibility) snap to epoch boundaries when clicking scrollbar verbose=False on channel/component context click figures make it work for ica.plot_sources(epochs) touch epochs tutorial fix CIs (disable keypress j if no projs present) clean up help window code make "show histogram" key a toggle retain xlabel in zen mode
fix: make epoch_colors work in butterfly mode [skip travis]
68bca25
to
73060df
Compare
@larsoner all green here, can we get this in so more folks can start testing it? |
Yes, thanks @drammock ! |
awesome @drammock <https://github.com/drammock> !
… |
|
@drammock looks like these are yours: Can you check and open a quick PR to fix? |
this is an element of #7751
Basically working already, though needs testing and maybe some cosmetics.