GpuDemandIndexCalculator
StockSharp.Algo.Gpu.Indicators
GPU calculator for Demand Index indicator.
Наследует: GpuIndicatorCalculatorBase<DemandIndex, GpuDemandIndexParams, GpuIndicatorResult>
Конструкторы
GpuDemandIndexCalculator
public GpuDemandIndexCalculator(Context context, Accelerator accelerator)
gpuDemandIndexCalculator = GpuDemandIndexCalculator(context, accelerator)
Initializes a new instance of the GpuDemandIndexCalculator class.
- context
- ILGPU context.
- accelerator
- ILGPU accelerator.
Методы
Calculate
public override GpuIndicatorResult[][][] Calculate(GpuCandle[][] candlesSeries, GpuDemandIndexParams[] parameters)
result = gpuDemandIndexCalculator.Calculate(candlesSeries, parameters)
DemandIndexParamsSeriesKernel
private static void DemandIndexParamsSeriesKernel(Index2D index, ArrayView<GpuCandle> flatCandles, ArrayView<GpuIndicatorResult> flatResults, ArrayView<int> offsets, ArrayView<int> lengths, ArrayView<GpuDemandIndexParams> parameters, ArrayView<double> windowStorage, int maxParamLength)
GpuDemandIndexCalculator.DemandIndexParamsSeriesKernel(index, flatCandles, flatResults, offsets, lengths, parameters, windowStorage, maxParamLength)
ILGPU kernel: Demand Index computation for multiple series and parameter sets. One thread processes a (parameter, series) pair sequentially across bars.