IntorCrossArgsBuilder

Struct IntorCrossArgsBuilder 

Source
pub struct IntorCrossArgsBuilder<'l, F> {
    intor: Option<&'l str>,
    mols: Option<&'l [&'l CInt]>,
    shls_slice: Option<&'l [[usize; 2]]>,
    aosym: Option<CIntSymm>,
    out: Option<Option<&'l mut [F]>>,
    row_major: Option<bool>,
}
Expand description

Builder for IntorCrossArgs.

Fields§

§intor: Option<&'l str>

Integrator name, such as "int1e_ovlp", "int2e", etc.

§mols: Option<&'l [&'l CInt]>

Molecules for which the integral will be evaluated.

The length of molecules must be accordance with the shls_slice and number of centers of integrator.

§shls_slice: Option<&'l [[usize; 2]]>

Shell slices for evaluating sub-tensor of the total integral.

§aosym: Option<CIntSymm>

Symmetry of the integral. This will affect shape of output tensor.

§out: Option<Option<&'l mut [F]>>

Output buffer for the integral evaluation.

If this is None, the integral engine will generate a buffer for output.

§row_major: Option<bool>

Col-major or row-major output buffer (col-major default).

  • Col-major: the same data layout to PySCF’s 2/3-center integrals; shape presented in col-major.
  • Row-major: the same shape to PySCF’s integrals; shape presented in row-major.

Implementations§

Source§

impl<'l, F> IntorCrossArgsBuilder<'l, F>

Source

pub fn intor<VALUE: Into<&'l str>>(self, value: VALUE) -> Self

Integrator name, such as "int1e_ovlp", "int2e", etc.

Source

pub fn mols(self, value: &'l [&'l CInt]) -> Self

Molecules for which the integral will be evaluated.

The length of molecules must be accordance with the shls_slice and number of centers of integrator.

Source

pub fn shls_slice(self, value: &'l [[usize; 2]]) -> Self

Shell slices for evaluating sub-tensor of the total integral.

Source

pub fn aosym<VALUE: Into<CIntSymm>>(self, value: VALUE) -> Self

Symmetry of the integral. This will affect shape of output tensor.

Source

pub fn out(self, value: &'l mut [F]) -> Self

Output buffer for the integral evaluation.

If this is None, the integral engine will generate a buffer for output.

Source

pub fn row_major(self, value: bool) -> Self

Col-major or row-major output buffer (col-major default).

  • Col-major: the same data layout to PySCF’s 2/3-center integrals; shape presented in col-major.
  • Row-major: the same shape to PySCF’s integrals; shape presented in row-major.
Source

pub fn build(self) -> Result<IntorCrossArgs<'l, F>, CIntError>

Builds a new IntorCrossArgs.

§Errors

If a required field has not been initialized.

Source

fn create_empty() -> Self

Create an empty builder, with all fields set to None or PhantomData.

Trait Implementations§

Source§

impl<'l, F> Default for IntorCrossArgsBuilder<'l, F>

Source§

fn default() -> Self

Returns the “default value” for a type. Read more

Auto Trait Implementations§

§

impl<'l, F> Freeze for IntorCrossArgsBuilder<'l, F>

§

impl<'l, F> RefUnwindSafe for IntorCrossArgsBuilder<'l, F>
where F: RefUnwindSafe,

§

impl<'l, F> Send for IntorCrossArgsBuilder<'l, F>
where F: Send,

§

impl<'l, F> Sync for IntorCrossArgsBuilder<'l, F>
where F: Sync,

§

impl<'l, F> Unpin for IntorCrossArgsBuilder<'l, F>

§

impl<'l, F> !UnwindSafe for IntorCrossArgsBuilder<'l, F>

Blanket Implementations§

§

impl<T> Any for T
where T: 'static + ?Sized,

§

fn type_id(&self) -> TypeId

Gets the TypeId of self. Read more
§

impl<T> Borrow<T> for T
where T: ?Sized,

§

fn borrow(&self) -> &T

Immutably borrows from an owned value. Read more
§

impl<T> BorrowMut<T> for T
where T: ?Sized,

§

fn borrow_mut(&mut self) -> &mut T

Mutably borrows from an owned value. Read more
§

impl<T> From<T> for T

§

fn from(t: T) -> T

Returns the argument unchanged.

§

impl<T, U> Into<U> for T
where U: From<T>,

§

fn into(self) -> U

Calls U::from(self).

That is, this conversion is whatever the implementation of From<T> for U chooses to do.

Source§

impl<T> IntoEither for T

Source§

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 more
Source§

fn into_either_with<F>(self, into_left: F) -> Either<Self, Self>
where F: FnOnce(&Self) -> bool,

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
Source§

impl<T> Pointable for T

Source§

const ALIGN: usize

The alignment of pointer.
Source§

type Init = T

The type for initializers.
Source§

unsafe fn init(init: <T as Pointable>::Init) -> usize

Initializes a with the given initializer. Read more
Source§

unsafe fn deref<'a>(ptr: usize) -> &'a T

Dereferences the given pointer. Read more
Source§

unsafe fn deref_mut<'a>(ptr: usize) -> &'a mut T

Mutably dereferences the given pointer. Read more
Source§

unsafe fn drop(ptr: usize)

Drops the object pointed to by the given pointer. Read more
§

impl<T, U> TryFrom<U> for T
where U: Into<T>,

§

type Error = Infallible

The type returned in the event of a conversion error.
§

fn try_from(value: U) -> Result<T, <T as TryFrom<U>>::Error>

Performs the conversion.
§

impl<T, U> TryInto<U> for T
where U: TryFrom<T>,

§

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.
§

fn try_into(self) -> Result<U, <U as TryFrom<T>>::Error>

Performs the conversion.