|
@@ -141,6 +141,7 @@ void PipelineManager::create_from_json(const std::string& json_path)
|
|
|
new_node = std::make_shared<GNode::AnalyzeNode>(node_id);
|
|
|
std::shared_ptr<meta::AnalyzeConfigData> config_data = std::make_shared<meta::AnalyzeConfigData>();
|
|
|
config_data->algorithm_names = params.at("algorithm_names").get<std::vector<std::string>>();
|
|
|
+ std::vector<std::vector<cv::Point>> multi_fence_points;
|
|
|
for (const auto& [name, points] : params["algorithm_params_fence"].items())
|
|
|
{
|
|
|
std::vector<cv::Point> fence_points;
|
|
@@ -150,8 +151,9 @@ void PipelineManager::create_from_json(const std::string& json_path)
|
|
|
int y = point.at("y").get<int>();
|
|
|
fence_points.emplace_back(x, y);
|
|
|
}
|
|
|
- config_data->algorithm_params_fence[name] = fence_points;
|
|
|
+ multi_fence_points.push_back(fence_points);
|
|
|
}
|
|
|
+ config_data->algorithm_params_fence[name] = multi_fence_points;
|
|
|
new_node->set_config_data(config_data);
|
|
|
}
|
|
|
else if (node_type == "Drawer")
|
|
@@ -185,8 +187,8 @@ void PipelineManager::create_from_json(const std::string& json_path)
|
|
|
// --- Link nodes within the current pipeline ---
|
|
|
if (current_pipeline.nodes.size() > 1)
|
|
|
{
|
|
|
- int max_queue_size = 100;
|
|
|
- OverflowStrategy strategy = OverflowStrategy::BlockTimeout;
|
|
|
+ int max_queue_size = 20;
|
|
|
+ OverflowStrategy strategy = OverflowStrategy::DiscardOldest;
|
|
|
|
|
|
for (size_t i = 0; i < current_pipeline.nodes.size() - 1; ++i)
|
|
|
{
|