Repository navigation
[QRE] Distill logical T from explicit sources; fix to graph search - #4311
Open
Pooya Ronagh (pooya-git) wants to merge 1 commit into
Open
Pooya Ronagh (pooya-git) wants to merge 1 commit into
Pooya Ronagh (pooya-git) wants to merge 1 commit into
Conversation
…h search RoundBasedFactory with an explicit source: - ISATransform.source_isa_alternatives() (default: none) lists requirements that an ISA from an explicit `source` query may satisfy instead of required_isa(). They are not applied to the architecture root. - RoundBasedFactory accepts a LOGICAL T from an explicit source, so RoundBasedFactory.q(source=GSJ24Factory.q()) distills cultivated states. Before, constraint(T) is physical, so this query yielded nothing when enumerated and silently fell back to plain physical-T distillation in the graph search. - _ComponentQuery.populate matches alternatives only within the source's node range (no fallback to T states of unrelated factories) and, when they match, drops base matches that came from the fallback, so the graph and enumeration paths add the same factories. Graph-search encoding check: - source/qre/src/trace/estimation.rs: the Pareto-node filter in estimate_with_graph now checks the constraint's encoding as well as its error bound, matching InstructionConstraint::is_satisfied_by. Before, a physical T gate could stand in for a logical T state when its error fit the budget (9-Toffoli adder on GateBased 1e-4: 3,774 qubits with the raw T instead of 6,833 from the exhaustive search). Tests: - test_models.py: cultivated source is distilled (160 factories in both paths, better than cultivation alone); alternatives do not fall back. - test_estimation.py: graph and exhaustive frontiers agree on the adder and no physical T reaches the estimate. Validation: pytest tests/qre (231 passed, 4 skipped) against a release wheel built from this branch; black, rustfmt and pyright 1.1.411 clean. The explicit-source model test fails without the Python change. Co-authored-by: Copilot <223556219+Copilot@users.noreply.github.com>
Contributor
|
Pooya Ronagh (@pooya-git) please read the following Contributor License Agreement(CLA). If you agree with the CLA, please reply with the following information.
Contributor License AgreementContribution License AgreementThis Contribution License Agreement (“Agreement”) is agreed to by the party signing below (“You”),
|
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.
RoundBasedFactory with an explicit source:
sourcequery may satisfy instead of required_isa(). They are not applied to the architecture root.Graph-search encoding check:
Tests:
Validation: pytest tests/qre (231 passed, 4 skipped) against a release wheel built from this branch; black, rustfmt and pyright 1.1.411 clean. The explicit-source model test fails without the Python change.