pub struct TensorNode {
pub id: usize,
pub data: Vec<f64>,
pub leg_dims: Vec<usize>,
pub leg_labels: Vec<String>,
}Expand description
A node in a tensor network
Fields§
§id: usizeNode identifier
data: Vec<f64>Tensor data
leg_dims: Vec<usize>Dimensions of each leg
leg_labels: Vec<String>Labels for each leg (for contraction)
Implementations§
Trait Implementations§
Source§impl Clone for TensorNode
impl Clone for TensorNode
Source§fn clone(&self) -> TensorNode
fn clone(&self) -> TensorNode
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreAuto Trait Implementations§
impl Freeze for TensorNode
impl RefUnwindSafe for TensorNode
impl Send for TensorNode
impl Sync for TensorNode
impl Unpin for TensorNode
impl UnwindSafe for TensorNode
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