GpuEmaCalculator
StockSharp.Algo.Gpu.Indicators
GPU calculator for Exponential Moving Average (EMA).
Наследует: GpuIndicatorCalculatorBase<ExponentialMovingAverage, GpuEmaParams, GpuIndicatorResult>
Конструкторы
GpuEmaCalculator
public GpuEmaCalculator(Context context, Accelerator accelerator)
gpuEmaCalculator = GpuEmaCalculator(context, accelerator)
Initializes a new instance of the GpuEmaCalculator class.
- context
- ILGPU context.
- accelerator
- ILGPU accelerator.
Методы
Calculate
public override GpuIndicatorResult[][][] Calculate(GpuCandle[][] candlesSeries, GpuEmaParams[] parameters)
result = gpuEmaCalculator.Calculate(candlesSeries, parameters)
EmaParamsSeriesKernel
private static void EmaParamsSeriesKernel(Index2D index, ArrayView<GpuCandle> flatCandles, ArrayView<GpuIndicatorResult> flatResults, ArrayView<int> offsets, ArrayView<int> lengths, ArrayView<GpuEmaParams> parameters)
GpuEmaCalculator.EmaParamsSeriesKernel(index, flatCandles, flatResults, offsets, lengths, parameters)
ILGPU kernel: EMA computation for multiple series and multiple parameter sets. One thread handles one (parameter, series) pair and iterates bars sequentially.