-
Notifications
You must be signed in to change notification settings - Fork 3
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
Interest in supporting Kaggle? #3
Comments
Hi Francesco,
super - thank you for providing NGSolve within your fem - package on Kaggle.
@matthias:
I had a quick look - can we check for availability of jupyter - widgets, instead of checking explicitely for colab ?
Best, Joachim
… On 06.12.2022, at 10:17, Francesco Ballarin ***@***.***> wrote:
Hi @mhochsteger <https://github.com/mhochsteger> and @JSchoeberl <https://github.com/JSchoeberl>,
I got in touch with you a few months ago about my FEM on Colab <https://fem-on-colab.github.io/> project, which supports NGSolve, including visualization through the webgui.
A few users have asked me if, by reusing the same build system, I could also package the same libraries for usage on Kaggle. With a bit of work, this is now available in the spin-off project FEM on Kaggle <https://fem-on-kaggle.github.io/>.
Kaggle is based on jupyter lab, but does not support additional widgets unless they are hardcoded in their backend (see Kaggle/docker-python#1190 <Kaggle/docker-python#1190>). Since on Colab, at least to my understanding, you do not use widgets either, my thought was to patch
https://github.com/CERBSim/webgui_jupyter_widgets/blob/main/webgui_jupyter_widgets/widget.py#L30
changing the bool from False to True while packaging ngsolve for Kaggle, to trick the webgui into thinking that it is on Colab, so that
https://github.com/NGSolve/ngsolve/blob/master/python/webgui.py#L592
https://github.com/NGSolve/netgen/blob/master/python/webgui.py#L238
will follow on both Colab and Kaggle the same flow.
You can find the resulting packages at
https://fem-on-kaggle.github.io/packages.html
and a relevant test at
https://kaggle.com/kernels/welcome?src=https://github.com/fem-on-kaggle/fem-on-kaggle.github.io/blob/gh-pages/tests/ngsolve/test-ngsolve-extras.ipynb
If you run that notebook, at the first Draw(mesh) you will get a plot similar to the following screenshot, where some part of the webgui are shown but the mesh is missing, and the overall formatting is clearly wrong.
<https://user-images.githubusercontent.com/11783908/205868607-967ca0d8-e04c-4b85-b9ee-04464d78a498.png>
If you have any interest in supporting Kaggle I would be happy to test future releases of webgui_jupyter_widgets with my packaging workflow.
Cheers,
Francesco
—
Reply to this email directly, view it on GitHub <#3>, or unsubscribe <https://github.com/notifications/unsubscribe-auth/AAF7QDZKHDCOGBHOLOE6VD3WL4ADLANCNFSM6AAAAAASVIJNPY>.
You are receiving this because you were mentioned.
|
Hi @JSchoeberl There is
In my notebook those two issues are not a big deal, but I would advise against such a
I am not sure if that would be advisable.
|
Hi @mhochsteger and @JSchoeberl,
I got in touch with you a few months ago about my FEM on Colab project, which supports NGSolve, including visualization through the webgui.
A few users have asked me if, by reusing the same build system, I could also package the same libraries for usage on Kaggle. With a bit of work, this is now available in the spin-off project FEM on Kaggle.
Kaggle is based on
jupyter lab
, but does not support additional widgets unless they are hardcoded in their backend (see Kaggle/docker-python#1190). Since on Colab, at least to my understanding, you do not use widgets either, my thought was to patchhttps://github.com/CERBSim/webgui_jupyter_widgets/blob/main/webgui_jupyter_widgets/widget.py#L30
changing the bool from False to True while packaging ngsolve for Kaggle, to trick the webgui into thinking that it is on Colab, so that
https://github.com/NGSolve/ngsolve/blob/master/python/webgui.py#L592
https://github.com/NGSolve/netgen/blob/master/python/webgui.py#L238
will follow on both Colab and Kaggle the same flow.
You can find the resulting packages at
https://fem-on-kaggle.github.io/packages.html
and a relevant test at
https://kaggle.com/kernels/welcome?src=https://github.com/fem-on-kaggle/fem-on-kaggle.github.io/blob/gh-pages/tests/ngsolve/test-ngsolve-extras.ipynb
If you run that notebook, at the first
Draw(mesh)
you will get a plot similar to the following screenshot, where some part of the webgui are shown but the mesh is missing, and the overall formatting is clearly wrong.If you have any interest in supporting Kaggle I would be happy to test future releases of
webgui_jupyter_widgets
with my packaging workflow.Cheers,
Francesco
The text was updated successfully, but these errors were encountered: