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

Table of Contents

Note
Clicking on the option with a triangle bullet ▸ next to it will expand/collapse its detailed information.
Type name written in PascalCase typically refer to a NEML2 object type, oftentimes a primitive tensor type.
The 🔗 symbol denotes that the option can cross-reference another object.
You can always use Ctrl+F or Cmd+F to search the entire page.

Available objects and their input file syntax

Refer to System Documentation for detailed explanation about this system.

EmptyMillerIndex

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptyQuaternion

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptyR2

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptyR3

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptyR4

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptyR5

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptyRot

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptySFFR4

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptySFR3

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptySR2

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptySSFR5

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptySSR4

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptySWR4

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptyScalar

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptyTensor

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

base_shape Base shape

  • Type: tensor shape
batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptyVec

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptyWR2

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptyWSR4

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

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

EmptyWWR4

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

batch_shape Batch shape

  • Type: tensor shape

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: list of number

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: list of 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: list of 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: list of Scalar 🔗

Detailed documentation link

FillWR2

Construct a Rot from a vector of Scalars.

values Scalars used to fill the WR2

  • Type: list of Scalar 🔗

Detailed documentation link

FullMillerIndex

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullQuaternion

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullR2

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullR3

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullR4

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullR5

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullRot

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullSFFR4

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullSFR3

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullSR2

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullSSFR5

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullSSR4

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullSWR4

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullScalar

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullTensor

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

base_shape Base shape

  • Type: tensor shape
batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullVec

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullWR2

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullWSR4

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

FullWWR4

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

batch_shape Batch shape

  • Type: tensor shape
value Value used to fill the tensor

  • Type: number

Detailed documentation link

IdentityTensor

Construct an identity Tensor with given batch shape.

batch_shape Batch shape

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

  • Type: number

Detailed documentation link

LinspaceMillerIndex

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: MillerIndex 🔗

Detailed documentation link

LinspaceQuaternion

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: Quaternion 🔗

Detailed documentation link

LinspaceR2

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: R2 🔗

Detailed documentation link

LinspaceR3

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: R3 🔗

Detailed documentation link

LinspaceR4

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: R4 🔗

Detailed documentation link

LinspaceR5

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: R5 🔗

Detailed documentation link

LinspaceRot

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: Rot 🔗

Detailed documentation link

LinspaceSFFR4

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: SFFR4 🔗

Detailed documentation link

LinspaceSFR3

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: SFR3 🔗

Detailed documentation link

LinspaceSR2

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: SR2 🔗

Detailed documentation link

LinspaceSSFR5

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: SSFR5 🔗

Detailed documentation link

LinspaceSSR4

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: SSR4 🔗

Detailed documentation link

LinspaceSWR4

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: SWR4 🔗

Detailed documentation link

LinspaceScalar

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: Scalar 🔗

Detailed documentation link

LinspaceTensor

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

batch_dim Batch dimension of the output

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

  • Type: tensor shape
dim Where to insert the new dimension

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: Tensor 🔗

Detailed documentation link

LinspaceVec

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: Vec 🔗

Detailed documentation link

LinspaceWR2

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: WR2 🔗

Detailed documentation link

LinspaceWSR4

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: WSR4 🔗

Detailed documentation link

LinspaceWWR4

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

batch_dim Batch dimension of the output

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: WWR4 🔗

Detailed documentation link

LogspaceMillerIndex

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: MillerIndex 🔗

Detailed documentation link

LogspaceQuaternion

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: Quaternion 🔗

Detailed documentation link

LogspaceR2

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: R2 🔗

Detailed documentation link

LogspaceR3

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: R3 🔗

Detailed documentation link

LogspaceR4

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: R4 🔗

Detailed documentation link

LogspaceR5

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: R5 🔗

Detailed documentation link

LogspaceRot

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: Rot 🔗

Detailed documentation link

LogspaceSFFR4

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: SFFR4 🔗

Detailed documentation link

LogspaceSFR3

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: SFR3 🔗

Detailed documentation link

LogspaceSR2

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: SR2 🔗

Detailed documentation link

LogspaceSSFR5

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: SSFR5 🔗

Detailed documentation link

LogspaceSSR4

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: SSR4 🔗

Detailed documentation link

LogspaceSWR4

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: SWR4 🔗

Detailed documentation link

LogspaceScalar

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: Scalar 🔗

Detailed documentation link

LogspaceTensor

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: Tensor 🔗

Detailed documentation link

LogspaceVec

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: Vec 🔗

Detailed documentation link

LogspaceWR2

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: WR2 🔗

Detailed documentation link

LogspaceWSR4

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
start The starting tensor

  • Type: WSR4 🔗

Detailed documentation link

LogspaceWWR4

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

base Exponent base

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

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

  • Type: number
end The ending tensor

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

  • Type: number
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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

Detailed documentation link

OnesMillerIndex

Construct a MillerIndex with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesQuaternion

Construct a Quaternion with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesR2

Construct a R2 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesR3

Construct a R3 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesR4

Construct a R4 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesR5

Construct a R5 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesRot

Construct a Rot with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesSFFR4

Construct a SFFR4 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesSFR3

Construct a SFR3 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesSR2

Construct a SR2 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesSSFR5

Construct a SSFR5 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesSSR4

Construct a SSR4 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesSWR4

Construct a SWR4 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesScalar

Construct a Scalar with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesTensor

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

base_shape Base shape

  • Type: tensor shape
batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesVec

Construct a Vec with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesWR2

Construct a WR2 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesWSR4

Construct a WSR4 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

OnesWWR4

Construct a WWR4 with given batch shape filled with ones.

batch_shape Batch shape

  • Type: tensor shape

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 number
  • Default: 1
random_seed Random seed for random angle generation

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

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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

Tensor

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

base_shape Base shape

  • Type: tensor shape
batch_shape Batch shape

  • Type: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

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: tensor shape
values Values in this (flattened) tensor

  • Type: list of number

Detailed documentation link

ZerosMillerIndex

Construct a MillerIndex with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosQuaternion

Construct a Quaternion with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosR2

Construct a R2 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosR3

Construct a R3 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosR4

Construct a R4 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosR5

Construct a R5 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosRot

Construct a Rot with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosSFFR4

Construct a SFFR4 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosSFR3

Construct a SFR3 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosSR2

Construct a SR2 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosSSFR5

Construct a SSFR5 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosSSR4

Construct a SSR4 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosSWR4

Construct a SWR4 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosScalar

Construct a Scalar with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosTensor

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

base_shape Base shape

  • Type: tensor shape
batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosVec

Construct a Vec with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosWR2

Construct a WR2 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosWSR4

Construct a WSR4 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link

ZerosWWR4

Construct a WWR4 with given batch shape filled with zeros.

batch_shape Batch shape

  • Type: tensor shape

Detailed documentation link