NEML2 1.4.0
Loading...
Searching...
No Matches
[Tensors]

Table of Contents

Available objects and their input file syntax

Refer to System Documentation for detailed explanation about this system.

BatchTensor

Construct a BatchTensor from a vector of values. The vector will be reshaped according to the specified batch and base shapes.

base_shape Base shape

  • Type: vector<long>
batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

EmptyBatchTensor

Construct an empty BatchTensor given batch and base shapes. Tensor values are undefined after construction.

base_shape Base shape

  • Type: vector<long>
batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptyMillerIndex

Construct an empty MillerIndex with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptyQuaternion

Construct an empty Quaternion with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptyR2

Construct an empty R2 with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptyR3

Construct an empty R3 with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptyR4

Construct an empty R4 with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptyR5

Construct an empty R5 with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptyRot

Construct an empty Rot with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptySFFR4

Construct an empty SFFR4 with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptySFR3

Construct an empty SFR3 with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptySR2

Construct an empty SR2 with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptySSFR5

Construct an empty SSFR5 with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptySSR4

Construct an empty SSR4 with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptySWR4

Construct an empty SWR4 with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptyScalar

Construct an empty Scalar with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptyVec

Construct an empty Vec with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptyWR2

Construct an empty WR2 with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptyWSR4

Construct an empty WSR4 with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

EmptyWWR4

Construct an empty WWR4 with given batch shape. Tensor values are undefined after construction.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

FillMillerIndex

Fills a tensor of Miller indices from a list of integers. Use -1 instead of \( \bar{1} \).

values List of integers defining a Miller index

  • Type: vector<int>

Detailed documentation link

FillR2

Construct a R2 with a vector of Scalars. The vector length must be 1, 3, 6, or 9. When vector length is 1, the Scalar value is used to fill the diagonals; when vector length is 3, the Scalar values are used to fill the respective diagonal entries; when vector length is 6, the Scalar values are used to fill the tensor following the Voigt notation; when vector length is 9, the Scalar values are used to fill the tensor in the row-major fashion.

values Scalars used to fill the R2

  • Type: vector<Scalar>

Detailed documentation link

FillRot

Construct a Rot from a vector of Scalars.

method Fill method, options are 'modified' and 'standard'.

  • Type: string
  • Default: modified
values Scalars used to fill the Rot

  • Type: vector<Scalar>

Detailed documentation link

FillSR2

Construct a R2 with a vector of Scalars. The vector length must be 1, 3, or 6. See the full documentation on neml2::SR2 on the dispatch of fill method. When vector length is 1, the Scalar value is used to fill the diagonals; when vector length is 3, the Scalar values are used to fill the respective diagonal entries; when vector length is 6, the Scalar values are used to fill the tensor following the Voigt notation.

values Scalars used to fill the R2

  • Type: vector<Scalar>

Detailed documentation link

FillWR2

Construct a Rot from a vector of Scalars.

values Scalars used to fill the WR2

  • Type: vector<Scalar>

Detailed documentation link

FullBatchTensor

Construct a full BatchTensor with given batch and base shapes filled with a given value.

base_shape Base shape

  • Type: vector<long>
batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullMillerIndex

Construct a full MillerIndex with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullQuaternion

Construct a full Quaternion with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullR2

Construct a full R2 with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullR3

Construct a full R3 with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullR4

Construct a full R4 with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullR5

Construct a full R5 with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullRot

Construct a full Rot with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullSFFR4

Construct a full SFFR4 with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullSFR3

Construct a full SFR3 with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullSR2

Construct a full SR2 with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullSSFR5

Construct a full SSFR5 with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullSSR4

Construct a full SSR4 with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullSWR4

Construct a full SWR4 with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullScalar

Construct a full Scalar with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullVec

Construct a full Vec with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullWR2

Construct a full WR2 with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullWSR4

Construct a full WSR4 with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

FullWWR4

Construct a full WWR4 with given batch shape filled with a given value.

batch_shape Batch shape

  • Type: vector<long>
value Value used to fill the tensor

  • Type: double

Detailed documentation link

IdentityBatchTensor

Construct an identity BatchTensor with given batch shape.

batch_shape Batch shape

  • Type: vector<long>
n Diagonal size of the identity tensor, i.e., base shape of the identity tensor will be (n,n)

  • Type: long

