Skip to content

Port the structured idle-noise families to the native-surface NoiseModel (twirl/threshold route) #422

Description

@ciaranra

Goal

Port the structured idle-noise interface (PR #420: p_idle_linear/p_idle_linear_model,
p_idle_sin_squared/p_idle_sin_squared_model, p_idle_coherent/p_idle_coherent_model,
relative-rate multiplier semantics, symmetric defaults, first-class L key) to the
native-surface noise surface used by the twirl and threshold pipelines, so both routes share
one vocabulary and one set of fail-loud rules.

Current state

  • pecos.qec.surface.decode.NoiseModel exposes only the legacy idle fields (p_idle,
    T1/T2, per-axis rates, bare Z-only aliases) and forwards them directly to the Rust
    DemBuilder.with_noise (python/quantum-pecos/src/pecos/qec/surface/decode.py).
  • The Pauli-twirl handoff route builds DEMs exclusively through that surface, so it never
    sees the structured families, the ambiguity/clobber conflicts, or the deprecation
    warnings for the bare aliases (tests/qec/surface/test_pauli_twirl_handoff.py exercised
    them until the alias migration on PR Align idle-noise vocabulary across DEM, engines and neo, and emit the requested Pauli channel #420's branch).
  • generate_dem_from_tick_circuit and the pure-Python Pauli-frame DEM builder are likewise
    legacy-only surfaces (python/quantum-pecos/src/pecos/qec/surface/circuit_builder.py).

Work

  • Reuse the shared translator from pecos/qec/dem.py (_translate_structured_idle_noise
    and the family/model validator) rather than duplicating semantics; one implementation,
    two consumers.
  • Same conflict, deprecation, and rejection behavior as the Guppy entry points, including
    rejecting nonzero coherent rates on the standard DEM route.
  • Decide the fate of NoiseModel.p_idle consistently with the Guppy surface (the shorthand
    was removed there in favor of explicit p_idle_linear).

Consistency principle

This is one step of a broader goal: identical idle-noise semantics at every level that
accepts noise parameters, including below the public API (the Rust from_circuit binding's
idle_rz currently accepts a coherent angle and silently stores its Pauli twirl, while the
Guppy surface rejects requested coherence loudly — that split should eventually close in
the same direction).

Metadata

Metadata

Assignees

No one assigned

    Labels

    enhancementNew feature or requestpythonPull requests that update python code

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions