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

Qiskit / qiskit-fermions / 40712548054
98%

Build:
DEFAULT BRANCH: main
Ran 28 Oct 2026 03:10PM UTC
Jobs 1
Files 131
Run time 1min
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

28 Oct 2026 03:06PM UTC coverage: 98.226% (+0.007%) from 98.219%
40712548054

push

github

web-flow
Refactor `QDrift` (#406)

* fix(transpiler): compare array-valued synthesis settings in MergeEvolutions

`MergeEvolutions` decides whether two neighbouring `Evolution` gates
decompose the same way by comparing `vars()` of their synthesis methods
as whole dicts. A method that holds an array, such as sampling weights,
makes that comparison raise `ValueError` ("truth value of an array is
ambiguous") instead of answering, because `dict.__eq__` calls `==` on
the values and an array has no single truth value.

Compare the settings entry by entry and use `np.array_equal` for arrays.
Gates whose arrays differ are now left unmerged, as they must be, since
merging them would pick one way of decomposing for both. Equal arrays in
distinct objects describe the same method and merge.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* refactor(circuit): make qDRIFT a fermion-to-fermion synthesis method

qDRIFT was the one Trotterization that lived outside the synthesis
framework, as a pass of its own, whereas upstream Qiskit treats it as a
product formula on an equal footing with Lie and Suzuki. Move the
sampling into `FermionicQDrift`, registered as `Evolution.QDrift,` so it
is chosen like any other method through `F2FSynthesis`.

The method is stateless: it derives the distribution from the gate it is
given and holds only num_terms, weights and rng. That is why the guard
against reusing a weights array on several gates became a per-gate
length check; a stateless method cannot count the gates it saw.

`filter_trivial` stays in `QDriftTrotterization`, now slimmed down to
what a method cannot do: tracking occupation across the whole circuit to
reject draws that cannot move a particle. It takes the method as its
argument and draws through the same sampler, so both paths share one
implementation of the protocol. Using the pass is what enables the
filtering, so the flag is gone.

Co-Authored-By: Claude Sonnet 5.5 <noreply@anthropic.com>

* feat(transpiler): m... (continued)

140 of 141 new or added lines in 5 files covered. (99.29%)

14343 of 14602 relevant lines covered (98.23%)

447619.18 hits per line

Uncovered Changes

Lines Coverage ∆ File
1
95.65
-1.57% python/qiskit_fermions/transpiler/passes/optimization/merge_evolutions.py
Jobs
ID Job ID Ran Files Coverage
1 40712548054.1 28 Oct 2026 03:10PM UTC 131
98.23
GitHub Action Run
Source Files on build 40712548054
  • Tree
  • List 131
  • Changed 3
  • Source Changed 3
  • Coverage Changed 3
Coverage ∆ File Lines Relevant Covered Missed Hits/Line
  • Back to Repo
  • Github Actions Build #40712548054
  • ecd9e28b on github
  • Prev Build on main (#40703124160)
  • Next Build on main (#40855189934)
STATUS · Troubleshooting · Open an Issue · Sales · Support · CAREERS · ENTERPRISE · START FREE TRIAL · SCHEDULE DEMO
ANNOUNCEMENTS · TWITTER · TOS & SLA · Supported CI Services · What's a CI service? · Automated Testing

© 2026 Coveralls, Inc