Detailed documentation link

LinspaceBatchTensor

Construct a BatchTensor linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
batch_expand After construction, perform an additional batch expanding operation into the given batch shape.

  • Type: vector<long>
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: BatchTensor
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: BatchTensor

Detailed documentation link

LinspaceMillerIndex

Construct a MillerIndex linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: MillerIndex
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: MillerIndex

Detailed documentation link

LinspaceQuaternion

Construct a Quaternion linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: Quaternion
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: Quaternion

Detailed documentation link

LinspaceR2

Construct a R2 linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: R2
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: R2

Detailed documentation link

LinspaceR3

Construct a R3 linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: R3
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: R3

Detailed documentation link

LinspaceR4

Construct a R4 linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: R4
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: R4

Detailed documentation link

LinspaceR5

Construct a R5 linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: R5
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: R5

Detailed documentation link

LinspaceRot

Construct a Rot linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: Rot
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: Rot

Detailed documentation link

LinspaceSFFR4

Construct a SFFR4 linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: SFFR4
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: SFFR4

Detailed documentation link

LinspaceSFR3

Construct a SFR3 linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: SFR3
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: SFR3

Detailed documentation link

LinspaceSR2

Construct a SR2 linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: SR2
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: SR2

Detailed documentation link

LinspaceSSFR5

Construct a SSFR5 linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: SSFR5
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: SSFR5

Detailed documentation link

LinspaceSSR4

Construct a SSR4 linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: SSR4
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: SSR4

Detailed documentation link

LinspaceSWR4

Construct a SWR4 linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: SWR4
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: SWR4

Detailed documentation link

LinspaceScalar

Construct a Scalar linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: Scalar
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: Scalar

Detailed documentation link

LinspaceVec

Construct a Vec linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: Vec
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: Vec

Detailed documentation link

LinspaceWR2

Construct a WR2 linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: WR2
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: WR2

Detailed documentation link

LinspaceWSR4

Construct a WSR4 linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: WSR4
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: WSR4

Detailed documentation link

LinspaceWWR4

Construct a WWR4 linearly spaced on the batch dimensions. See neml2::BatchTensorBase::linspace for a detailed explanation.

batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: WWR4
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: WWR4

Detailed documentation link

LogspaceBatchTensor

Construct a BatchTensor with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: BatchTensor
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: BatchTensor

Detailed documentation link

LogspaceMillerIndex

Construct a MillerIndex with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: MillerIndex
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: MillerIndex

Detailed documentation link

LogspaceQuaternion

Construct a Quaternion with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: Quaternion
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: Quaternion

Detailed documentation link

LogspaceR2

Construct a R2 with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: R2
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: R2

Detailed documentation link

LogspaceR3

Construct a R3 with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: R3
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: R3

Detailed documentation link

LogspaceR4

Construct a R4 with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: R4
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: R4

Detailed documentation link

LogspaceR5

Construct a R5 with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: R5
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: R5

Detailed documentation link

LogspaceRot

Construct a Rot with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: Rot
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: Rot

Detailed documentation link

LogspaceSFFR4

Construct a SFFR4 with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: SFFR4
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: SFFR4

Detailed documentation link

LogspaceSFR3

Construct a SFR3 with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: SFR3
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: SFR3

Detailed documentation link

LogspaceSR2

Construct a SR2 with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: SR2
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: SR2

Detailed documentation link

LogspaceSSFR5

Construct a SSFR5 with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: SSFR5
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: SSFR5

Detailed documentation link

LogspaceSSR4

Construct a SSR4 with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: SSR4
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: SSR4

Detailed documentation link

LogspaceSWR4

Construct a SWR4 with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: SWR4
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: SWR4

Detailed documentation link

LogspaceScalar

Construct a Scalar with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: Scalar
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: Scalar

Detailed documentation link

LogspaceVec

Construct a Vec with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: Vec
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: Vec

Detailed documentation link

LogspaceWR2

Construct a WR2 with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: WR2
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: WR2

Detailed documentation link

LogspaceWSR4

Construct a WSR4 with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: WSR4
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: WSR4

Detailed documentation link

LogspaceWWR4

Construct a WWR4 with exponents linearly spaced on the batch dimensions. See neml2::BatchTensorBase::logspace for a detailed explanation.

