composite
118 memberslucid.ops.compositeFunctions
absolute→ TensorElement-wise absolute value.
acosh→ TensorInverse hyperbolic cosine.
addbmm→ TensorBatched matmul with reduction over the batch axis.
addcdiv→ TensorElement-wise fused divide-add.
addcmul→ TensorElement-wise fused multiply-add with a scalar weight.
addmm→ TensorGeneral matrix multiply with a scaled accumulator (GEMM).
addmv→ TensorMatrix-vector multiply with a scaled accumulator (BLAS-2 gemv).
addr→ TensorRank-1 update of a matrix by an outer product (BLAS-2 ger).
adjoint→ TensorConjugate (Hermitian) transpose of the trailing two dimensions.
angle→ TensorPhase angle (argument) of a complex tensor.
arccosh→ TensorInverse hyperbolic cosine.
arcsinh→ TensorInverse hyperbolic sine.
arctan2→ TensorQuadrant-correct two-argument arctangent.
arctanh→ TensorInverse hyperbolic tangent.
asinh→ TensorInverse hyperbolic sine.
atanh→ TensorInverse hyperbolic tangent.
atleast_1d→ Tensor | tuple[Tensor, ...]Promote each input to at least 1 dimension.
atleast_2d→ Tensor | tuple[Tensor, ...]Promote each input to at least 2 dimensions.
atleast_3d→ Tensor | tuple[Tensor, ...]Promote each input to at least 3 dimensions.
baddbmm→ TensorBatched GEMM with a batched accumulator.
block_diag→ TensorConstruct a block-diagonal matrix from a sequence of blocks.
can_cast→ boolPredicate: can from_dtype be safely cast to to_dtype?
column_stack→ TensorStack tensors as columns of a 2-D matrix.
conj_physical→ TensorEagerly materialised complex conjugate.
divide→ TensorElement-wise true division.
dsplit→ list[Tensor]Split a tensor along its third (depth) axis.
dstack→ TensorStack tensors along the third (depth) axis.
expm1→ TensorElement-wise .
float_power→ TensorElement-wise power that always promotes operands to float64.
fmax→ TensorElement-wise NaN-quiet maximum.
fmin→ TensorElement-wise NaN-quiet minimum.
ger→ TensorOuter product of two 1-D tensors.
heaviside→ TensorHeaviside step function with a user-selectable value at .
hsplit→ list[Tensor]Split a tensor horizontally (along axis 1 for rank ).
is_conj→ boolPredicate: does the tensor carry a lazy "conjugated" flag?
is_neg→ boolPredicate: does the tensor carry a lazy "negated" flag?
is_nonzero→ boolPredicate: is a single-element tensor non-zero?
is_same_size→ boolPredicate: do two tensors have identical shapes?
is_storage→ boolPredicate: is the object a separate Storage container?
isin→ TensorPer-element set-membership test.
isneginf→ TensorElement-wise test for negative infinity.
isposinf→ TensorElement-wise test for positive infinity.
isreal→ TensorElement-wise test for real-valued entries.
logit→ TensorLogit function — inverse of the logistic sigmoid.
moveaxis→ TensorMove one or more axes to new positions.
multiply→ TensorElement-wise product.
mv→ TensorMatrix-vector product.
nanmean→ TensorMean of the tensor, ignoring NaN entries.
nanmedian→ TensorMedian of a tensor, ignoring NaN entries.
nansum→ TensorSum the tensor, treating NaN entries as zero.
negative→ TensorElement-wise negation.
numel→ intReturn the total number of elements in a tensor.
polar→ TensorBuild a complex tensor from polar coordinates (magnitude, phase).
positive→ TensorElement-wise identity — returns the input unchanged.
promote_types→ DTypeCompute the joint promotion of two dtypes.
resolve_conj→ TensorMaterialise any pending lazy conjugation — no-op in Lucid.
resolve_neg→ TensorMaterialise any pending lazy negation — no-op in Lucid.
result_type→ DTypeCompute the dtype that a binary operation on the inputs would produce.
rot90→ TensorRotate a tensor by 90° in a chosen plane.
row_stack→ TensorStack tensors as rows — alias of lucid.vstack.
rsub→ TensorReverse subtraction: .
signbit→ TensorElement-wise sign-bit predicate.
sinc→ TensorNormalised sinc function with the standard removable singularity at 0.
subtract→ TensorElement-wise subtraction with an optional scalar multiplier.
swapaxes→ TensorReturn x with axes axis0 and axis1 exchanged.
swapdims→ TensorSwap two named dimensions of a tensor.
t→ TensorShort-form transpose for tensors of rank at most 2.
take_along_dim→ TensorGather elements from x at positions indices along dim.
tensor_split→ list[Tensor]Split a tensor along dim, permitting unequal final-piece sizes.
true_divide→ TensorElement-wise true (floating-point) division.
vdot→ TensorVector dot product (complex-conjugating on the first argument).
view_as_complex→ TensorReinterpret a real tensor with a trailing pair axis as a complex tensor.
view_as_real→ TensorReinterpret a complex tensor as a real tensor with a trailing pair axis.
vsplit→ list[Tensor]Split a tensor along its first (vertical) axis.
xlogy→ TensorCompute with the convention .
logdet→ TensorLog-determinant of a square matrix (or batch).
copysign→ TensorElement-wise sign transplant: magnitudes from x, signs from y.
diag_embed→ TensorEmbed the last dimension of x as the diagonal of a new matrix.
digamma→ TensorDigamma function .
erfc→ TensorComplementary error function .
floor_divide→ TensorElement-wise floor division — .
frexp→ tuple[Tensor, Tensor]Decompose input into mantissa m and exponent e such that
input = m * 2**e with |m| in [0.5, 1) (or m == 0).
gcd→ TensorElement-wise greatest common divisor for integer tensors.
i0→ TensorModified Bessel function of the first kind, order 0: .
lcm→ TensorElement-wise least common multiple for integer tensors.
ldexp→ TensorElement-wise .
lgamma→ TensorNatural log of the gamma function .
log_softmax→ TensorLogarithm of softmax along dim: .
softmax→ TensorSoftmax along dim — .
argwhere→ TensorReturn the coordinates of every non-zero element in x.
index_add→ TensorReturn input with alpha * source accumulated at index positions along dim.
index_copy→ TensorReturn a copy of input with slices at index replaced by source.
index_fill→ TensorReturn a copy of input with positions index along dim set to value.
index_put→ TensorOut-of-place advanced-indexing write.
index_put_→ TensorIn-place variant of index_put — mutates input so the
write is visible through the same Tensor reference.
masked_scatter→ TensorCopy elements from source into input at positions where mask is True.
put→ TensorWrite source into input at the flat positions in index.
scatter_reduce→ TensorReduce src into input along dim at positions given by index.
allclose→ boolReturn True iff every element pair is close within tolerance.
amax→ TensorReduce x to per-slice maxima along dim — values only.
amin→ TensorReduce x to per-slice minima along dim — values only.
count_nonzero→ TensorCount non-zero elements along dim (or whole tensor when None).
combinations→ TensorAll r-length combinations of the elements of a 1-D input.
tril_indices→ TensorIndices of the lower-triangular part of an (row, col) matrix.
triu_indices→ TensorIndices of the upper-triangular part of an (row, col) matrix.
bincount→ TensorCount occurrences of each integer value in input.
cdist→ TensorPairwise distance matrix between rows of x1 and x2.
corrcoef→ TensorPearson correlation-coefficient matrix.
cov→ TensorCovariance matrix of input.
histogram→ tuple of TensorCompute a 1-D histogram of input values.
histogram2d→ tuple of TensorJoint 2-D histogram of paired observations (x[i], y[i]).
histogramdd→ tupleN-dimensional histogram for arbitrary sample dimension.
multinomial→ TensorDraw num_samples indices from the categorical distribution defined by input.
nanquantile→ TensorNaN-aware quantile — same interface as quantile, but
every NaN is excluded from the sort and the per-axis quantile
is computed over the remaining values.
poisson→ TensorSample element-wise from .
quantile→ TensorCompute the q-th quantile of input.
std_mean→ tuple of TensorReturn (std, mean) along dim in a single call.
var_mean→ tuple of TensorReturn (var, mean) along dim in a single call.