Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
5 changes: 0 additions & 5 deletions host/core/pipeline/host_pipeline_config.cpp
Original file line numberDiff line numberDiff line change
Expand Up@@ -44,11 +44,6 @@ bool HostPipelineConfig::initWithJSON(const json &json_obj)
}
}

// if 'meta_d2h' not specified - add it
if (!hasStream("meta_d2h"))
{
streams.emplace_back("meta_d2h");
}

// "depth"
if (json_obj.contains("depth"))
Expand Down
24 changes: 18 additions & 6 deletions host/py_module/py_bindings.cpp
Original file line numberDiff line numberDiff line change
Expand Up@@ -262,13 +262,7 @@ bool init_device(
}
}

// device support listener
g_device_support_listener = std::unique_ptr<DeviceSupportListener>(new DeviceSupportListener);

g_device_support_listener->observe(
*g_xlink.get(),
c_streams_myriad_to_pc.at("meta_d2h")
);


result = true;
Expand DownExpand Up@@ -424,6 +418,8 @@ std::shared_ptr<CNNHostPipeline> create_pipeline(
json_config_obj["ai"]["calc_dist_to_bb"] = config.ai.calc_dist_to_bb;

bool add_disparity_post_processing_color = false;
bool temp_measurement = false;

std::vector<std::string> pipeline_device_streams;

for (const auto &stream : config.streams)
Expand All@@ -437,6 +433,10 @@ std::shared_ptr<CNNHostPipeline> create_pipeline(
}
else
{
if (stream.name == "meta_d2h")
{
temp_measurement = true;
}
json obj = { {"name" ,stream.name} };

if (!stream.data_type.empty()) { obj["data_type"] = stream.data_type; };
Expand DownExpand Up@@ -658,6 +658,18 @@ std::shared_ptr<CNNHostPipeline> create_pipeline(
break;
}
}

if(temp_measurement)
{
// device support listener
g_device_support_listener = std::unique_ptr<DeviceSupportListener>(new DeviceSupportListener);

g_device_support_listener->observe(
*g_xlink.get(),
c_streams_myriad_to_pc.at("meta_d2h")
);
}

init_ok = true;
std::cout << "depthai: INIT OK!\n";
}
Expand Down