Repository navigation
Conversation
Signed-off-by: Scott Thornton <wsttiger@gmail.com>
…ELECT
The QROM SELECT undid the programmable spatial network with
cudaq.adjoint, which the CUDA-Q runtime refuses for a kernel that calls
cudaq.control inside a loop ("could not autogenerate the adjoint of a
kernel"), so the H2 driver and every QROM-backend kernel failed to
execute on CUDA-Q 0.15.1. programmable_spatial_givens_adjoint is the
hand-written inverse (slots in reverse order, negated weights), the
same convention as the arithmetic primitives, and the angle words are
erased by a second lookup, which the QROM contract documents as exactly
self-inverse. User-facing text states what the backends are rather
than how they relate to earlier versions.
The 11 QROM tests pass on CUDA-Q 0.15.1 and 0.16.0; the H2 driver runs
both backends with all checks passing.
Signed-off-by: Scott Thornton <wsttiger@gmail.com>
This branch has not been deployed
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
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.
The double-factorized example currently sweeps through classical orbital frames. Add an optional QROM backend that coherently loads one real spatial frame from the term index, applies programmable inverse/forward Givens networks around the signed Z word, and uncomputes angle/ladder workspace. The fixed backend remains the class default; the molecular driver defaults to comparing both.
Preserves the exact flat coefficient PREPARE, retained terms, scalar offsets, compressed dense-core support, and all BlockEncoding consumers. Documents index-bit reversal, two-spin rotation conventions, complete-ancilla reflections, resource widths, and independent ideal/represented error budgets. This implements the requested angle-loading mechanism; it does not reproduce the papers' nested DF algorithms or optimized fault-tolerant costs.
This PR targets main independently of plan 09 / PR #90 and PR #78. No library or dependency changes.
Validation on Python 3.12.3 / CUDA-Q 0.16.0.post1, fp64 qpp-cpu:
The driver retains fixed-backend moments, adds a host-only b=4/6/8 precision sweep, and labels larger QROM cases as resource-only. H2 happens to be on-grid; the synthetic regression deliberately exercises nonzero rounding error. Full wheel/GPU CI is separate from these focused checks.