-
Notifications
You must be signed in to change notification settings - Fork 36
Add docs for AI decoder training with PyTorch #344
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
Merged
Merged
Conversation
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
- Add comprehensive tutorial for training neural network decoders - Demonstrate PyTorch/Stim workflow for surface code decoding - Include ONNX export and TensorRT deployment examples - Move training script to examples directory Signed-off-by: Scott Thornton <[email protected]>
Signed-off-by: Scott Thornton <[email protected]>
melody-ren
reviewed
Nov 7, 2025
melody-ren
reviewed
Nov 7, 2025
Consolidate AI decoder training documentation into decoders.rst and enhance
PyTorch installation guidance:
- Merge training_ai_decoders.rst content into decoders.rst for better
organization and discoverability
- Update terminology from "Neural Network" to "AI" decoders throughout
- Add "Optional Dependencies" section in installation guide with:
- PyTorch requirements for Tensor Network Decoder, Generative Quantum
Eigensolver (GQE), and AI decoder training
- Link to PyTorch installation page
- CUDA 12.8+ requirement note
- Add cross-reference links between installation guide and AI decoder
deployment section
- Clarify that AI decoders don't use parity check matrix (placeholder
only) in Python and C++ code examples
- Remove standalone training_ai_decoders.rst file
- Update examples.rst table of contents
These changes improve documentation clarity and help users understand
PyTorch dependencies and AI decoder workflows.
Signed-off-by: Scott Thornton <[email protected]>
Collaborator
|
@wsttiger regarding the CI failures, what is the plan? Do the CI runners need an extra package installed? If so, can you add the package to the runners as part of this PR? |
bmhowe23
reviewed
Nov 13, 2025
bmhowe23
reviewed
Nov 13, 2025
melody-ren
reviewed
Nov 13, 2025
Add comprehensive tutorial for training and deploying AI decoders with
TensorRT, along with improved PyTorch installation guidance:
Documentation changes:
- Add train_mlp_decoder.py example showing complete workflow for training
neural network decoders using PyTorch and Stim
- Update decoders.rst with AI decoder deployment documentation and
TensorRT decoder usage examples
- Add "Optional Dependencies" section in installation guide with:
- PyTorch requirements for Tensor Network Decoder (CPU only), Generative
Quantum Eigensolver (GQE), and AI decoder training
- Link to PyTorch installation page
- Note for Blackwell architecture users requiring CUDA 12.8+
- Clarify that AI decoders don't use parity check matrix (placeholder only)
in Python and C++ code examples
- Add cross-reference links between installation guide and AI decoder section
CI/CD changes:
- Update GitHub Actions workflows to support new documentation examples
- Modify all_libs.yaml, all_libs_release.yaml, lib_qec.yaml, and
lib_solvers.yaml for proper build integration
These changes provide users with a complete guide for training custom AI
decoders and deploying them with optimized TensorRT inference.
Signed-off-by: Scott Thornton <[email protected]>
Signed-off-by: Scott Thornton <[email protected]>
Collaborator
Author
|
/ok to test 3e3ecc1 |
Signed-off-by: Scott Thornton <[email protected]>
…nto train_trt_decoder_docs Signed-off-by: Scott Thornton <[email protected]>
Signed-off-by: Scott Thornton <[email protected]>
…ion page Signed-off-by: Scott Thornton <[email protected]>
bmhowe23
requested changes
Nov 17, 2025
Signed-off-by: Scott Thornton <[email protected]>
bmhowe23
approved these changes
Nov 18, 2025
Collaborator
|
Approved, but let's hold off on merging until the release is done. |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Add TensorRT Decoder Training Tutorial
Overview
This PR introduces comprehensive documentation for training and deploying neural network-based quantum error correction decoders using the TensorRT decoder plugin (
trt_decoder), which is being released with CUDA-Q QEC v0.5.0.Motivation
With the release of the TensorRT decoder, users need clear guidance on:
This tutorial provides an end-to-end workflow demonstrating the complete pipeline from data generation to production deployment.
Changes Made
New Documentation
training_ai_decoders.rst: Comprehensive tutorial covering:trtexecTraining Script
train_mlp_decoder.py: Complete working example demonstrating:docs/sphinx/examples/qec/python/Documentation Updates
examples.rst: Added new tutorial to QEC examples table of contentsdecoders.rst: Minor formatting cleanupTutorial Features
Target Audience
Testing
The training script has been tested and successfully:
Related Components: