PineForge HPO 1.11.0
Native hyperparameter optimization for PineForge strategies
Loading...
Searching...
No Matches
pineforge::hpo::ReturnBlockLayout Struct Reference

Block layout of one bar-return series: how many intervals each block holds and which curve point opens it. More...

#include <pineforge/hpo/return_stats.hpp>

Public Attributes

std::uint32_t blocks = 0
 S, the block count; 0 when the layout is not usable.
 
std::int64_t intervals = 0
 K, the interval count; 0 when the layout is not usable.
 
bool usable = false
 True when the sizes and the times below are populated.
 
std::vector< std::int64_t > n_b
 S block sizes, ascending block.
 
std::vector< std::int64_t > boundary_time_ms
 S + 1 opening timestamps, in milliseconds.
 

Detailed Description

Block layout of one bar-return series: how many intervals each block holds and which curve point opens it.

Interval k is the pair of adjacent curve points (k, k + 1) of a curve of intervals + 1 points and belongs to block floor(k * S / K); block b opens at the point a_b = ceil(b * K / S), so n_b[b] = a_(b+1) - a_b, sum(n_b) = K, and boundary_time_ms[b] is that opening point's timestamp copied unchanged from the curve, for b = 0..S (the last entry is the curve's final point). The sizes depend on the curve length and S only, never on the equities; the times are the curve's own.

usable is true exactly when the request can be served and every rule the module checks holds: S is even and at least 2, K is at least S, the smallest half of the blocks holds at least two intervals, and the opening timestamps are non-decreasing (equal times are allowed). A layout that is not usable carries no sizes and no times.

Definition at line 257 of file return_stats.hpp.

Member Data Documentation

◆ blocks

std::uint32_t pineforge::hpo::ReturnBlockLayout::blocks = 0

S, the block count; 0 when the layout is not usable.

Definition at line 258 of file return_stats.hpp.

◆ boundary_time_ms

std::vector<std::int64_t> pineforge::hpo::ReturnBlockLayout::boundary_time_ms

S + 1 opening timestamps, in milliseconds.

Definition at line 262 of file return_stats.hpp.

◆ intervals

std::int64_t pineforge::hpo::ReturnBlockLayout::intervals = 0

K, the interval count; 0 when the layout is not usable.

Definition at line 259 of file return_stats.hpp.

◆ n_b

std::vector<std::int64_t> pineforge::hpo::ReturnBlockLayout::n_b

S block sizes, ascending block.

Definition at line 261 of file return_stats.hpp.

◆ usable

bool pineforge::hpo::ReturnBlockLayout::usable = false

True when the sizes and the times below are populated.

Definition at line 260 of file return_stats.hpp.


The documentation for this struct was generated from the following file: