44 bool structure_changed {
true };
46 spdlog::debug(
"[PipelineHalideOperationManager::init]: m_last_operations.size() = {}, operations.size() = {}",
47 m_last_operations.size(), operations.size());
49 if (m_last_operations.size() == operations.size()) {
50 structure_changed =
false;
51 for (
size_t i = 0; i < operations.size(); ++i)
55 spdlog::debug(
"[PipelineHalideOperationManager::init]: Op[{}]: | last=({},{}) | new=({},{})",
56 operations[i].
id,m_last_operations[i].name, m_last_operations[i].enabled, operations[i].name, operations[i].enabled);
58 if (operations[i].
id != m_last_operations[i].
id ||
59 operations[i].enabled != m_last_operations[i].enabled) {
60 structure_changed =
true;
61 spdlog::debug(
"[PipelineHalideOperationManager::init]: Structure change detected at index {}", i);
66 spdlog::debug(
"[PipelineHalideOperationManager::init]: structure_changed = {}", structure_changed);
71 m_last_operations = operations;
74 std::lock_guard lock(m_mutex);
76 if (structure_changed) {
77 spdlog::info(
"[PipelineHalideOperationManager::init]: Structure changed. Recompiling pipeline.");
79 m_executor->init(std::move(operations), *m_operation_factory);
81 spdlog::trace(
"[PipelineHalideOperationManager::init]: Values only. Updating runtime params.");
83 m_executor->updateRuntimeParams(std::move(operations));