Skip to content

[kalman_2] Update to JAX#644

Open
xuanguang-li wants to merge 8 commits into
mainfrom
update_kalman2
Open

[kalman_2] Update to JAX#644
xuanguang-li wants to merge 8 commits into
mainfrom
update_kalman2

Conversation

@xuanguang-li

Copy link
Copy Markdown
Contributor

This pull request improves the lectures/kalman_2.md file, focusing on code modernization, clarity, and consistency.
The main updates include:

  • Refactored the code to use jax for array creation, mathematical operations, and simulation functions. Some numpy code remains to avoid data type–related warnings.
  • Improved the logic of the Kalman filter implementation, including clarifying the meaning of the variable x_hat and handling the initial states more carefully.
  • Standardized parameter names in worker creation and simulation functions — for example, replacing hhat_0 and uhat_0 with μ_h and μ_u, and defining hhat_0 and uhat_0 as the priors.
  • Added a seed parameter to all simulation calls.
  • Fixed typos and added explanatory comments for better readability.

@github-actions

Copy link
Copy Markdown

@xuanguang-li xuanguang-li changed the title Update kalman2 [kalman_2] Update Oct 13, 2025
@github-actions

Copy link
Copy Markdown

@github-actions

Copy link
Copy Markdown

@github-actions

Copy link
Copy Markdown

@xuanguang-li xuanguang-li changed the title [kalman_2] Update [kalman_2] Update to JAX Oct 13, 2025
@xuanguang-li xuanguang-li marked this pull request as ready for review October 13, 2025 07:27
@github-actions

Copy link
Copy Markdown

📖 Netlify Preview Ready!

Preview URL: https://pr-644--sunny-cactus-210e3e.netlify.app (2119e95)

📚 Changed Lecture Pages: kalman_2

@mmcky

mmcky commented Oct 15, 2025

Copy link
Copy Markdown
Contributor

thanks @xuanguang-li. I have just merged in the latest main and the preview is now showing kalman_2 as the change.

@xuanguang-li

Copy link
Copy Markdown
Contributor Author

Thanks @mmcky. I noticed a warning right below the import cell, saying.

Matplotlib is building the font cache; this may take a moment.

Should we hide this output or leave it there?

@jstac

jstac commented Jul 8, 2026

Copy link
Copy Markdown
Contributor

🤖 Status note for a future session — from a maintainer investigation on 2026-07-08 into why open-PR previews 404. Context only, not instructions.

Netlify preview: https://pr-644--sunny-cactus-210e3e.netlify.app/ currently returns 404.

Why previews are down (repo-wide findings)

1. This branch is stale — 174 commits behind main. A preview build compiles the whole site from this branch. This branch's lectures/house_auction.md still has unpinned !pip install prettytable, which now breaks on a wcwidth incompatibility. main fixed this on 2026-06-28 by pinning prettytable<3.18 (#939). This alone fails any rebuild of this branch until it's updated to main.

2. The arviz failure was a red herring — do NOT pin arviz or rewrite plotting. A 2026-07-07 rebuild also failed in ar1_bayes/ar1_turningpts with an arviz_plots figsize ValueError. That was a transient bug in an intermediate arviz-plots 1.x release, already fixed in arviz 1.2.0. Verified locally on a clean latest-stack venv: the real az.plot_trace(trace) cell (pymc + numpyro InferenceData) runs green. The lectures use only 1.x-compatible arviz APIs (plot_trace, summary, from_numpyro, compare).

Recommended first step for this PR

Update this branch to main (merge or rebase — pulls in #939 plus ~174 other commits), then let CI rebuild. On today's latest libraries the site builds clean, so the preview should return. house_auction is the known blocker; updating also picks up other since-merged fixes — rebuild and address any remaining per-lecture failures. Verify with:

curl -sI https://pr-644--sunny-cactus-210e3e.netlify.app/kalman_2.html

This PR touches: kalman_2.md. Last CI build: success@2025-10-15. Branch: 174 commits behind main as of 2026-07-08.

@xuanguang-li

Copy link
Copy Markdown
Contributor Author

@copilot resolve the merge conflicts in this pull request

Copilot AI commented Jul 9, 2026

Copy link
Copy Markdown
Contributor

@copilot resolve the merge conflicts in this pull request

Resolved. I merged the latest main into this branch and fixed the conflict in lectures/kalman_2.md in commit 1f3225b.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Projects

Status: In Progress

Development

Successfully merging this pull request may close these issues.

4 participants