pub struct ParallelFusionDecoder {
pub adaptor: Arc<FusionBlossomAdaptor>,
pub fusion_solver: SolverParallel,
pub config: ParallelFusionDecoderConfig,
}Expand description
MWPM decoder based on fusion blossom algorithm, initialized and cloned for multiple threads
Fields§
§adaptor: Arc<FusionBlossomAdaptor>shared data helps interface with the fusion blossom algorithm
fusion_solver: SolverParallelfusion blossom algorithm: a fast MWPM solver for quantum error correction
config: ParallelFusionDecoderConfigsave configuration for later usage
Implementations§
Source§impl ParallelFusionDecoder
impl ParallelFusionDecoder
Sourcepub fn new(
simulator: &Simulator,
noise_model: Arc<NoiseModel>,
decoder_configuration: &Value,
parallel: usize,
use_brief_edge: bool,
) -> Self
pub fn new( simulator: &Simulator, noise_model: Arc<NoiseModel>, decoder_configuration: &Value, parallel: usize, use_brief_edge: bool, ) -> Self
create a new MWPM decoder with decoder configuration
Sourcepub fn decode(
&mut self,
sparse_measurement: &SparseMeasurement,
) -> (SparseCorrection, Value)
pub fn decode( &mut self, sparse_measurement: &SparseMeasurement, ) -> (SparseCorrection, Value)
decode given measurement results
Sourcepub fn decode_with_erasure(
&mut self,
sparse_measurement: &SparseMeasurement,
sparse_detected_erasures: &SparseErasures,
) -> (SparseCorrection, Value)
pub fn decode_with_erasure( &mut self, sparse_measurement: &SparseMeasurement, sparse_detected_erasures: &SparseErasures, ) -> (SparseCorrection, Value)
decode given measurement results and detected erasures
Trait Implementations§
Source§impl Clone for ParallelFusionDecoder
impl Clone for ParallelFusionDecoder
Source§impl Debug for ParallelFusionDecoder
impl Debug for ParallelFusionDecoder
Auto Trait Implementations§
impl !RefUnwindSafe for ParallelFusionDecoder
impl !UnwindSafe for ParallelFusionDecoder
impl Freeze for ParallelFusionDecoder
impl Send for ParallelFusionDecoder
impl Sync for ParallelFusionDecoder
impl Unpin for ParallelFusionDecoder
impl UnsafeUnpin for ParallelFusionDecoder
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more
impl<ST, DT> CastableFrom<ST, Initialized, Initialized> for DT
impl<ST, DT> CastableFrom<ST, Uninit, Uninit> for DT
Source§impl<T> CloneToUninit for Twhere
T: Clone,
impl<T> CloneToUninit for Twhere
T: Clone,
Source§impl<T> Instrument for T
impl<T> Instrument for T
Source§fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
fn instrument(self, span: Span) -> Instrumented<Self> ⓘ
Source§fn in_current_span(self) -> Instrumented<Self> ⓘ
fn in_current_span(self) -> Instrumented<Self> ⓘ
Source§impl<T> IntoEither for T
impl<T> IntoEither for T
Source§fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
fn into_either(self, into_left: bool) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left is true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read moreSource§fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
fn into_either_with<F>(self, into_left: F) -> Either<Self, Self> ⓘ
Converts
self into a Left variant of Either<Self, Self>
if into_left(&self) returns true.
Converts self into a Right variant of Either<Self, Self>
otherwise. Read more