Skip to content
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

Spike: Investigate caching WebAssembly modules to reduce latency #934

Closed
loiswells97 opened this issue Feb 26, 2024 · 2 comments · May be fixed by #974
Closed

Spike: Investigate caching WebAssembly modules to reduce latency #934

loiswells97 opened this issue Feb 26, 2024 · 2 comments · May be fixed by #974
Assignees
Labels

Comments

@loiswells97
Copy link
Contributor

Although the .whl files are cached between code runs, the fact that we need to reset pyodide between runs means that they need to be re-interpreted each time the code runs. This introduces some latency which we may be able to reduce if we cache using WebAssembly modules (see Slack thread for more details)

@sra405 sra405 added this to the Pyodide Rollout milestone Mar 6, 2024
@loiswells97 loiswells97 self-assigned this Mar 14, 2024
Copy link
Contributor

@loiswells97
Copy link
Contributor Author

loiswells97 commented Mar 18, 2024

Thoughts

  • There is a noticeable delay of around 5 seconds at the start of each code run using sklearn as a (rather large) example, but this is just over a second for something like numpy (which perhaps we are more likely to use)
  • It may be possible to cache the wasm files, but this thread suggests it's complicated and may not make enough to difference to be worth it

@loiswells97 loiswells97 changed the title Cache WebAssembly modules to reduce latency Spike: Investigate caching WebAssembly modules to reduce latency Mar 18, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

Successfully merging a pull request may close this issue.

2 participants