pub struct DeviceTranspiler { /* private fields */ }Expand description
Enhanced device-specific transpiler with SciRS2 graph optimization
Implementations§
Source§impl DeviceTranspiler
impl DeviceTranspiler
Sourcepub fn new_with_scirs2_optimization() -> Self
pub fn new_with_scirs2_optimization() -> Self
Create a new device transpiler with SciRS2 optimization enabled
Sourcepub fn optimize_layout_scirs2<const N: usize>(
&self,
circuit: &Circuit<N>,
hardware_spec: &HardwareSpec,
strategy: &GraphOptimizationStrategy,
) -> QuantRS2Result<HashMap<QubitId, usize>>
pub fn optimize_layout_scirs2<const N: usize>( &self, circuit: &Circuit<N>, hardware_spec: &HardwareSpec, strategy: &GraphOptimizationStrategy, ) -> QuantRS2Result<HashMap<QubitId, usize>>
Optimize circuit layout using SciRS2 graph algorithms
Sourcepub fn generate_scirs2_optimization_report<const N: usize>(
&self,
original_circuit: &Circuit<N>,
optimized_circuit: &Circuit<N>,
transpilation_stats: &TranspilationStats,
) -> String
pub fn generate_scirs2_optimization_report<const N: usize>( &self, original_circuit: &Circuit<N>, optimized_circuit: &Circuit<N>, transpilation_stats: &TranspilationStats, ) -> String
Generate optimization report with SciRS2 insights
Sourcepub fn add_hardware_spec(&mut self, spec: HardwareSpec)
pub fn add_hardware_spec(&mut self, spec: HardwareSpec)
Add or update a hardware specification
Sourcepub fn available_devices(&self) -> Vec<String>
pub fn available_devices(&self) -> Vec<String>
Get available hardware devices
Sourcepub fn transpile<const N: usize>(
&self,
circuit: &Circuit<N>,
device: &str,
options: Option<TranspilationOptions>,
) -> QuantRS2Result<TranspilationResult<N>>
pub fn transpile<const N: usize>( &self, circuit: &Circuit<N>, device: &str, options: Option<TranspilationOptions>, ) -> QuantRS2Result<TranspilationResult<N>>
Transpile circuit for specific device
Trait Implementations§
Auto Trait Implementations§
impl Freeze for DeviceTranspiler
impl !RefUnwindSafe for DeviceTranspiler
impl Send for DeviceTranspiler
impl Sync for DeviceTranspiler
impl Unpin for DeviceTranspiler
impl !UnwindSafe for DeviceTranspiler
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
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 moreSource§impl<T> Pointable for T
impl<T> Pointable for T
Source§impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
impl<SS, SP> SupersetOf<SS> for SPwhere
SS: SubsetOf<SP>,
Source§fn to_subset(&self) -> Option<SS>
fn to_subset(&self) -> Option<SS>
The inverse inclusion map: attempts to construct
self from the equivalent element of its
superset. Read moreSource§fn is_in_subset(&self) -> bool
fn is_in_subset(&self) -> bool
Checks if
self is actually part of its subset T (and can be converted to it).Source§fn to_subset_unchecked(&self) -> SS
fn to_subset_unchecked(&self) -> SS
Use with care! Same as
self.to_subset but without any property checks. Always succeeds.Source§fn from_subset(element: &SS) -> SP
fn from_subset(element: &SS) -> SP
The inclusion map: converts
self to the equivalent element of its superset.