diff --git a/.spellcheck.yaml b/.spellcheck.yaml index b2ac3791..64bd71ba 100644 --- a/.spellcheck.yaml +++ b/.spellcheck.yaml @@ -33,7 +33,7 @@ matrix: - name: Markdown sources: - - 'docs/**/*.md' + - ['docs/**/*.md', '!docs/doxygen/mainpage.md'] expect_match: false aspell: lang: en @@ -105,8 +105,6 @@ matrix: close: '\n' - open: '(- )?(?P`+)' close: '(?P=open)' - - open: ':figure:.*' - close: '\n' # Ignore reStructuredText roles - open: ':(?:(class|file|func|math|ref|octicon|meth|obj)):`' content: '[^`]*' @@ -148,7 +146,7 @@ matrix: - open: '\.\.\s+toctree::' close: '(?P(?:((?P[ ]+).*$)|(\n))+)' # Ignore directives - - open: '\.\.\s+(image|include|only|tabularcolumns|datatemplate:nodata)::' + - open: '\.\.\s+(figure|image|include|only|tabularcolumns|datatemplate:nodata)::' close: '$' # Ignore reStructuredText reference - open: '^.{2}[ ]+_' @@ -157,6 +155,10 @@ matrix: - open: '\.\. (autodoxygenindex|doxygenfunction|doxygenstruct|doxygenclass|doxygennamespace|doxygenconcept|doxygenenum|doxygenenumvalue|doxygentypedef|doxygenunion|doxygendefine|doxygenvariable|doxygenfile|doxygengroup|autodoxygenfile|doxygenpage)::.*$\n*' content: '(?P(^(?P[ ]+).*$\n))(?P(^([ \t]+.*|[ \t]*)$\n)*)' close: '(^(?![ \t]+.*$))' + # Ignore doxygen one line directives + - open: '\.\. (autodoxygenindex|doxygenfunction|doxygenstruct|doxygenclass|doxygennamespace|doxygenconcept|doxygenenum|doxygenenumvalue|doxygentypedef|doxygenunion|doxygendefine|doxygenvariable|doxygenfile|doxygengroup|autodoxygenfile|doxygenpage)::' + content: '[ \S]*' + close: '\n' # Manual disabling via: #spellcheck-disable - open : '^.. $' content: '[\s\S]*?' diff --git a/.wordlist.txt b/.wordlist.txt index e2368e54..bbf90c3b 100644 --- a/.wordlist.txt +++ b/.wordlist.txt @@ -15,9 +15,12 @@ ASICs ASan ASm ATI +AWQ +AdaLoRA AddressSanitizer AlexNet Arb +AutoGPTQ BLAS BMC BitCode @@ -56,9 +59,11 @@ CommonMark Concretized Conda ConnectX +DDP DGEMM DKMS DL +DLM DMA DNN DNNL @@ -73,7 +78,9 @@ DataParallel DeepSpeed Dependabot DevCap +Diffusers Dockerfile +Dockerfiles Doxygen ELMo ENDPGM @@ -86,6 +93,7 @@ FFmpeg FHS FMA FP +FSDP Filesystem Flang Fortran @@ -108,9 +116,11 @@ GMI GPG GPR GPT +GPTQ GPU GPU's GPUs +GQA GRBM GenAI GenZ @@ -165,21 +175,26 @@ LLMs LLVM LM LSAN +LSTM LTS +LinearReLU LoRA MEM MERCHANTABILITY MFMA +MHA MIGraphX MIOpen MIOpenGEMM MIVisionX MLM +MLP MMA MMIO MMIOH MNIST MPI +MQA MSVC MVAPICH MVFFR @@ -191,6 +206,7 @@ Mellanox Mellanox's Meta's MirroredStrategy +MoE Multicore Multithreaded MyEnvironment @@ -224,6 +240,9 @@ OMPX ONNX OSS OSU +Omniperf +Omnitrace +OpenAI OpenCL OpenCV OpenFabrics @@ -236,6 +255,7 @@ PCIe PEFT PIL PILImage +PPO PRNG PRs PaLM @@ -247,6 +267,7 @@ PnP PowerShell PyPi PyTorch +QLoRA Qcycles RAII RCCL @@ -254,6 +275,7 @@ RDC RDMA RDNA RHEL +RNN ROC ROCProfiler ROCTracer @@ -266,9 +288,11 @@ ROCmCC ROCmSoftwarePlatform ROCmValidationSuite ROCr +RPC RST RW Radeon +ReLU RelWithDebInfo Req Rickle @@ -281,6 +305,7 @@ SDK SDMA SDRAM SENDMSG +SFT SGPR SGPRs SHA @@ -299,11 +324,14 @@ SRAM SRAMECC SVD SWE +SciPy SerDes Shlens Skylake +SmoothQuant Softmax Spack +StarCoder Supermicro Szegedy TCA @@ -313,19 +341,27 @@ TCIU TCP TCR TFLOPS +TGI +TPOT TPU TPUs +TRL +TTFT +Templated TensorBoard TensorFlow TensorParallel ToC TorchAudio +TorchInductor TorchMIGraphX TorchScript TorchServe TorchVision TransferBench TrapStatus +Tunable +TunableOp UAC UC UCC @@ -355,6 +391,7 @@ WikiText Wojna Workgroups Writebacks +XDL XGBoost XGBoost's XGMI @@ -381,10 +418,13 @@ api atmi atomics autogenerated +autoregression +autoregressive avx awk backend backends +backpropagation benchmarking bilinear bitsandbytes @@ -400,9 +440,12 @@ centos centric changelog chiplet +ckProfiler cmake cmd coalescable +codebase +codebases codename collater comgr @@ -442,6 +485,7 @@ dimensionality disambiguates distro doxysphinx +dropdown el embeddings enablement @@ -497,10 +541,12 @@ init initializer inlining installable +instantiation interprocedural intra invariants invocating +invoker ipo kdb libfabric @@ -526,6 +572,7 @@ mtypes mvffr namespace namespaces +natively numref ocl opencl @@ -544,6 +591,7 @@ perl pragma pre prebuilt +precisions precompiled prefetch prefetchable @@ -556,6 +604,8 @@ profiler protobuf pseudorandom py +quantized +quantizing quasirandom queueing rccl @@ -605,6 +655,7 @@ scalable sendmsg serializers shader +sharded sharding sigmoid sm @@ -614,6 +665,7 @@ spack src stochastically strided +struct subdirectory subexpression subfolder @@ -632,6 +684,7 @@ toolsets torchvision tqdm tracebacks +tunable txt uarch unallocated @@ -643,9 +696,11 @@ unstacking unswitching untrusted untuned +upstreamed upvote utils vL +vLLM variational vdi vectorizable @@ -666,8 +721,9 @@ writeback writebacks wrreq wzo +xFormers xargs xz yaml ysvmadyb -zypper +zyppe diff --git a/CHANGELOG.md b/CHANGELOG.md index abb204d0..74e042ba 100644 --- a/CHANGELOG.md +++ b/CHANGELOG.md @@ -1,3 +1,28 @@ +## v1.2.0 (2024-05-27) + +### Feat + +- **projects.yaml**: Add rocr_debug_agent to projects.yaml + +## v1.1.3 (2024-05-22) + +### Fix + +- Get header version from URL instead of theme.conf + +### Refactor + +- **projects.py**: Use ROCm org when checking versions for banner +- **theme.py**: Point to ROCm org instead of RadeonOpenCompute for rocm-docs-core + +## v1.1.2 (2024-05-16) + +### Fix + +- **projects.yaml**: add rocr-runtime +- **custom.css**: add bottom margin to images in rst files +- **404.html**: Remove relative link in 404.html page + ## v1.1.1 (2024-04-26) ### Fix diff --git a/docs/conf.py b/docs/conf.py index 9866176e..b1ec11c0 100644 --- a/docs/conf.py +++ b/docs/conf.py @@ -37,8 +37,8 @@ "path": "demo/doxygen/xml", } -version = "1.1.1" -release = "1.1.1" +version = "1.2.0" +release = "1.2.0" html_title = f"ROCm Docs Core {version}" project = "ROCm Docs Core" author = "Advanced Micro Devices, Inc." diff --git a/pyproject.toml b/pyproject.toml index f23dc7bf..ed7b3581 100644 --- a/pyproject.toml +++ b/pyproject.toml @@ -7,7 +7,7 @@ build-backend = "setuptools.build_meta" [project] name = 'rocm-docs-core' -version = "1.1.1" +version = "1.2.0" authors=[ {name="Lauren Wrubleski", email="Lauren.Wrubleski@amd.com"} ] @@ -72,7 +72,7 @@ color = true [tool.commitizen] name = "cz_conventional_commits" -version = "1.1.1" +version = "1.2.0" version_files = ["pyproject.toml:^version", "docs/conf.py:^(version|release)"] tag_format = "v$version" annotated_tag = true diff --git a/requirements.txt b/requirements.txt index a4700312..c34c0dac 100644 --- a/requirements.txt +++ b/requirements.txt @@ -4,13 +4,13 @@ # # pip-compile --all-extras pyproject.toml # -accessible-pygments==0.0.4 +accessible-pygments==0.0.5 # via pydata-sphinx-theme alabaster==0.7.16 # via sphinx argcomplete==3.3.0 # via commitizen -babel==2.14.0 +babel==2.15.0 # via # pydata-sphinx-theme # sphinx @@ -47,11 +47,11 @@ click-log==0.4.0 # via doxysphinx colorama==0.4.6 # via commitizen -commitizen==3.24.0 +commitizen==3.26.0 # via rocm-docs-core (pyproject.toml) -cryptography==42.0.5 +cryptography==42.0.7 # via pyjwt -decli==0.6.1 +decli==0.6.2 # via commitizen deprecated==1.2.14 # via pygithub @@ -63,13 +63,13 @@ docutils==0.21.2 # myst-parser # pydata-sphinx-theme # sphinx -doxysphinx==3.3.7 +doxysphinx==3.3.8 # via rocm-docs-core (pyproject.toml) exceptiongroup==1.2.1 # via pytest fastjsonschema==2.19.1 # via rocm-docs-core (pyproject.toml) -filelock==3.13.4 +filelock==3.14.0 # via virtualenv gitdb==4.0.11 # via gitpython @@ -87,7 +87,7 @@ iniconfig==2.0.0 # via pytest isort==5.13.2 # via rocm-docs-core (pyproject.toml) -jinja2==3.1.3 +jinja2==3.1.4 # via # commitizen # myst-parser @@ -102,11 +102,11 @@ markdown-it-py==3.0.0 # myst-parser markupsafe==2.1.5 # via jinja2 -mdit-py-plugins==0.4.0 +mdit-py-plugins==0.4.1 # via myst-parser mdurl==0.1.2 # via markdown-it-py -mpire==2.10.1 +mpire==2.10.2 # via doxysphinx mypy==1.10.0 # via rocm-docs-core (pyproject.toml) @@ -114,7 +114,7 @@ mypy-extensions==1.0.0 # via # black # mypy -myst-parser==3.0.0 +myst-parser==3.0.1 # via rocm-docs-core (pyproject.toml) nodeenv==1.8.0 # via pre-commit @@ -130,13 +130,13 @@ pathspec==0.12.1 # via black pip-tools==7.4.1 # via rocm-docs-core (pyproject.toml) -platformdirs==4.2.1 +platformdirs==4.2.2 # via # black # virtualenv pluggy==1.5.0 # via pytest -pre-commit==3.7.0 +pre-commit==3.7.1 # via rocm-docs-core (pyproject.toml) prompt-toolkit==3.0.36 # via questionary @@ -148,7 +148,7 @@ pydata-sphinx-theme==0.15.2 # sphinx-book-theme pygithub==2.3.0 # via rocm-docs-core (pyproject.toml) -pygments==2.17.2 +pygments==2.18.0 # via # accessible-pygments # mpire @@ -164,11 +164,11 @@ pyparsing==3.1.2 # via # doxysphinx # sphinxcontrib-doxylink -pyproject-hooks==1.0.0 +pyproject-hooks==1.1.0 # via # build # pip-tools -pytest==8.1.2 +pytest==8.2.1 # via rocm-docs-core (pyproject.toml) python-dateutil==2.9.0.post0 # via sphinxcontrib-doxylink @@ -181,11 +181,11 @@ pyyaml==6.0.1 # sphinx-external-toc questionary==2.0.1 # via commitizen -requests==2.31.0 +requests==2.32.0 # via # pygithub # sphinx -ruff==0.4.2 +ruff==0.4.5 # via rocm-docs-core (pyproject.toml) six==1.16.0 # via python-dateutil @@ -211,11 +211,11 @@ sphinx-book-theme==1.1.2 # via rocm-docs-core (pyproject.toml) sphinx-copybutton==0.5.2 # via rocm-docs-core (pyproject.toml) -sphinx-design==0.5.0 +sphinx-design==0.6.0 # via rocm-docs-core (pyproject.toml) sphinx-external-toc==1.0.1 # via rocm-docs-core (pyproject.toml) -sphinx-notfound-page==1.0.0 +sphinx-notfound-page==1.0.2 # via rocm-docs-core (pyproject.toml) sphinxcontrib-applehelp==1.0.8 # via sphinx @@ -242,11 +242,11 @@ tomli==2.0.1 # pyproject-hooks # pytest # sphinx -tomlkit==0.12.4 +tomlkit==0.12.5 # via commitizen -tqdm==4.66.2 +tqdm==4.66.4 # via mpire -typing-extensions==4.11.0 +typing-extensions==4.12.0 # via # black # mypy @@ -256,7 +256,7 @@ urllib3==2.2.1 # via # pygithub # requests -virtualenv==20.26.0 +virtualenv==20.26.2 # via pre-commit wcwidth==0.2.13 # via prompt-toolkit @@ -264,7 +264,7 @@ wheel==0.43.0 # via pip-tools wrapt==1.16.0 # via deprecated -zipp==3.18.1 +zipp==3.19.0 # via importlib-metadata # The following packages are considered to be unsafe in a requirements file: diff --git a/src/rocm_docs/data/projects.yaml b/src/rocm_docs/data/projects.yaml index ef202f8b..b7831437 100644 --- a/src/rocm_docs/data/projects.yaml +++ b/src/rocm_docs/data/projects.yaml @@ -68,6 +68,12 @@ projects: target: https://rocm.docs.amd.com/projects/rocprofiler/en/${version} development_branch: amd-master rocrand: https://rocm.docs.amd.com/projects/rocRAND/en/${version} + rocr-runtime: + target: https://rocm.docs.amd.com/projects/ROCR-Runtime/en/${version} + development_branch: master + rocr_debug_agent: + target: https://rocm.docs.amd.com/projects/rocr_debug_agent/en/${version} + development_branch: master rocsolver: https://rocm.docs.amd.com/projects/rocSOLVER/en/${version} rocsparse: https://rocm.docs.amd.com/projects/rocSPARSE/en/${version} rocthrust: https://rocm.docs.amd.com/projects/rocThrust/en/${version} diff --git a/src/rocm_docs/projects.py b/src/rocm_docs/projects.py index 482c6afb..6c073135 100644 --- a/src/rocm_docs/projects.py +++ b/src/rocm_docs/projects.py @@ -324,11 +324,11 @@ def _update_theme_configs( ) -> None: """Update configurations for use in theme.py""" latest_version = requests.get( - "https://raw.githubusercontent.com/RadeonOpenCompute/rocm-docs-core/header-versions/latest_version.txt" + "https://raw.githubusercontent.com/ROCm/rocm-docs-core/header-versions/latest_version.txt" ).text.strip("\r\n") latest_version_string = f"docs-{latest_version}" release_candidate = requests.get( - "https://raw.githubusercontent.com/RadeonOpenCompute/rocm-docs-core/header-versions/release_candidate.txt" + "https://raw.githubusercontent.com/ROCm/rocm-docs-core/header-versions/release_candidate.txt" ).text.strip("\r\n") release_candidate_string = f"docs-{release_candidate}" diff --git a/src/rocm_docs/rocm_docs_theme/404.html b/src/rocm_docs/rocm_docs_theme/404.html index 69da00c2..82eca212 100644 --- a/src/rocm_docs/rocm_docs_theme/404.html +++ b/src/rocm_docs/rocm_docs_theme/404.html @@ -1,5 +1,5 @@ {%- extends "page.html" %} {% block body %}

