-
Notifications
You must be signed in to change notification settings - Fork 200
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
Add BaseRasterWidget
#3661
base: main
Are you sure you want to change the base?
Add BaseRasterWidget
#3661
Conversation
I have to admit I like your style better with the edges removed. Looking classier to me. Something I've been meaning to suggest for a long time! |
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.
first round of comments. I think the main thing is actually making sure the segment handling is working as expected. I think a bug from before this refactor was being propagated.
Co-authored-by: Zach McKenzie <92116279+zm711@users.noreply.github.com>
There's currently different behaviour for plot_rasters and plot_amplitudes for a multi-segment analyzers.
Should we keep the different behaviours? Or unify the behaviour? |
Maybe warn and plot the first one? |
I would say unify the behaviors in general. I only deal in mono segments so if Alessio is good with warn and do the first then that works for me for everything. I think I would lean toward error to force people to specify a segment so they realize this is only plotting one segment, but I'm also okay with a warning. |
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.
I'm sorry for this.
Added
BaseRasterWidget
widget, and re-factoredAmplitudeWidget
,RasterWidget
andDriftRasterMapWidget
to use it.Following on from @JoeZiminski's comment in #3649, I’ve made a
BaseRasterWidget
, which can be used to make spike times vs anything plots. Some advantages:AmplitudeWidget
,RasterWidget
andDriftRasterMapWidget
(and later LocationsWidget)y_lim
andscatter_decimate
fromDriftRasterMapWidget
is now available forAmplitudeWidget
.Now users (and devs!) can easily make custom raster plots, e.g. if you have a sorting analyzer called
sa
with spike_amplitudes computed, you can do:which makes this:

The goal was for this to be totally backend and not change any plots, but when doing it, I think it was a chance to unify some widget style choices. E.g. drawing just the left and bottom axes, and making the data fill the plot. It's a little difficult to test all this stuff. Here's a bunch of plots using
main
and this PR. I've also checking that SortingView can still do an amplitudes plot and played withipywidgets
a lot.OLD vs NEW