Function ouster::sdk::core::frame_ops::reduce_factor_to_indices

Function Documentation

std::vector<size_t> ouster::sdk::core::frame_ops::reduce_factor_to_indices(size_t factor, size_t height)

Convert a downsampling factor to a list of beam indices.

Generates indices by selecting every Nth row. If factor equals height, returns only the middle row index.

Parameters:
  • factor[in] Downsampling factor. Must be a non-zero divisor of height.

  • height[in] Total number of beam rows.

Throws:

std::invalid_argument – If factor is 0 or does not evenly divide height.

Returns:

Vector of selected row indices.