Replies: 17 comments
-
It looks like |
Beta Was this translation helpful? Give feedback.
-
@mmcky Thanks for the detailed setup. This looks promising.
I think |
Beta Was this translation helpful? Give feedback.
-
Thanks @Smit-create , sounds promising. Please keep @oyamad included in any decisions that involve QuantEcon.py |
Beta Was this translation helpful? Give feedback.
-
Thanks @jstac -- for sure. @Smit-create I have now create a project repository where we can deploy jupyterlite into gh-pages and share a common test environment. We can also document our findings in Issues and/or Wiki pages. |
Beta Was this translation helpful? Give feedback.
-
Now, since this doesn't support So, here's one thing that comes to my mind with minimal changes in
# We have function in qe.utils
def qe_jit(func, ...):
if NUMBA_PRESENT:
return numba.njit(func,...)
else:
return func And remove this error message completely: https://github.com/QuantEcon/QuantEcon.py/blob/67fe7044148f95dbad42f85c82e288c7c1584650/quantecon/__init__.py#L8-L14 That is replacing all the This will open the doors for our lectures to be dependent on |
Beta Was this translation helpful? Give feedback.
-
Thanks @Smit-create , sounds promising. Once @mmcky has reviewed this idea, let's run it by @oyamad . |
Beta Was this translation helpful? Give feedback.
-
Thanks @jstac. There's one more way to handle this, but that might be kind of hack-ish or repetitive. We can create a new fork |
Beta Was this translation helpful? Give feedback.
-
@Smit-create that is exactly the sort of approach I was thinking as well use a |
Beta Was this translation helpful? Give feedback.
-
I am not very enthusiastic about the idea of allowing
|
Beta Was this translation helpful? Give feedback.
-
Thanks for your comments @oyamad. You make good points. The key issue is how we make live lectures available to students. One option is via something like Google Colab, which is server-based. Another is distributed computing in the browser via WASM. The second option prohibits us using Numba. I quite like Colab but it's rather dangerous to completely rely on a service over which we have no control. On the other hand, using WASM degrades the quantecon library, as you say. And of course WASM doesn't make GPUs available, unlike Colab. So anyway, we have to choose between imperfect options. (For background, @sglyon is leading a project to develop a learning management system (for workshops and teaching) that integrates WASM. QuantEcon has invested in that project.) |
Beta Was this translation helpful? Give feedback.
-
I like the idea of QuantEcon-lite. We'll want to do what we can to minimize drift between QuantEcon.py and QuantEcon-lite I think one way to do this would be to migrate all code to QuantEcon-lite, but remove numba parts. Then QuantEcon.py could depend on QuantEcon-lite, import the routines, and re-wrap them in numba/jax/etc. depending on context. |
Beta Was this translation helpful? Give feedback.
-
(Just a side note) This is still very new and in development but this project may be able to target different contexts such as WebAssm, LLVM accelerated code, GPU etc. @oyamad @jstac thanks for your comments. I agree the library wouldn't function well without the acceleration (in the wasm context for some functions), but we wanted to understand which functions are needed for lecture-python-intro (to test if this lecture series could run fully in WASM) and then document the trade-offs. The current aim for this project is around @oyamad your idea of |
Beta Was this translation helpful? Give feedback.
-
Here's a small demo: https://smit-create.github.io/qe-wasm-demo/. It has just one lecture on cobweb and that works completely fine. Hence, we have a working demo. The above demo uses a hardcoded cobweb notebook. In order to automate this, we can write a python script:
The above tasks seem to be easygoing. We need to figure out the following:
|
Beta Was this translation helpful? Give feedback.
-
Thanks @Smit-create , very cool!! |
Beta Was this translation helpful? Give feedback.
-
I have written a script to automate updating the lectures (requires just a small manual effort of updating locally and pushing which can be automated later using gh-actions). The demo repo is: https://github.com/Smit-create/qe-wasm-demo. For the next steps, let's plan to test all the notebooks manually(as discussed in yesterday's meeting) so that we can check both code errors and
|
Beta Was this translation helpful? Give feedback.
-
thanks @Smit-create The
so perhaps we should try to address this |
Beta Was this translation helpful? Give feedback.
-
Thanks @mmcky, so to resolve that issue, as from the above discussion we have two options:
I'm fine with any of them and will fix that according to whichever is chosen. |
Beta Was this translation helpful? Give feedback.
-
This project is to review and recommend changes that need to be made to:
that will help us better use and support the upcoming WASM environments such as those provided by JupyterLite.
Aim: To focus on https://github.com/quantecon/lecture-python-intro and identify solutions with the aim to enable the entire lecture set to run in the browser via WASM. If this aim is not fully achievable due technical restrictions -- we need to document all those cases and identify solutions.
TimeFrame: This lecture set will be used to support the QuantEcon Africa workshops that will be run in the first two weeks of July 2023
Tasks include:
Resources
The jupyterlite project
jupyterlab-myst
is runnable to render fullmyst
notebooksmyst
ordownload notebook set
)Beta Was this translation helpful? Give feedback.
All reactions