-
Notifications
You must be signed in to change notification settings - Fork 1.4k
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
ENH: Speed up code a bit #11614
Merged
Merged
ENH: Speed up code a bit #11614
Conversation
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Okay I think this is good enough for now. I'll leave further improvements for later. @drammock feel free to review/merge if you're happy |
larsoner
commented
Apr 3, 2023
mne/utils/docs.py
Outdated
@@ -1658,7 +1658,7 @@ def _reflow_param_docstring(docstring, has_first_line=True, width=75): | |||
index : {} | None | |||
Kind of index to use for the DataFrame. If ``None``, a sequential | |||
integer index (:class:`pandas.RangeIndex`) will be used. If ``'time'``, a | |||
:class:`pandas.Float64Index`, :class:`pandas.Int64Index`, {}or | |||
``pandas.Float64Index``, ``pandas.Int64Index``, {}or |
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.
Hopefully temporary workaround Proper fix for pandas-dev/pandas#52379
larsoner
commented
Apr 3, 2023
drammock
approved these changes
Apr 4, 2023
larsoner
added a commit
to alexrockhill/mne-python
that referenced
this pull request
Apr 12, 2023
* upstream/main: MAINT: Add token [ci skip] (mne-tools#11622) API: One cycle of backward compat (mne-tools#11621) MAINT: Use git rather than zipball (mne-tools#11620) ENH: Speed up code a bit (mne-tools#11614)
larsoner
added a commit
to cbrnr/mne-python
that referenced
this pull request
Apr 21, 2023
* upstream/main: (50 commits) BUG: Fix bug with paths (mne-tools#11639) MAINT: Report download time and size (mne-tools#11635) MRG: Allow retrieval of channel names via make_1020_channel_selections() (mne-tools#11632) Fix index name in to_data_frame()'s docstring (mne-tools#11457) MAINT: Use VTK prerelease wheels in pre jobs (mne-tools#11629) ENH: Allow gradient compensated data in maxwell_filter (mne-tools#10554) make test compatible with future pandas (mne-tools#11625) Display SVG figures correctly in Report (mne-tools#11623) API: Port ieeg gui over to mne-gui-addons and add tfr gui example (mne-tools#11616) MAINT: Add token [ci skip] (mne-tools#11622) API: One cycle of backward compat (mne-tools#11621) MAINT: Use git rather than zipball (mne-tools#11620) ENH: Speed up code a bit (mne-tools#11614) [BUG, MRG] Don't modify info in place for transform points (mne-tools#11612) [BUG, MRG] Fix topomap extra plot generated, add util to check a range (mne-tools#11607) ENH: Add mne-bids-pipeline to mne sys_info (mne-tools#11606) MAINT: `coding: utf-8` is implicit in Python 3 (mne-tools#11599) ENH: Read eyetracking data (Eyelink) (Fork of mne-tools#10855 ) (mne-tools#11152) MAINT: In Python 3, do not prefix literals with `u` (mne-tools#11604) MAINT: object is an implicit base for all classes (mne-tools#11601) ...
larsoner
added a commit
that referenced
this pull request
Apr 24, 2023
larsoner
added a commit
to larsoner/mne-python
that referenced
this pull request
Apr 25, 2023
* upstream/main: (152 commits) FIX: missing channels/fiducials can be np.nan (mne-tools#11634) use py3.10 in precommit config (mne-tools#11648) MAINT: Unify GH Actions pytest (mne-tools#11644) MRG: Rename "Discourse" link in top navigation to "Forum" [ci skip] (mne-tools#11649) ENH: Add support for Harmonic Field correction (mne-tools#11536) Add pre-commit (mne-tools#11541) BUG: Fix bug with paths (mne-tools#11639) MAINT: Report download time and size (mne-tools#11635) MRG: Allow retrieval of channel names via make_1020_channel_selections() (mne-tools#11632) Fix index name in to_data_frame()'s docstring (mne-tools#11457) MAINT: Use VTK prerelease wheels in pre jobs (mne-tools#11629) ENH: Allow gradient compensated data in maxwell_filter (mne-tools#10554) make test compatible with future pandas (mne-tools#11625) Display SVG figures correctly in Report (mne-tools#11623) API: Port ieeg gui over to mne-gui-addons and add tfr gui example (mne-tools#11616) MAINT: Add token [ci skip] (mne-tools#11622) API: One cycle of backward compat (mne-tools#11621) MAINT: Use git rather than zipball (mne-tools#11620) ENH: Speed up code a bit (mne-tools#11614) [BUG, MRG] Don't modify info in place for transform points (mne-tools#11612) ...
larsoner
added a commit
to larsoner/mne-python
that referenced
this pull request
Apr 25, 2023
* upstream/main: (117 commits) FIX: missing channels/fiducials can be np.nan (mne-tools#11634) use py3.10 in precommit config (mne-tools#11648) MAINT: Unify GH Actions pytest (mne-tools#11644) MRG: Rename "Discourse" link in top navigation to "Forum" [ci skip] (mne-tools#11649) ENH: Add support for Harmonic Field correction (mne-tools#11536) Add pre-commit (mne-tools#11541) BUG: Fix bug with paths (mne-tools#11639) MAINT: Report download time and size (mne-tools#11635) MRG: Allow retrieval of channel names via make_1020_channel_selections() (mne-tools#11632) Fix index name in to_data_frame()'s docstring (mne-tools#11457) MAINT: Use VTK prerelease wheels in pre jobs (mne-tools#11629) ENH: Allow gradient compensated data in maxwell_filter (mne-tools#10554) make test compatible with future pandas (mne-tools#11625) Display SVG figures correctly in Report (mne-tools#11623) API: Port ieeg gui over to mne-gui-addons and add tfr gui example (mne-tools#11616) MAINT: Add token [ci skip] (mne-tools#11622) API: One cycle of backward compat (mne-tools#11621) MAINT: Use git rather than zipball (mne-tools#11620) ENH: Speed up code a bit (mne-tools#11614) [BUG, MRG] Don't modify info in place for transform points (mne-tools#11612) ...
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
From
py-spy
profiling based on mne-tools/mne-qt-browser#161 (comment) , i.e., Raw with thousands of annotations, I've found a couple of things so far:Annotations.__iter__
can be slow due to_any_ch_names()
. The fix is to check this once and pass it to__getitem__
.setApplicationIcon
was taking tens of seconds forpytest mne/viz
(!), so check to see if we actually need to set it based on thecacheKey()
property.Draft for now just so I can see if I've broken anything so far. I plan to add other stuff as I find it.