Loading numpy doesn't matter, "installing" it (via micropip) is what takes some time, that's when it's being copied to your local browser cache. But that's fine. SciPy is worse, but also fine. Importing it just does the normal Python thing (importing) from that local file.
I think there's a way to "hide" this, that is, cause it to load install automatically. Some places (like numpy.org) load install it as part of loading the season. It just saves a little visible code (the micropip part), but nice because it would look more like "native" code and not confuse users with a strange pyodide construct. I haven't worked that out, though (it might just be calling the command manually from JS).
Originally posted by @henryiii in #1820 (comment)
Loading numpy doesn't matter, "installing" it (via micropip) is what takes some time, that's when it's being copied to your local browser cache. But that's fine. SciPy is worse, but also fine. Importing it just does the normal Python thing (importing) from that local file.
I think there's a way to "hide" this, that is, cause it to
loadinstall automatically. Some places (like numpy.org)loadinstall it as part of loading the season. It just saves a little visible code (the micropip part), but nice because it would look more like "native" code and not confuse users with a strange pyodide construct. I haven't worked that out, though (it might just be calling the command manually from JS).Originally posted by @henryiii in #1820 (comment)