• Home
  • Features
  • Pricing
  • Docs
  • Announcements
  • Sign In

Qiskit / qiskit / 16834979106
88%
main: 88%

Build:
Build:
LAST BUILD BRANCH: add-pauli-accessor-15468
DEFAULT BRANCH: main
Ran 08 Aug 2025 04:43PM UTC
Jobs 1
Files 836
Run time 2min
Badge
Embed ▾
README BADGES
x

If you need to use a raster PNG badge, change the '.svg' to '.png' in the link

Markdown

Textile

RDoc

HTML

Rst

08 Aug 2025 04:04PM UTC coverage: 87.665%. Remained the same
16834979106

push

github

web-flow
Add Python free path to inverse_cancellation (#14803)

* Add Python free path to inverse_cancellation

This commit adds a Python free path to the inverse cancellation
transpiler pass. Previously, the only way to run the pass required Python
because the pass handles arbitrary gates to cancel which can include
custom gates from Python. This meant to validate the gates were equal we
would need the Python interpreter. This commit opts to add a new
entrypoint for Rust as working under the constraints that we're only
having StandardGates can lead to a more efficient implementation.
Additionally, for the preset pass managers we always used the same fixed
set of standard gates which don't take parameters to cancel. Since the
initial goal of the C API is to expose the preset pass managers this new
entrypoint only uses this set which simplifies the checking necessary.
This provides an optimized path for the preset pass managers too. For the
standalone C function in #14444 we don't need to make the pass
configurable. If we decide eventually to expand this it is trivial to add
an updated entrypoint, but for the first MVP it's not necessary.

Since this new entrypoint is also more efficient for the use case of the
preset pass managers the Python side pass is updated to use it in the
default case. This enables the preset pass managers to run the pass
faster.

Related to #14444

* Fix copy paste error in inverse pair path

The inverse pair path was incorrectly checking the same gate twice
instead of the gate and the next one in a run. This was just a copy and
paste error where code was supposed to operate on n and n+1 but it was
doing n twice. This commit fixes this and expands the testing to ensure
we have direct coverage of the new code path instead of relying on the
transpiler tests testing indirectly.

* Apply suggestions from code review

Co-authored-by: Alexander Ivrii <alexi@il.ibm.com>

* Rename collect_1q_runs_by() -> collect_runs_by()

* Fix short circuit ... (continued)

125 of 132 new or added lines in 3 files covered. (94.7%)

19 existing lines in 3 files now uncovered.

82309 of 93890 relevant lines covered (87.67%)

546221.33 hits per line

New Missed Lines in Diff

Lines Coverage ∆ File
1
85.49
0.02% crates/circuit/src/dag_circuit.rs
2
95.12
1.0% qiskit/transpiler/passes/optimization/inverse_cancellation.py
4
95.54
0.01% crates/transpiler/src/passes/inverse_cancellation.rs

Uncovered Existing Lines

Lines Coverage ∆ File
1
83.39
0.0% crates/circuit/src/parameter/parameter_expression.rs
6
92.01
-0.77% crates/qasm2/src/lex.rs
12
96.62
-0.94% crates/qasm2/src/parse.rs
Jobs
ID Job ID Ran Files Coverage
1 16834979106.1 08 Aug 2025 04:43PM UTC 836
87.67
GitHub Action Run
Source Files on build 16834979106
  • Tree
  • List 836
  • Changed 10
  • Source Changed 4
  • Coverage Changed 10
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #16834979106
  • 7d91c500 on github
  • Prev Build on gh-readonly-queue/main/pr-14843-dee38aaa75efcbdca5c0ccf36c46a8b627dd4187 (#16830026850)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2025 Coveralls, Inc