Commit Graph

270 Commits

Author SHA1 Message Date
anyin233
92e3f3e059 refactor: restructure project and update documentation for second edition (#500)
* feat: remove bilingual button on the front page

* misc: clean repo

* test: fix test suite for v1/v2 restructure and removed language switch

* refactor: restructure chapters for the second edition

* refactor: restructure project

* refactor: remove unused scripts

* refactor: move conftest.py to tests directory

* refactor: update README with new chapter structure and logo path

* fix: update image paths in README and README_EN for consistency

* refactor: update directory structure and script references in documentation
2026-03-12 20:39:45 +00:00
anyin233
bdb823c575 refactor: clean the structure of current project (#499)
* feat: remove bilingual button on the front page

* misc: clean repo

* test: fix test suite for v1/v2 restructure and removed language switch
2026-03-12 18:24:03 +00:00
Yeqi Huang
6f677ff507 fix: fix undefined docsRoot variable in version-selector.js (#498)
The variable was renamed from docsRoot to root in #496 but one
reference was missed, causing a ReferenceError that broke the
entire script and prevented V1/V2/EN/ZH buttons from rendering.

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 17:32:57 +00:00
anyin233
a28ab0478b Add bilingual issue and PR templates (#497)
* feat: add bilingual issue and PR templates

* feat: add bilingual contributing guides for v2

* docs: migrate style guide to v2/info, trim contributing guides

* docs: move terminology to v2/info

* docs: update README links to v2 contributing and style guides

* refactor: remove content about Writing Guidelines from contribution guidence, replace it with link to style.md

* misc: update contribution guide and PR template
2026-03-12 17:15:45 +00:00
Yeqi Huang
95a086903b fix: fix 404 on version switch from index.html and strip pandoc heading IDs (#496)
Two fixes:

1. version-selector.js: Simplify basePath() to determine site root from
   the URL prefix (/ or /docs/) instead of trying to strip path segments.
   Previously, visiting /index.html caused basePath to compute
   /index.html/v1/ (404) because it didn't strip the filename first.

2. prepare_mdbook.py: Strip pandoc-style heading IDs ({#label}) from
   both extracted titles (used in SUMMARY.md sidebar) and rendered
   markdown content. Fixes "Model Deployment {#ch:deploy}" showing
   raw in the sidebar and page headings.

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 14:42:46 +00:00
Yeqi Huang
ea4d0d178e fix: fix preprocessor paths for v1/v2 mdbook builds (#495)
mdbook runs preprocessor commands from the book root directory (where
book.toml lives). The v1/v2 book.toml files had incorrect relative
paths to the preprocessor scripts, causing them to silently fail and
leaving raw rst directives (.. raw:: html, toc blocks) unprocessed.

Fix by using correct relative paths in book.toml (../tools/ for
top-level books, ../../../tools/ for books/zh/) and changing build
scripts to cd into book directories before running mdbook build.

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 14:01:24 +00:00
Yeqi Huang
d953030747 feat: add v1/v2 versioning with language selector (#494)
* feat: add v1/v2 versioning and language selector for mdbook

- Copy current content to v1/ directory (1st Edition)
- Create v2/ directory with new TOC structure (2nd Edition) and placeholder chapters
- Add version selector (V1/V2) and language toggle (EN/ZH) in top-right nav bar
- Add build scripts: build_mdbook_v1.sh, build_mdbook_v2.sh
- Update assemble_docs_publish_tree.py to support v1/v2 deployment layout
- Fix mdbook preprocessor to use 'sections' key (v0.4.43 compatibility)
- Update .gitignore for new build artifact directories
- Deployment layout: / = v2 EN, /cn/ = v2 ZH, /v1/ = v1 EN, /v1/cn/ = v1 ZH

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* build: update CI to build and verify all four books (v1/v2 x EN/ZH)

- Clarify step names: "Build v2 (EN + ZH)" and "Build v1 (EN + ZH)"
- Add verification step to check all four index.html outputs exist
- Deploy workflow assembles: / = v2 EN, /cn/ = v2 ZH, /v1/ = v1 EN, /v1/cn/ = v1 ZH

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix: gracefully skip missing TOC entries instead of crashing

resolve_toc_target() now returns None for missing files instead of
raising FileNotFoundError. This fixes v1 EN build where chapter index
files reference TOC entry names that don't match actual filenames.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 13:37:42 +00:00
anyin233
00db02dbfd fix: fix equation rendering by changing the toolchain to mathjax (#493)
* docs: update README and build guide

* fix: escape * and _ inside math to prevent markdown emphasis corruption

* fix: configure MathJax to use TeX (Computer Modern) font

* feat: enhance markdown processing with label and figure collection

* fix: remove duplicate bibliography directives from chapter summaries

References are already handled at the chapter level, so the
:bibliography: directives in summary pages are redundant and cause
rendering issues.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-12 06:21:56 +00:00
Yeqi Huang
ec03af6862 chore: update new readme (#491)
* fix: update new readme

* chore: update new readme
2026-03-11 16:26:28 +00:00
anyin233
6c9673a659 build: migrate docs build and deploy to mdbook (#490)
* build: add mdbook support for zh chapters

Add mdBook configuration rooted at zh_chapters, generate and commit SUMMARY.md, rewrite d2l-specific directives through a Python preprocessor, refresh chapter resource symlinks from the build scripts, and ignore local build-only links and helper directories.

* feat: add raw HTML inline and frontpage layout support for mdbook preprocessor

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* feat: add dark mode image background for mdbook dark themes

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix: add resource symlinks and repo root static fallback to mdbook build

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* feat: add BibTeX citation support with inline links and bibliography

Parse mlsys.bib to generate author-year inline citations linked to
per-page bibliography sections. Missing bib keys degrade gracefully
to plain text placeholders.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* refactor: switch citation display to footnote style

Use numbered superscript references [1] [2] inline with an ordered
list bibliography at page bottom. Each entry has a back-link (↩)
to the citation site.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix: strip LaTeX escapes outside math mode in mdbook preprocessor

Remove \_, \%, \#, \& escapes from text outside $...$ math spans
while preserving them inside math mode for MathJax compatibility.

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* style: set frontpage author grid to 6 columns and widen main content area

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* fix: group mdbook toc by part titles

* fix: enable inline math rendering in mdbook

* build: migrate docs publishing to mdbook

Move the English root site to mdBook, keep the Chinese site as a sub-book, and update CI/deploy to publish .mdbook outputs to docs/ and docs/cn/. Also add regression coverage for placeholder skipping, publish-tree assembly, and shared resource setup.

* ci: use official pages deployment workflow

Switch the docs deployment workflow to the official GitHub Pages actions flow and verify it uses Pages action outputs for the deployment URL.

* feat: add homepage language switch links

Inject a homepage-only language switch into the mdBook frontpage wrapper so the English homepage links to the Chinese homepage and the Chinese homepage links back to the English homepage.

* fix: correct english homepage frontpage

Add an English-specific frontpage template so the default homepage no longer falls back to the Chinese frontpage, and clear homepage image backgrounds in the frontpage wrapper CSS.

* fix: align english homepage author grid

Top-align the English homepage author cards, enlarge the row gap, and normalize avatar sizing so author portraits line up consistently.

* fix: restore dark mode body image backgrounds

Apply light gray backgrounds to body images in dark themes for both English and Chinese mdBook themes while explicitly excluding homepage frontpage images.

* fix: restyle homepage language switch button

Move the homepage language switch below the GitHub star button and restyle it to match the same button family on both the English and Chinese homepages.

* fix: center homepage content container

Align the English and Chinese homepage frontpage wrapper with the main content container so homepage content is centered like normal body content.

* fix: stack english homepage footer copy

Keep the English homepage contributor and errata footer lines in normal block flow so each sentence stays on its own line instead of being laid out as author-grid columns.

* fix: widen centered homepage container

Keep the homepage frontpage wrapper centered while ensuring it uses at least 80% of the available content area, without changing normal body page layout.

* fix: widen homepage main content area

Apply a homepage-only override so mdbook-content > main uses at least 80% of the available content width while keeping normal body pages on the default layout.

* ci: use peaceiris action for mdbook

Replace manual mdBook installation in CI and Pages workflows with peaceiris/actions-mdbook@v2 and keep a regression test to ensure the action stays in use.

* fix: reduce homepage main width floor

Lower the homepage-only mdbook-content > main minimum width from 80% to 65% while leaving normal body pages unchanged.

* build: switch math rendering to mdbook-katex

Use mdbook-katex in pre-render mode for both books, pin mdBook to a compatible version, update build scripts and workflows, and replace the old MathJax regression tests with KaTeX coverage.

* Revert "build: switch math rendering to mdbook-katex"

This reverts commit b9cf38a5d1.

* build: switch math rendering from MathJax to mdbook-typst-math

* ci: deploy docs to openmlsys.github.io repo

* fix: convert pandoc tables to GFM pipe tables for mdbook

* feat: convert :eqlabel:/:eqref: to MathJax \tag/\label/\eqref

- Add process_equation_labels() to inject \tag{n}\label{name} into
  preceding $$ equations, replacing :eqlabel: directives
- Change :eqref: conversion from backtick code to $\eqref{name}$
  for clickable cross-references
- Add TeX.equationNumbers.autoNumber:"none" to MathJax config to
  prevent conflicts with manual \tag numbering
- Add tests for single-line, multi-line, and sequential numbering

Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>

* ci: cache mdbook-typst-math binary in workflows

* feat: add LaTeX-to-Typst math converter with eqref/tag support

* feat: integrate LaTeX-to-Typst conversion into zh preprocessor

* fix: strip LaTeX escapes only outside math spans and code blocks

* fix: load references/*.bib so all citations render correctly

* fix: skip citations with no bib entry instead of rendering raw keys

* ci: remove redundant CI workflow, keep only deploy workflow

* ci: Add CI workflow for testing and building mdBook

* ci: remove concurrency settings from update_docs.yml

Removed concurrency settings from the update_docs workflow.

---------

Co-authored-by: Claude Opus 4.6 <noreply@anthropic.com>
2026-03-11 16:17:37 +00:00
Yeqi Huang
09dd269236 fix: fix ci, move url to original one (#489) 2026-03-09 21:51:04 +00:00
Yeqi Huang
085b874376 fix: fix ci (#488) 2026-03-09 18:50:47 +00:00
Yeqi Huang
f974d3e841 Split book into English and Chinese builds with framework update (#487)
* docs: split the book into English and Chinese builds

* feat: update english version framework

* fix: fix ci
2026-03-09 17:32:24 +00:00
Yiran Geng
1492ec6c41 update robot learning (#471)
Co-authored-by: Luo Mai <luo.mai.cs@gmail.com>
2024-02-18 17:49:56 +08:00
Tao191
709431fa82 Update model_inference.md (#473)
卷积计算公式错误,本次修改进行修正
2024-02-18 09:00:41 +00:00
Jiarong Han
57f6301ff9 update (#453)
Co-authored-by: Luo Mai <luo.mai.cs@gmail.com>
2023-06-08 09:56:10 +08:00
jojobugfree
004017beaa Adapt the mindspore code used in the book to the MS2.0 version (#455)
Co-authored-by: caifubi <caifubi1@huawei.com>
2023-05-10 14:16:14 +08:00
Jiarong Han
4c9dfc7d69 en-html test (#452)
* en-html test

* Update config.ini

* update

* update
2023-04-14 17:08:57 +08:00
Fan Zhang
4f4c4ffb72 Fix typo in 3.4 (#451)
* fix typo in 3.3.1

* fix typo in 3.4

---------

Co-authored-by: Cheng Lai <laicheng_VIP@163.com>
2023-04-13 16:36:41 +08:00
Fan Zhang
efc1cdabdc fix typo in 3.3.1 (#450) 2023-04-12 09:22:23 +08:00
chengtianwu
e75b7ad02b sync overleaf to git (#449) 2023-04-06 18:32:07 +08:00
Jiarong Han
e7a0ac8f58 fix ch04 (#441)
Co-authored-by: Tanzhipeng <Rudysheeppig@users.noreply.github.com>
2023-04-03 11:18:33 +08:00
Pei Mu
245bc4099f fix some reference issues (#446)
* fix some reference issues

* mis-remove of code

---------

Co-authored-by: Tanzhipeng <Rudysheeppig@users.noreply.github.com>
2023-03-31 18:49:10 +08:00
Luo Mai
5ac39809e9 Fix AllGather. (#442)
* Update collective.md

* Update overview.md

---------

Co-authored-by: Tanzhipeng <Rudysheeppig@users.noreply.github.com>
2023-03-31 18:39:08 +08:00
HaoyangLI
ff453ad396 fix image path bug in Explainable AI section (#443)
Co-authored-by: Tanzhipeng <Rudysheeppig@users.noreply.github.com>
2023-03-31 18:19:03 +08:00
zjuchujinjin
cef59fa233 fix bug for ch05 (#444)
Co-authored-by: chujinjin <chujinjin52@huawei.com>
Co-authored-by: Tanzhipeng <Rudysheeppig@users.noreply.github.com>
2023-03-31 17:40:13 +08:00
Corleone
04285985a3 fix bugs in ch06 (#447)
Co-authored-by: Corleone <liuchao195@huawei.com>
Co-authored-by: Tanzhipeng <Rudysheeppig@users.noreply.github.com>
2023-03-31 17:29:54 +08:00
hangangqiang
89a1128ed8 fix math-equal bug in deployment (#448)
Co-authored-by: hangangqiang <hangangqiang2@huawei.com>
2023-03-31 15:41:11 +08:00
Luo Mai
2d67effd58 Update ch10-computation-increase.png (#440) 2023-03-29 17:57:18 +01:00
Luo Mai
4541da5d58 Update the distributed training chapter. (#436)
* WIP: distributed.

* Update the distributed section.

* Fix line numbers.

* Update.

* Update collective.md
2023-03-29 17:26:29 +01:00
Jack
dbe4eee5b9 Update ros.md (#437)
Co-authored-by: Luo Mai <luo.mai.cs@gmail.com>
2023-03-28 13:26:18 -07:00
Yao Fu
f5c3b21e12 Yao recsys dev (#438)
* add rec system

* fix

* add new figures

* fix

* update

* fix

* fix

* fix
2023-03-29 00:28:49 +08:00
Jack
728c4b2c31 Update rl_sys_intro.md (#435) 2023-03-28 11:01:32 +08:00
Jack
1315f33568 Robotics 3.24 (#433)
* robotics 3.24

* robotics 3.24

---------

Co-authored-by: Cheng Lai <laicheng_VIP@163.com>
2023-03-27 10:57:25 +08:00
Zihan Ding
4ca2b6f698 chapter RL modified according to publisher feedback (#434)
* fix chap12 render

* add distributed rl chapter

* fix bug

* fix issue #212

* fix typo

* update imgs

* fix chinese

* fix svg img

* update contents in rl chapter

* update marl sys

* fix a fig

* fix ref

* fix error

* update rl chapter according to chinese modification

* Revert "update rl chapter according to chinese modification"

This reverts commit 413f5b679f.

* update rl chapter with chinese modification

---------

Co-authored-by: Dalong <39682259+eedalong@users.noreply.github.com>
2023-03-26 08:21:38 +08:00
zjuchujinjin
842b5f5f79 update ch05 (#432)
Co-authored-by: chujinjin <chujinjin52@huawei.com>
Co-authored-by: Jiarong Han <jiaronghan@outlook.com>
2023-03-25 14:13:50 +08:00
Corleone
66d2496e53 update chinese images for ch06 (#426)
Co-authored-by: Corleone <liuchao195@huawei.com>
Co-authored-by: Jiarong Han <jiaronghan@outlook.com>
2023-03-24 18:18:21 +08:00
hangangqiang
fcdd97397b model-deployment: sync from overleaf (#422)
Co-authored-by: hangangqiang <hangangqiang2@huawei.com>
Co-authored-by: Tanzhipeng <Rudysheeppig@users.noreply.github.com>
Co-authored-by: Jiarong Han <jiaronghan@outlook.com>
2023-03-24 17:53:45 +08:00
Tanzhipeng
fb9f14f6f7 modify chapter_preface_advanced (#429)
modify  chapter_preface_advanced

Co-authored-by: Jiarong Han <jiaronghan@outlook.com>
2023-03-24 17:45:47 +08:00
Liang ZhiBo
540a6794d3 Update frontend ir (#431)
Co-authored-by: liangzhibo <liangzhibo@huawei.com>
2023-03-24 11:44:16 +08:00
Shaoyu Wang
ec6ccd4686 fix typo (#427)
fix typo
2023-03-24 10:45:52 +08:00
Cheng Lai
3d7c502c68 Update programming model (#425) 2023-03-09 16:21:00 +08:00
Hello_World
f80e6559b0 feat(accelerator): update according to the book (#423)
* update accelerator_practise.md

* update images in accelerator_practise.md

* update images in accelerator_practise.md

* feat(accelerator): update according to the book

---------

Co-authored-by: Went-Liang <wenteng_liang@163.com>
2023-03-06 15:28:36 +08:00
machine_gun_lin
a0912ecf41 修改一个标题笔误 (#398)
Co-authored-by: Luo Mai <luo.mai.cs@gmail.com>
Co-authored-by: Jiarong Han <jiaronghan@outlook.com>
Co-authored-by: Cheng Lai <laicheng_VIP@163.com>
2023-02-17 10:26:56 +08:00
Corleone
039787dc8d sync overleaf for acceleerator (#420)
Co-authored-by: Corleone <liuchao195@huawei.com>
Co-authored-by: Jiarong Han <jiaronghan@outlook.com>
2023-02-17 10:16:44 +08:00
Jiarong Han
0c0bff1b83 new computational graph chapter (#419)
* new computational graph chapter

* Update main.yml

* Update main.yml

---------

Co-authored-by: Luo Mai <luo.mai.cs@gmail.com>
2023-02-16 19:03:17 +08:00
HLearning
15ccf2fecf update info_info.md (#405)
Co-authored-by: E00064 <jerry.huang@icleague.com>
2023-02-16 17:25:09 +08:00
Luo Mai
362b18d7f3 New Introduction Section. (#410)
* New Introduction.

* Fix comments.
2022-11-02 17:33:14 +08:00
Luo Mai
db9e392ac1 Check in new preface. (#409) 2022-11-01 23:01:22 +08:00
Jiarong Han
c5cfcd227b update frontpage (#393)
* update frontpage

* update frontpage

* update frontpage

* update frontpage
2022-11-01 18:55:44 +08:00