-
-
Notifications
You must be signed in to change notification settings - Fork 54
[FIX] Fix jax and os.fork warnings #557
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
Conversation
59e6903 to
a793512
Compare
|
Hi @mmcky, I tried different approaches but no method gives clean output like I find that we can fix the warning by importing This PR fixes the two warnings on my end. The error now is caused by a strange error from |
jax and os.fork warnings
jax and os.fork warnings| ```{code-cell} ipython3 | ||
| fig = go.Figure() | ||
| fig.add_trace(go.Scatter(x=grid, y=f_val, name=r'$-3x+2$')) |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@HumphreyYang the failure in back_prop in the pdf builder could be due to the removal of these $ signs?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
I will run locally to check and confirm.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Thanks @mmcky,
I removed them because of the error but it doesn't seem to be working : (
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
@HumphreyYang I think the error was due to big changes in plotly and Kaleido versions. It also seems to have been re-written around chrome.
|
@HumphreyYang I can build this branch locally -- I have triggered another run just in case. Leave this with me. Thanks of your work on this. |
|
@HumphreyYang the issue being reported in �[0;31mValueError�[0m:
Image export using the "kaleido" engine requires the kaleido package,
which can be installed using pip:
$ pip install -U kaleidoso trying an install upgrade. |
|
Hi @mmcky, I think this might be related to QuantEcon/lecture-python-advanced.myst#221. Something breaks when using |
|
Many thanks @mmcky! It looks like it is building!! I think colab servers do not have chrome so it might be hard to solve on the colab side. |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Pull Request Overview
This PR addresses JAX and os.fork warnings reported in issue #548 by reorganizing import statements and improving build configuration. The changes ensure proper JAX initialization order and suppress unnecessary warning messages during the build process.
- Reorganizes JAX imports and GPU checks in lecture files to prevent initialization warnings
- Updates package installation commands for better compatibility
- Adds warning suppression configuration to prevent build noise
Reviewed Changes
Copilot reviewed 4 out of 4 changed files in this pull request and generated 2 comments.
| File | Description |
|---|---|
| lectures/status.md | Reorders GPU check to occur before JAX backend verification |
| lectures/back_prop.md | Moves JAX installation and import after other package setups, updates plotly installation |
| lectures/_config.yml | Adds warning suppression for unknown MIME types |
| .github/workflows/ci.yml | Updates artifact naming and removes failure condition |
Co-authored-by: Copilot <175728472+Copilot@users.noreply.github.com>
|
thanks @HumphreyYang great to get those warnings removed. LGTM |
This PR fixes the
os.forkwarning documented in #548.This together with #556, fixes #548.