pub struct DetectorErrorModel { /* private fields */ }Implementations§
Source§impl DetectorErrorModel
impl DetectorErrorModel
pub fn new() -> Self
pub fn from_dem_text(text: &str) -> Result<Self, Exception>
pub fn diagram(&self, type_name: &str) -> Result<String, Exception>
pub fn add(&self, other: &Self) -> Self
pub fn add_assign(&mut self, other: &Self)
pub fn repeat(&self, repetitions: u64) -> Self
pub fn repeat_assign(&mut self, repetitions: u64)
pub fn to_dem_text(&self) -> String
pub fn len(&self) -> usize
pub fn top_level_item(&self, index: usize) -> DemTopLevelItemData
pub fn top_level_repeat_block_body(&self, index: usize) -> Self
pub fn get_slice(&self, start: i64, step: i64, slice_length: i64) -> Self
pub fn is_empty(&self) -> bool
pub fn num_detectors(&self) -> u64
pub fn num_errors(&self) -> u64
pub fn num_observables(&self) -> u64
pub fn get_detector_coordinates( &self, included_detector_indices: &[u64], ) -> Result<Vec<CoordinateEntryData>, Exception>
pub fn clear(&mut self)
pub fn approx_equals(&self, other: &Self, atol: f64) -> bool
pub fn equals(&self, other: &Self) -> bool
pub fn flattened(&self) -> Self
pub fn rounded(&self, digits: u8) -> Self
pub fn append_instruction( &mut self, instruction_type: &str, args: &[f64], targets: &[u64], tag: &str, ) -> Result<(), Exception>
pub fn append_repeat_block( &mut self, repeat_count: u64, body: &Self, ) -> Result<(), Exception>
pub fn compile_sampler(&self) -> DemSampler
pub fn compile_sampler_with_seed(&self, seed: u64) -> DemSampler
pub fn shortest_graphlike_error( &self, ignore_ungraphlike_errors: bool, ) -> Result<Self, Exception>
pub fn shortest_error_sat_problem( &self, format_name: &str, ) -> Result<String, Exception>
pub fn likeliest_error_sat_problem( &self, quantization: i32, format_name: &str, ) -> Result<String, Exception>
Trait Implementations§
Source§impl Clone for DetectorErrorModel
impl Clone for DetectorErrorModel
Auto Trait Implementations§
impl Freeze for DetectorErrorModel
impl RefUnwindSafe for DetectorErrorModel
impl !Send for DetectorErrorModel
impl !Sync for DetectorErrorModel
impl Unpin for DetectorErrorModel
impl UnsafeUnpin for DetectorErrorModel
impl UnwindSafe for DetectorErrorModel
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