base Exponent base

  • Type: double
  • Default: 10
batch_dim Batch dimension of the output

  • Type: long
  • Default: -1
dim Where to insert the new dimension

  • Type: long
end The ending tensor

  • Type: WWR4
nstep The number of steps with even spacing along the new dimension

  • Type: long
start The starting tensor

  • Type: WWR4

Detailed documentation link

MillerIndex

Construct a MillerIndex from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

OnesBatchTensor

Construct a BatchTensor with batch and base shapes filled with ones.

base_shape Base shape

  • Type: vector<long>
batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesMillerIndex

Construct a MillerIndex with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesQuaternion

Construct a Quaternion with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesR2

Construct a R2 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesR3

Construct a R3 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesR4

Construct a R4 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesR5

Construct a R5 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesRot

Construct a Rot with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesSFFR4

Construct a SFFR4 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesSFR3

Construct a SFR3 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesSR2

Construct a SR2 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesSSFR5

Construct a SSFR5 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesSSR4

Construct a SSR4 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesSWR4

Construct a SWR4 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesScalar

Construct a Scalar with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesVec

Construct a Vec with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesWR2

Construct a WR2 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesWSR4

Construct a WSR4 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

OnesWWR4

Construct a WWR4 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

Orientation

An orientation, internally defined as a set of Modified Rodrigues parameters given by \( r = n \tan{\frac{\theta}{4}} \) with \( n \) the axis of rotation and \( \theta \) the rotation angle about that axis. However, this class provides a variety of ways to define the orientation in terms of other, more common representations.

angle_convention Euler angle convention, 'Kocks', 'Roe', or 'Bunge'

  • Type: string
  • Default: kocks
angle_type Type of angles, either 'degrees' or 'radians'

  • Type: string
  • Default: degrees
input_type The method used to define the angles, 'euler_angles' or 'random'

  • Type: string
  • Default: euler_angles
normalize If true do a shadow parameter replacement of the underlying MRP representation to move the inputs farther away from the singularity

  • Type: bool
  • Default: false
quantity Number (batch size) of random orientations

  • Type: unsigned int
  • Default: 1
random_seed Random seed for random angle generation

  • Type: long
  • Default: -1
values Input Euler angles, as a flattened n-by-3 matrix

  • Type: vector<double>

Detailed documentation link

Quaternion

Construct a Quaternion from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

R2

Construct a R2 from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

R3

Construct a R3 from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

R4

Construct a R4 from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

R5

Construct a R5 from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

Rot

Construct a Rot from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

SFFR4

Construct a SFFR4 from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

SFR3

Construct a SFR3 from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

SR2

Construct a SR2 from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

SSFR5

Construct a SSFR5 from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

SSR4

Construct a SSR4 from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

SWR4

Construct a SWR4 from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

Scalar

Construct a Scalar from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

SymmetryFromOrbifold

Returns a tensor of symmetry operations for a given symmetr group represented in orbifold notation.

orbifold A string giving the orbifold representation of the group, for example 432 for the typical cubic crystal system defined by chiral octahedral symmetry

  • Type: string

Detailed documentation link

Vec

Construct a Vec from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

WR2

Construct a WR2 from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

WSR4

Construct a WSR4 from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

WWR4

Construct a WWR4 from a vector values. The vector will be reshaped according to the specified batch shape.

batch_shape Batch shape

  • Type: vector<long>
values Values in this (flattened) tensor

  • Type: vector<double>

Detailed documentation link

ZerosBatchTensor

Construct a BatchTensor with batch and base shapes filled with zeros.

base_shape Base shape

  • Type: vector<long>
batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosMillerIndex

Construct a MillerIndex with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosQuaternion

Construct a Quaternion with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosR2

Construct a R2 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosR3

Construct a R3 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosR4

Construct a R4 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosR5

Construct a R5 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosRot

Construct a Rot with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosSFFR4

Construct a SFFR4 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosSFR3

Construct a SFR3 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosSR2

Construct a SR2 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosSSFR5

Construct a SSFR5 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosSSR4

Construct a SSR4 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosSWR4

Construct a SWR4 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosScalar

Construct a Scalar with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosVec

Construct a Vec with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosWR2

Construct a WR2 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosWSR4

Construct a WSR4 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link

ZerosWWR4

Construct a WWR4 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: vector<long>

Detailed documentation link