-
Notifications
You must be signed in to change notification settings - Fork 584
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
MAINT: Future-compatible cmap reversal #2131
Conversation
thanks! |
how did you trigger the warning? running the tests? |
Any |
(I based the 3.2 in the comments on the deprecation warning I got from MPL) |
sorry for the delay @larsoner |
Codecov Report
@@ Coverage Diff @@
## master #2131 +/- ##
=========================================
- Coverage 92.3% 92.3% -0.01%
=========================================
Files 142 142
Lines 18508 18515 +7
Branches 2255 2255
=========================================
+ Hits 17084 17090 +6
- Misses 920 921 +1
Partials 504 504
Continue to review full report at Codecov.
|
My editor removed trailing whitespace (arguably a good thing), which caused CIs to flag PEP8 errors on those lines (arguably a good thing), so I'm going to fix the PEP8 errors in those vicinities (could be a good or bad thing). There are a ton in the file and I don't want to touch everything, so I'll try to stay localized. Or if you prefer I can revert the whitespace changes and just keep the relevant ones for MPL deprecation. |
My editor removed trailing whitespace (arguably a good thing),
I like to configure mine so that it only does this on lines that I have
touched, to keep diffs clean
which caused CIs to flag PEP8 errors on those lines (arguably a good thing), so I'm going to fix the PEP8 errors in those vicinities (could be a good or bad thing). There are a ton in the file and I don't want to touch everything, so I'll try to stay localized.
thanks for fixing them!
Or if you prefer I can revert the whitespace changes and just keep the relevant ones for MPL deprecation.
Now that you have already fixed the PEP8 errors we should keep it that
way
|
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.
LGTM. thanks a lot!
Add this under fixes in what's new. |
Done |
LGTM. Merging. |
…clean * 'master' of https://github.com/nilearn/nilearn: (2100 commits) Fixes nilearn#2029 Handle gzip files without extensions (nilearn#2126) Update Schaefer parcelation to v0.14.3 (nilearn#2138) MAINT: Future-compatible cmap reversal (nilearn#2131) fix openmp crash (nilearn#2140) change nose to pytest on appveyor (nilearn#2130) adding fix to whatsnew fix wrong urls in nki dataset Made Flake8 happy added whats_new Added test for labels=None More explicit doc string Test for right length of labels Added tests for empty list case and labels as ndarray ensure labels is a list, not an ndarray Change such that empty lists are recognized as False Undid some documentation changes as their reason is not understood Replaced conda latest version with 4.6.* pending replacement Removed omit sections (nothing to omit, it would seem) Corrected docstring for bg_img in plot_stat_map Removed omit=*test* to fix error during coverage reporting ... # Conflicts: # nilearn/tests/test_signal.py
…encoding * 'master' of github.com:nilearn/nilearn: (228 commits) Expose bg_img, vmin and vmax in plot_img signature (nilearn#2157) Replac conda with pip in TravisCI setup (nilearn#2141) Core devs doc and add @emdupre (nilearn#2151) Add check for vmin, vmax in plot_surf_roi (nilearn#2052) [ENH] Initial visual reports (nilearn#2019) Renamed test to deduplicate name (nilearn#2144) Fixes nilearn#2029 Handle gzip files without extensions (nilearn#2126) Update Schaefer parcelation to v0.14.3 (nilearn#2138) MAINT: Future-compatible cmap reversal (nilearn#2131) fix openmp crash (nilearn#2140) change nose to pytest on appveyor (nilearn#2130) adding fix to whatsnew fix wrong urls in nki dataset Made Flake8 happy added whats_new Added test for labels=None More explicit doc string Test for right length of labels Added tests for empty list case and labels as ndarray ensure labels is a list, not an ndarray ...
…s_brain_orientation * 'master' of https://github.com/nilearn/nilearn: (116 commits) Import HTMLDocument in its original module to preserve backwards compatibility (nilearn#2162) Fixing malfunctioning allowed-failure section in Travis (nilearn#2160) Update Brainomics fetcher (nilearn#2097) Remove inplace modification in signal.clean (nilearn#2125) Iter age group prediction example (nilearn#2063) Expose bg_img, vmin and vmax in plot_img signature (nilearn#2157) Replac conda with pip in TravisCI setup (nilearn#2141) Core devs doc and add @emdupre (nilearn#2151) Add check for vmin, vmax in plot_surf_roi (nilearn#2052) [ENH] Initial visual reports (nilearn#2019) Renamed test to deduplicate name (nilearn#2144) Fixes nilearn#2029 Handle gzip files without extensions (nilearn#2126) Update Schaefer parcelation to v0.14.3 (nilearn#2138) MAINT: Future-compatible cmap reversal (nilearn#2131) fix openmp crash (nilearn#2140) change nose to pytest on appveyor (nilearn#2130) adding fix to whatsnew fix wrong urls in nki dataset Made Flake8 happy added whats_new ... # Conflicts: # doc/whats_new.rst
…lot_connectome_strength * 'master' of https://github.com/nilearn/nilearn: (272 commits) [MRG] FIX: orientation problem with plot_glass_brain (nilearn#1888) Import HTMLDocument in its original module to preserve backwards compatibility (nilearn#2162) Fixing malfunctioning allowed-failure section in Travis (nilearn#2160) Update Brainomics fetcher (nilearn#2097) Remove inplace modification in signal.clean (nilearn#2125) Iter age group prediction example (nilearn#2063) Expose bg_img, vmin and vmax in plot_img signature (nilearn#2157) Replac conda with pip in TravisCI setup (nilearn#2141) Core devs doc and add @emdupre (nilearn#2151) Add check for vmin, vmax in plot_surf_roi (nilearn#2052) [ENH] Initial visual reports (nilearn#2019) Renamed test to deduplicate name (nilearn#2144) Fixes nilearn#2029 Handle gzip files without extensions (nilearn#2126) Update Schaefer parcelation to v0.14.3 (nilearn#2138) MAINT: Future-compatible cmap reversal (nilearn#2131) fix openmp crash (nilearn#2140) change nose to pytest on appveyor (nilearn#2130) adding fix to whatsnew fix wrong urls in nki dataset Made Flake8 happy ... # Conflicts: # examples/03_connectivity/plot_sphere_based_connectome.py
…ounds_for_connectome * 'master' of https://github.com/nilearn/nilearn: (227 commits) [MRG] FIX: orientation problem with plot_glass_brain (nilearn#1888) Import HTMLDocument in its original module to preserve backwards compatibility (nilearn#2162) Fixing malfunctioning allowed-failure section in Travis (nilearn#2160) Update Brainomics fetcher (nilearn#2097) Remove inplace modification in signal.clean (nilearn#2125) Iter age group prediction example (nilearn#2063) Expose bg_img, vmin and vmax in plot_img signature (nilearn#2157) Replac conda with pip in TravisCI setup (nilearn#2141) Core devs doc and add @emdupre (nilearn#2151) Add check for vmin, vmax in plot_surf_roi (nilearn#2052) [ENH] Initial visual reports (nilearn#2019) Renamed test to deduplicate name (nilearn#2144) Fixes nilearn#2029 Handle gzip files without extensions (nilearn#2126) Update Schaefer parcelation to v0.14.3 (nilearn#2138) MAINT: Future-compatible cmap reversal (nilearn#2131) fix openmp crash (nilearn#2140) change nose to pytest on appveyor (nilearn#2130) adding fix to whatsnew fix wrong urls in nki dataset Made Flake8 happy ...
…_roi_contours * 'master' of https://github.com/nilearn/nilearn: (227 commits) [MRG] FIX: orientation problem with plot_glass_brain (nilearn#1888) Import HTMLDocument in its original module to preserve backwards compatibility (nilearn#2162) Fixing malfunctioning allowed-failure section in Travis (nilearn#2160) Update Brainomics fetcher (nilearn#2097) Remove inplace modification in signal.clean (nilearn#2125) Iter age group prediction example (nilearn#2063) Expose bg_img, vmin and vmax in plot_img signature (nilearn#2157) Replac conda with pip in TravisCI setup (nilearn#2141) Core devs doc and add @emdupre (nilearn#2151) Add check for vmin, vmax in plot_surf_roi (nilearn#2052) [ENH] Initial visual reports (nilearn#2019) Renamed test to deduplicate name (nilearn#2144) Fixes nilearn#2029 Handle gzip files without extensions (nilearn#2126) Update Schaefer parcelation to v0.14.3 (nilearn#2138) MAINT: Future-compatible cmap reversal (nilearn#2131) fix openmp crash (nilearn#2140) change nose to pytest on appveyor (nilearn#2130) adding fix to whatsnew fix wrong urls in nki dataset Made Flake8 happy ...
…nt_modify_fetch_dev * 'master' of https://github.com/nilearn/nilearn: (228 commits) [MRG] Nans in view connectome (nilearn#2166) [MRG] FIX: orientation problem with plot_glass_brain (nilearn#1888) Import HTMLDocument in its original module to preserve backwards compatibility (nilearn#2162) Fixing malfunctioning allowed-failure section in Travis (nilearn#2160) Update Brainomics fetcher (nilearn#2097) Remove inplace modification in signal.clean (nilearn#2125) Iter age group prediction example (nilearn#2063) Expose bg_img, vmin and vmax in plot_img signature (nilearn#2157) Replac conda with pip in TravisCI setup (nilearn#2141) Core devs doc and add @emdupre (nilearn#2151) Add check for vmin, vmax in plot_surf_roi (nilearn#2052) [ENH] Initial visual reports (nilearn#2019) Renamed test to deduplicate name (nilearn#2144) Fixes nilearn#2029 Handle gzip files without extensions (nilearn#2126) Update Schaefer parcelation to v0.14.3 (nilearn#2138) MAINT: Future-compatible cmap reversal (nilearn#2131) fix openmp crash (nilearn#2140) change nose to pytest on appveyor (nilearn#2130) adding fix to whatsnew fix wrong urls in nki dataset ... # Conflicts: # nilearn/datasets/func.py
…ecomposition * 'master' of https://github.com/nilearn/nilearn: (348 commits) [MRG] FIX: orientation problem with plot_glass_brain (nilearn#1888) Import HTMLDocument in its original module to preserve backwards compatibility (nilearn#2162) Fixing malfunctioning allowed-failure section in Travis (nilearn#2160) Update Brainomics fetcher (nilearn#2097) Remove inplace modification in signal.clean (nilearn#2125) Iter age group prediction example (nilearn#2063) Expose bg_img, vmin and vmax in plot_img signature (nilearn#2157) Replac conda with pip in TravisCI setup (nilearn#2141) Core devs doc and add @emdupre (nilearn#2151) Add check for vmin, vmax in plot_surf_roi (nilearn#2052) [ENH] Initial visual reports (nilearn#2019) Renamed test to deduplicate name (nilearn#2144) Fixes nilearn#2029 Handle gzip files without extensions (nilearn#2126) Update Schaefer parcelation to v0.14.3 (nilearn#2138) MAINT: Future-compatible cmap reversal (nilearn#2131) fix openmp crash (nilearn#2140) change nose to pytest on appveyor (nilearn#2130) adding fix to whatsnew fix wrong urls in nki dataset Made Flake8 happy ... # Conflicts: # doc/connectivity/resting_state_networks.rst # doc/whats_new.rst # examples/03_connectivity/plot_canica_analysis.py
Without this change I get warnings of the form:
The suggested fix of
.reversed()
is not immediately usable because that wouldn't give us the data to put in_cmaps_data
, so just take the (simple) mpl code to do the reversal knowing they're alldict
and notcallable
.