Closed bjlittle closed 8 months ago
Attention: 25 lines
in your changes are missing coverage. Please review.
Comparison is base (
79385ff
) 94.91% compared to head (247ee97
) 94.49%.
Files | Patch % | Lines |
---|---|---|
src/geovista/search.py | 50.00% | 5 Missing :warning: |
src/geovista/bridge.py | 69.23% | 4 Missing :warning: |
src/geovista/common.py | 69.23% | 4 Missing :warning: |
src/geovista/filters.py | 77.77% | 2 Missing :warning: |
src/geovista/geodesic.py | 66.66% | 2 Missing :warning: |
src/geovista/geometry.py | 80.00% | 2 Missing :warning: |
src/geovista/pantry/textures.py | 66.66% | 2 Missing :warning: |
src/geovista/core.py | 75.00% | 1 Missing :warning: |
src/geovista/gridlines.py | 75.00% | 1 Missing :warning: |
src/geovista/pantry/__init__.py | 83.33% | 1 Missing :warning: |
... and 1 more |
:umbrella: View full report in Codecov by Sentry.
:loudspeaker: Have feedback on the report? Share it here.
@banesullivan @tkoyama010
I'd be really interested to know your thoughts on lazy_loader and whether it's appropriate to be adopted in pyvista
?
Also see SPEC 1 β Lazy Loading of Submodules and Functions.
I'd be really interested to know your thoughts on lazy_loader and whether it's appropriate to be adopted in
pyvista
?Also see SPEC 1 β Lazy Loading of Submodules and Functions.
I am fine with that. Let's discuss this at https://github.com/pyvista/pyvista/discussions/5512 !
Granted, this is just delaying or spreading the inevitable cost of importing the larger third-party packages e.g., pyvista, vtk, numpy, pyproj, but from a user perspective this is perhaps attractive.
I think maybe this is missing a point. The prime benefit to the user is never having to worry about which sub-modules are loaded by default, and which must be explicitly imported. In principle, you should always import everything you use, so
import geovista as gv
import geovista.pantry.meshes
data = gv.pantry.meshes.fesom()
But in practice, the user would rather just have all of geovista plugged in with a single import. And IIUC this is now possible.
import geovista as gv
data = gv.pantry.meshes.fesom()
π Pull Request
Description
This pull-request addresses the slow
import geovista
time, which can take between~2.5 - 3secs
.Incorporating these changes reduces this overhead to
>100msecs
e.g.,Granted, this is just delaying or spreading the inevitable cost of importing the larger third-party packages e.g.,
pyvista
,vtk
,numpy
,pyproj
, but from a user perspective this is perhaps attractive.Closes #647