404 - Page Not Found

-

Return home or use the sidebar navigation to get back on track.

+

Use the navigation bar on the side to get back on track.

{% endblock %} diff --git a/src/rocm_docs/rocm_docs_theme/sections/header.html b/src/rocm_docs/rocm_docs_theme/sections/header.html index bdb862c7..7b5c0b31 100644 --- a/src/rocm_docs/rocm_docs_theme/sections/header.html +++ b/src/rocm_docs/rocm_docs_theme/sections/header.html @@ -19,7 +19,11 @@ AMD Logo
- {{ top_level_header(theme_repository_branch | replace("docs-", ""), theme_header_latest_version, theme_header_release_candidate_version) }} + {{ top_level_header( + theme_repository_branch | replace("docs-", ""), + header_latest_version, + header_release_candidate_version + ) }} {{ version_list() }}
diff --git a/src/rocm_docs/rocm_docs_theme/static/custom.css b/src/rocm_docs/rocm_docs_theme/static/custom.css index a2f40c08..a9b18b24 100644 --- a/src/rocm_docs/rocm_docs_theme/static/custom.css +++ b/src/rocm_docs/rocm_docs_theme/static/custom.css @@ -220,3 +220,7 @@ a#ot-sdk-btn { .bd-sidebar-secondary { z-index: 10001; } + +:not(p) img { + margin-bottom: 1rem; +} diff --git a/src/rocm_docs/rocm_docs_theme/theme.conf b/src/rocm_docs/rocm_docs_theme/theme.conf index 92e883ce..13635ec0 100644 --- a/src/rocm_docs/rocm_docs_theme/theme.conf +++ b/src/rocm_docs/rocm_docs_theme/theme.conf @@ -9,6 +9,3 @@ show_toc_level = 1 flavor = rocm link_main_doc = True - -header_latest_version = 6.1.1 -header_release_candidate_version = 6.2.0 diff --git a/src/rocm_docs/theme.py b/src/rocm_docs/theme.py index 2c22bdab..f8ad196c 100644 --- a/src/rocm_docs/theme.py +++ b/src/rocm_docs/theme.py @@ -17,6 +17,36 @@ logger = sphinx.util.logging.getLogger(__name__) +def _get_version_from_url(url: str) -> str: + try: + response = requests.get(url) + return response.text.strip() + except requests.RequestException as e: + print(f"Error in rocm-docs-core _get_version_from_url: {e}") + return "" + + +def _add_custom_context( + app: Sphinx, # noqa: ARG001 + pagename: str, # noqa: ARG001 + templatename: str, # noqa: ARG001 + context: dict[str, str], + doctree: object, # noqa: ARG001 +) -> None: + header_latest_version = _get_version_from_url( + "https://raw.githubusercontent.com/ROCm/rocm-docs-core/header-versions/latest_version.txt" + ) + + header_release_candidate_version = _get_version_from_url( + "https://raw.githubusercontent.com/ROCm/rocm-docs-core/header-versions/release_candidate.txt" + ) + + context["header_latest_version"] = header_latest_version + context["header_release_candidate_version"] = ( + header_release_candidate_version + ) + + def _update_repo_opts(srcdir: str, theme_opts: dict[str, Any]) -> None: default_branch_options: dict[str, Any] = { "use_edit_page_button": False, @@ -88,12 +118,13 @@ def _update_theme_options(app: Sphinx) -> None: 0, "components/left-side-menu" ) - header_latest_version = requests.get( + header_latest_version = _get_version_from_url( "https://raw.githubusercontent.com/RadeonOpenCompute/rocm-docs-core/header-versions/latest_version.txt" - ).text.strip("\r\n") - header_release_candidate_version = requests.get( + ) + + header_release_candidate_version = _get_version_from_url( "https://raw.githubusercontent.com/RadeonOpenCompute/rocm-docs-core/header-versions/release_candidate.txt" - ).text.strip("\r\n") + ) default_config_opts = { "html_show_sphinx": False, @@ -101,8 +132,8 @@ def _update_theme_options(app: Sphinx) -> None: "notfound_context": {"title": "404 - Page Not Found"}, "notfound_template": "404.html", "html_context": { - "theme_header_latest_version": header_latest_version, - "theme_header_release_candidate_version": header_release_candidate_version, + "header_latest_version": header_latest_version, + "header_release_candidate_version": header_release_candidate_version, }, } for key, default in default_config_opts.items(): @@ -132,6 +163,7 @@ def setup(app: Sphinx) -> dict[str, Any]: ]: app.add_css_file(css) + app.connect("html-page-context", _add_custom_context) app.connect("builder-inited", _update_theme_options) return {