SimdKernels
Helpers & Utilities · AiDotNet.Tensors.Engines.Simd
No summary documentation available yet.
Methods
| Method | Summary |
|---|---|
double CosineSimilarity(ReadOnlySpan<double> a, ReadOnlySpan<double> b) |
|
double DotProduct(ReadOnlySpan<double> a, ReadOnlySpan<double> b) |
|
double Max(ReadOnlySpan<double> data) |
|
double MaxUnsafe(Double* data, int length) |
|
double Min(ReadOnlySpan<double> data) |
|
double Sum(ReadOnlySpan<double> data) |
|
float CosineSimilarity(ReadOnlySpan<float> a, ReadOnlySpan<float> b) |
|
float DotProduct(ReadOnlySpan<float> a, ReadOnlySpan<float> b) |
|
float Max(ReadOnlySpan<float> data) |
|
float MaxUnsafe(Single* data, int length) |
|
float Min(ReadOnlySpan<float> data) |
|
float MinUnsafe(Single* data, int length) |
|
float Sum(ReadOnlySpan<float> data) |
|
float SumSquaredDiffUnsafe(Single* data, float mean, int length) |
|
float SumUnsafe(Single* data, int length) |
|
void Abs(ReadOnlySpan<double> input, Span<double> output) |
|
void Abs(ReadOnlySpan<float> input, Span<float> output) |
|
void AbsUnsafe(Double* input, Double* output, int length) |
|
void AbsUnsafe(Single* input, Single* output, int length) |
|
void AddScalar(ReadOnlySpan<double> a, double scalar, Span<double> result) |
|
void AddScalar(ReadOnlySpan<float> a, float scalar, Span<float> result) |
|
void BatchNormBackwardDouble(Double* gradOutput, Double* input, Double* gamma, Double* mean, Double* variance, double epsilon, Double* gradInput, Double* gradGamma, Double* gradBeta, int batchSize, int channels, int spatialSize) |
|
void BatchNormBackwardHalf(ReadOnlySpan<Half> gradOutput, ReadOnlySpan<Half> input, ReadOnlySpan<Half> gamma, ReadOnlySpan<Half> mean, ReadOnlySpan<Half> variance, float epsilon, Span<Half> gradInput, Span<Half> gradGamma, Span<Half> gradBeta, int batchSize, int channels, int spatialSize) |
|
void BatchNormBackwardUnsafe(Single* gradOutput, Single* input, Single* gamma, Single* mean, Single* variance, float epsilon, Single* gradInput, Single* gradGamma, Single* gradBeta, int batchSize, int channels, int spatialSize) |
|
void Ceiling(ReadOnlySpan<double> input, Span<double> output) |
|
void Ceiling(ReadOnlySpan<float> input, Span<float> output) |
|
void CeilingUnsafe(Double* input, Double* output, int length) |
|
void CeilingUnsafe(Single* input, Single* output, int length) |
|
void Clamp(ReadOnlySpan<double> input, double min, double max, Span<double> output) |
|
void Clamp(ReadOnlySpan<float> input, float min, float max, Span<float> output) |
|
void ClampUnsafe(Single* input, Single* output, int length, float lo, float hi) |
|
void ConvertDoubleToFloat(ReadOnlySpan<double> source, Span<float> destination) |
|
void ConvertToHalf(ReadOnlySpan<float> source, Span<Half> destination) |
|
void ConvertToSingle(ReadOnlySpan<Half> source, Span<float> destination) |
|
void Cos(ReadOnlySpan<double> input, Span<double> output) |
|
void Cos(ReadOnlySpan<float> input, Span<float> output) |
|
void CoshUnsafe(Single* input, Single* output, int length) |
|
void DivideScalar(ReadOnlySpan<double> a, double scalar, Span<double> result) |
|
void DivideScalar(ReadOnlySpan<float> a, float scalar, Span<float> result) |
|
void ELU(ReadOnlySpan<double> input, double alpha, Span<double> output) |
|
void ELU(ReadOnlySpan<float> input, float alpha, Span<float> output) |
|
void ELUUnsafe(Single* input, Single* output, int length, float alpha) |
|
void EluBackwardDouble(Double* grad, Double* input, Double* eluOutput, Double* output, int length, double alpha) |
|
void EluBackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> input, ReadOnlySpan<Half> eluOutput, Span<Half> output, float alpha) |
|
void EluBackwardUnsafe(Single* grad, Single* input, Single* eluOutput, Single* output, int length, float alpha) |
|
void Exp(ReadOnlySpan<double> input, Span<double> output) |
|
void Exp(ReadOnlySpan<float> input, Span<float> output) |
|
void ExpUnsafe(Double* input, Double* output, int length) |
|
void ExpUnsafe(Single* input, Single* output, int length) |
|
void Floor(ReadOnlySpan<double> input, Span<double> output) |
|
void Floor(ReadOnlySpan<float> input, Span<float> output) |
|
void FloorUnsafe(Double* input, Double* output, int length) |
|
void FloorUnsafe(Single* input, Single* output, int length) |
|
void Frac(ReadOnlySpan<double> input, Span<double> output) |
|
void Frac(ReadOnlySpan<float> input, Span<float> output) |
|
void FusedGELUUnsafe(Single* input, Single* output, int length) |
|
void FusedLogSoftmaxRow(Single* input, Single* output, int cols) |
|
void GELU(ReadOnlySpan<double> input, Span<double> output) |
|
void GELU(ReadOnlySpan<float> input, Span<float> output) |
|
void GELUUnsafe(Double* input, Double* output, int length) |
|
void GELUUnsafe(Single* input, Single* output, int length) |
|
void GeluBackwardDouble(Double* grad, Double* input, Double* output, int length) |
|
void GeluBackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> input, Span<Half> output) |
|
void GeluBackwardUnsafe(Single* grad, Single* input, Single* output, int length) |
|
void HardSigmoidBackwardDouble(Double* grad, Double* input, Double* output, int length) |
|
void HardSigmoidBackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> input, Span<Half> output) |
|
void HardSigmoidBackwardUnsafe(Single* grad, Single* input, Single* output, int length) |
|
void HardSigmoidUnsafe(Single* input, Single* output, int length) |
|
void HardSwishBackwardDouble(Double* grad, Double* input, Double* output, int length) |
|
void HardSwishBackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> input, Span<Half> output) |
|
void HardSwishBackwardUnsafe(Single* grad, Single* input, Single* output, int length) |
|
void HardSwishUnsafe(Single* input, Single* output, int length) |
|
void LayerNormBackwardDouble(Double* gradOutput, Double* input, Double* gamma, Double* mean, Double* variance, double epsilon, Double* gradInput, Double* gradGamma, Double* gradBeta, int batchSize, int normSize) |
|
void LayerNormBackwardHalf(ReadOnlySpan<Half> gradOutput, ReadOnlySpan<Half> input, ReadOnlySpan<Half> gamma, ReadOnlySpan<Half> mean, ReadOnlySpan<Half> variance, float epsilon, Span<Half> gradInput, Span<Half> gradGamma, Span<Half> gradBeta, int batchSize, int normSize) |
|
void LayerNormBackwardUnsafe(Single* gradOutput, Single* input, Single* gamma, Single* mean, Single* variance, float epsilon, Single* gradInput, Single* gradGamma, Single* gradBeta, int batchSize, int normSize) |
|
void LeakyReLU(ReadOnlySpan<double> input, double alpha, Span<double> output) |
|
void LeakyReLU(ReadOnlySpan<float> input, float alpha, Span<float> output) |
|
void LeakyReLUUnsafe(Single* input, Single* output, int length, float alpha) |
|
void LeakyReluBackwardDouble(Double* grad, Double* input, Double* output, int length, double alpha) |
|
void LeakyReluBackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> input, Span<Half> output, float alpha) |
|
void LeakyReluBackwardUnsafe(Single* grad, Single* input, Single* output, int length, float alpha) |
|
void Log(ReadOnlySpan<double> input, Span<double> output) |
|
void Log(ReadOnlySpan<float> input, Span<float> output) |
|
void Log2(ReadOnlySpan<double> input, Span<double> output) |
|
void Log2(ReadOnlySpan<float> input, Span<float> output) |
|
void LogUnsafe(Double* input, Double* output, int length) |
|
void LogUnsafe(Single* input, Single* output, int length) |
|
void Mish(ReadOnlySpan<double> input, Span<double> output) |
|
void Mish(ReadOnlySpan<float> input, Span<float> output) |
|
void MishBackwardDouble(Double* grad, Double* input, Double* output, int length) |
|
void MishBackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> input, Span<Half> output) |
|
void MishBackwardUnsafe(Single* grad, Single* input, Single* output, int length) |
|
void MishUnsafe(Single* input, Single* output, int length) |
|
void MultiplyScalar(ReadOnlySpan<double> a, double scalar, Span<double> result) |
|
void MultiplyScalar(ReadOnlySpan<float> a, float scalar, Span<float> result) |
|
void MultiplyScalarUnsafe(Double* a, double scalar, Double* result, int length) |
|
void MultiplyScalarUnsafe(Single* a, float scalar, Single* result, int length) |
|
void Negate(ReadOnlySpan<double> input, Span<double> output) |
|
void Negate(ReadOnlySpan<float> input, Span<float> output) |
|
void NegateUnsafe(Single* input, Single* output, int length) |
|
void Pow(ReadOnlySpan<double> baseValues, double exponent, Span<double> output) |
|
void Pow(ReadOnlySpan<float> baseValues, ReadOnlySpan<float> exponents, Span<float> output) |
|
void Pow(ReadOnlySpan<float> baseValues, float exponent, Span<float> output) |
|
void ReLU(ReadOnlySpan<double> input, Span<double> output) |
|
void ReLU(ReadOnlySpan<float> input, Span<float> output) |
|
void ReLUUnsafe(Double* input, Double* output, int length) |
|
void ReLUUnsafe(Single* input, Single* output, int length) |
|
void ReciprocalUnsafe(Single* input, Single* output, int length) |
|
void Relu6BackwardDouble(Double* grad, Double* input, Double* output, int length) |
|
void Relu6BackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> input, Span<Half> output) |
|
void Relu6BackwardUnsafe(Single* grad, Single* input, Single* output, int length) |
|
void ReluBackwardDouble(Double* grad, Double* input, Double* output, int length) |
|
void ReluBackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> input, Span<Half> output) |
|
void ReluBackwardInPlaceUnsafe(Single* grad, Single* input, int length) |
|
void ReluBackwardScalarUnsafe(float scale, Single* input, Single* output, int length) |
|
void ReluBackwardUnsafe(Single* grad, Single* input, Single* output, int length) |
|
void RoundUnsafe(Double* input, Double* output, int length) |
|
void RoundUnsafe(Single* input, Single* output, int length) |
|
void SELUUnsafe(Single* input, Single* output, int length) |
|
void ScalarMultiplyAdd(ReadOnlySpan<double> a, ReadOnlySpan<double> b, double scalar, Span<double> result) |
|
void ScalarMultiplyAdd(ReadOnlySpan<float> a, ReadOnlySpan<float> b, float scalar, Span<float> result) |
|
void SeluBackwardDouble(Double* grad, Double* input, Double* output, int length) |
|
void SeluBackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> input, Span<Half> output) |
|
void SeluBackwardUnsafe(Single* grad, Single* input, Single* output, int length) |
|
void Sigmoid(ReadOnlySpan<double> input, Span<double> output) |
|
void Sigmoid(ReadOnlySpan<float> input, Span<float> output) |
|
void SigmoidBackwardDouble(Double* grad, Double* sigmoidOutput, Double* output, int length) |
|
void SigmoidBackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> sigmoidOutput, Span<Half> output) |
|
void SigmoidBackwardUnsafe(Single* grad, Single* sigmoidOutput, Single* output, int length) |
|
void SigmoidUnsafe(Double* input, Double* output, int length) |
|
void SigmoidUnsafe(Single* input, Single* output, int length) |
|
void SignUnsafe(Single* input, Single* output, int length) |
|
void Sin(ReadOnlySpan<double> input, Span<double> output) |
|
void Sin(ReadOnlySpan<float> input, Span<float> output) |
|
void SinCos(ReadOnlySpan<double> input, Span<double> sinOutput, Span<double> cosOutput) |
|
void SinCos(ReadOnlySpan<float> input, Span<float> sinOutput, Span<float> cosOutput) |
|
void SinhUnsafe(Single* input, Single* output, int length) |
|
void SoftMax(ReadOnlySpan<double> input, Span<double> output) |
|
void SoftMax(ReadOnlySpan<float> input, Span<float> output) |
|
void Softmax(ReadOnlySpan<float> input, Span<float> output, int outerSize, int axisSize) |
|
void SoftmaxBackwardDouble(Double* grad, Double* softmaxOutput, Double* output, int batchSize, int features) |
|
void SoftmaxBackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> softmaxOutput, Span<Half> output, int batchSize, int features) |
|
void SoftmaxBackwardUnsafe(Single* grad, Single* softmaxOutput, Single* output, int batchSize, int features) |
|
void SoftplusBackwardDouble(Double* grad, Double* input, Double* output, int length, double beta) |
|
void SoftplusBackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> input, Span<Half> output, float beta) |
|
void SoftplusBackwardUnsafe(Single* grad, Single* input, Single* output, int length, float beta) |
|
void SoftplusUnsafe(Single* input, Single* output, int length) |
|
void Sqrt(ReadOnlySpan<double> input, Span<double> output) |
|
void Sqrt(ReadOnlySpan<float> input, Span<float> output) |
|
void SqrtUnsafe(Single* input, Single* output, int length) |
|
void StridedGatherDouble(Double* source, int offset, int stride, Double* result, int count) |
|
void StridedGatherFloat(Single* source, int offset, int stride, Single* result, int count) |
|
void StridedScatterDouble(Double* source, Double* destination, int offset, int stride, int count) |
|
void StridedScatterFloat(Single* source, Single* destination, int offset, int stride, int count) |
|
void SubtractScalar(ReadOnlySpan<double> a, double scalar, Span<double> result) |
|
void SubtractScalar(ReadOnlySpan<float> a, float scalar, Span<float> result) |
|
void Swish(ReadOnlySpan<double> input, Span<double> output) |
|
void Swish(ReadOnlySpan<float> input, Span<float> output) |
|
void SwishBackwardDouble(Double* grad, Double* input, Double* output, int length) |
|
void SwishBackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> input, Span<Half> output) |
|
void SwishBackwardUnsafe(Single* grad, Single* input, Single* output, int length) |
|
void Tanh(ReadOnlySpan<double> input, Span<double> output) |
|
void Tanh(ReadOnlySpan<float> input, Span<float> output) |
|
void TanhBackwardDouble(Double* grad, Double* tanhOutput, Double* output, int length) |
|
void TanhBackwardHalf(ReadOnlySpan<Half> grad, ReadOnlySpan<Half> tanhOutput, Span<Half> output) |
|
void TanhBackwardUnsafe(Single* grad, Single* tanhOutput, Single* output, int length) |
|
void TanhUnsafe(Double* input, Double* output, int length) |
|
void TanhUnsafe(Single* input, Single* output, int length) |
|
void VectorAdd(ReadOnlySpan<double> a, ReadOnlySpan<double> b, Span<double> result) |
|
void VectorAdd(ReadOnlySpan<float> a, ReadOnlySpan<float> b, Span<float> result) |
|
void VectorAddUnsafe(Double* a, Double* b, Double* result, int length) |
|
void VectorAddUnsafe(Single* a, Single* b, Single* result, int length) |
|
void VectorDivide(ReadOnlySpan<double> a, ReadOnlySpan<double> b, Span<double> result) |
|
void VectorDivide(ReadOnlySpan<float> a, ReadOnlySpan<float> b, Span<float> result) |
|
void VectorDivideUnsafe(Double* a, Double* b, Double* result, int length) |
|
void VectorDivideUnsafe(Single* a, Single* b, Single* result, int length) |
|
void VectorMaxUnsafe(Double* a, Double* b, Double* result, int length) |
|
void VectorMaxUnsafe(Single* a, Single* b, Single* result, int length) |
|
void VectorMinUnsafe(Double* a, Double* b, Double* result, int length) |
|
void VectorMinUnsafe(Single* a, Single* b, Single* result, int length) |
|
void VectorMultiply(ReadOnlySpan<double> a, ReadOnlySpan<double> b, Span<double> result) |
|
void VectorMultiply(ReadOnlySpan<float> a, ReadOnlySpan<float> b, Span<float> result) |
|
void VectorMultiplyUnsafe(Double* a, Double* b, Double* result, int length) |
|
void VectorMultiplyUnsafe(Single* a, Single* b, Single* result, int length) |
|
void VectorSubtract(ReadOnlySpan<double> a, ReadOnlySpan<double> b, Span<double> result) |
|
void VectorSubtract(ReadOnlySpan<float> a, ReadOnlySpan<float> b, Span<float> result) |
|
void VectorSubtractUnsafe(Double* a, Double* b, Double* result, int length) |
|
void VectorSubtractUnsafe(Single* a, Single* b, Single* result, int length) |