-
-
Notifications
You must be signed in to change notification settings - Fork 1.4k
Description
cc @drammock there is https://scientific-python.org/specs/ , I assume you have thoughts/ideas/knowledge from the conference but wanted to get it on our radar.
- SPEC0: The minimum version one I haven't ready but I assume is close to what we do anyway, and if that's the case we should endorse/officially adopt it
- SPEC4: Nightly wheels I guess we could do but we're pure Python so seems unnecessary.
The interesting one is that might deserve some discussion is SPEC1 lazy loading. The lazy_load
package idea seems great. We could maybe get rid of all of our nested imports except maybe matplotlib
, and still have the nested import test pass. And import mne
would be faster because @verbose
creating functions does have a non-zero overhead, which I think accounts for most of this:
$ time python -c "import numpy, scipy"
real 0m0.123s
$ time python -c "import mne"
real 0m0.464s
But this would be another package to add to MNE-Python's dependency list (which has a high adoption cost as discussed before) or we'd have to vendor it, which would make the conda-forge people unhappy. Or we'd have to do some hybrid where we try: import lazy_loader; except Exception: <import our vendored one>
.
@agramfort would vendoring a BSD module be problematic from the industry-adoption end?