-
-
Notifications
You must be signed in to change notification settings - Fork 404
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
Optimize import startup time #1892
Comments
After an initial look I don't think there's much we can do about numpy, pandas and probably scipy. I would however consider moving the iris extension into GeoViews, which will shave off about 700ms. We could also investigate why numba gets imported by default which could shave another 500ms off. |
Just tested it without the iris data interface, which brings it down to 1549.9 ms vs. 3858.4 ms with it. I'd say we should definitely move it to GeoViews. |
Sounds good. I would also like to defer scipy imports to where they are needed, presumably in operations but not much else of holoviews needs scipy afaik. |
Moving iris support does make sense; there surely will be very few users who want Iris without GeoViews. (Conversely, not sure if it's possible to copy WMTS from GeoViews to HV? Seems like that part wouldn't depend on the rest of GeoViews, as long as projections are left up to the user, and I think that's the part of GV people are mostly likely to want (and thus could have without having the other heavy dependencies of GV. But I digress. :-) I always get confused by profiler output, but it seems to me to be saying that 0.6s is spent importing numpy. That's odd, because launching python and importing numpy by itself together take only 0.2s:
Maybe it's importing specific things from numpy that is expensive, not numpy as a module? |
So I've just had a go at this but the main issue that there is no way for me to move the tests into geoviews since they rely on baseclasses which are in the holoviews root directory. I think we should start moving tests into the modules they apply to rather than keeping them all separate. This is also the structure other projects like bokeh follow. |
Just to clarify, this issue is "closed - done", not "closed - wontfix", despite the last comment above... |
This issue has been automatically locked since there has not been any recent activity after it was closed. Please open a new issue for related bugs. |
We have on occasion discussed how long it takes to import holoviews. After coming across the import_profiler library I just ran it so now we have something concrete to discuss, here's the output:
The text was updated successfully, but these errors were encountered: