|
MayaFlux 0.5.0
Digital-First Multimedia Processing Framework
|
Stateful executor for a VisionSequence. More...
#include <VisionExecutor.hpp>
Collaboration diagram for MayaFlux::Kinesis::Vision::VisionExecutor:Public Member Functions | |
| void | reset () |
| Clear stored inter-frame state. | |
| VisionResult | run (const VisionSequence &sequence, std::span< const float > frame, uint32_t w, uint32_t h) |
| Execute a VisionSequence on one frame. | |
| VisionExecutor ()=default | |
Private Member Functions | |
| void | ensure_slots (uint32_t w, uint32_t h) |
| Ensure all slots are sized to n_pixels floats. | |
| const std::vector< float > & | gaussian_kernel (float sigma) |
| Return a reference to the precomputed 1D Gaussian kernel for sigma. | |
| Eigen::Map< const Eigen::ArrayXf > | slot_map (size_t i, Eigen::Index n) const noexcept |
| Zero-copy read-only Eigen::Map<const ArrayXf> over slot i. | |
| Eigen::Map< Eigen::ArrayXf > | slot_map_mut (size_t i, Eigen::Index n) noexcept |
| Zero-copy mutable Eigen::Map<ArrayXf> over slot i. | |
| const std::vector< float > & | slot_vec (size_t i) const noexcept |
| Const reference to the vector<float> inside slot i. | |
| std::vector< float > & | slot_vec (size_t i) noexcept |
| Mutable reference to the vector<float> inside slot i. | |
Private Attributes | |
| std::vector< float > | m_curr_gray_cache |
| std::unordered_map< uint32_t, std::vector< float > > | m_kernel_cache |
| Kakshya::DataVariant | m_prev_gray { std::vector<float> {} } |
| std::vector< Keypoint > | m_prev_keypoints |
| uint32_t | m_slot_h { 0 } |
| uint32_t | m_slot_w { 0 } |
| std::array< Kakshya::DataVariant, k_slot_count > | m_slots |
Static Private Attributes | |
| static constexpr size_t | k_slot_count = 11 |
| static constexpr size_t | k_slot_cur = 0 |
| static constexpr size_t | k_slot_dx = 3 |
| static constexpr size_t | k_slot_dy = 4 |
| static constexpr size_t | k_slot_ixx = 5 |
| static constexpr size_t | k_slot_ixy = 7 |
| static constexpr size_t | k_slot_iyy = 6 |
| static constexpr size_t | k_slot_nxt = 1 |
| static constexpr size_t | k_slot_sxx = 8 |
| static constexpr size_t | k_slot_sxy = 10 |
| static constexpr size_t | k_slot_syy = 9 |
| static constexpr size_t | k_slot_tmp = 2 |
Stateful executor for a VisionSequence.
Owns a pool of DataVariant scratch slots (each holding vector<float>) sized to the working resolution. Steps read via Eigen::Map<const ArrayXf> and write via Eigen::Map<ArrayXf> into the next slot, then swap indices. No heap allocation occurs in steady state after the first frame at a given resolution.
Gaussian kernels are cached by sigma (keyed on bit-exact float) and reused across frames and across the three structure tensor smoothing passes in Harris.
One executor instance per pipeline. Not thread-safe.
Definition at line 95 of file VisionExecutor.hpp.