Commit 8da6ff45 authored by xin.wang.waytous's avatar xin.wang.waytous

multi-w/hout

parent e1c4cc77
......@@ -22,8 +22,8 @@ units:
inputMean: [0, 0, 0]
inputStd: [1, 1, 1]
inferBatchSize: 1
inputWidth: 640
inputHeight: 640
inputWidth: 960 # 640
inputHeight: 544 # 640
fixAspectRatio: false
useBGR: false
-
......@@ -31,28 +31,30 @@ units:
inputNames: [resizeNormImages]
outputNames: [detections, seg_protos, depths, semantics]
runMode: 1 # 0-fp32 1-fp16 2-int8 (int8 not supported)
weightsPath: "configs/tasks/multi/isp_612m_best.onnx"
engineFile: "configs/tasks/multi/isp_612m_best_fp16.engine"
# weightsPath: "configs/tasks/multi/isp_612m_best.onnx"
# engineFile: "configs/tasks/multi/isp_612m_best_fp16.engine"
weightsPath: "configs/tasks/multi/isp_0718m_best.onnx"
engineFile: "configs/tasks/multi/isp_0718m_best_fp16.engine"
# calibImgPathFile: "configs/tasks/multi/isp_calib_imgs.txt"
# calibTableCache: "configs/tasks/multi/isp_calib_table.cache"
inferDynamic: false
inferBatchSize: 1
inputWidth: 640
inputHeight: 640
inputWidth: 960 # 640
inputHeight: 544 # 640
maxBatchSize: 1 # used when build engine
-
name: MultiPostProcess
inputNames: [detections, seg_protos, depths, semantics, undistortVisImage]
outputNames: [out_instances, out_semantics, out_depths]
inputWidth: 640
inputHeight: 640
inputWidth: 960 # 640
inputHeight: 544 # 640
fixAspectRatio: false
# instance-seg
nmsThreshold: 0.45
scoreThreshold: 0.2 # used when inference, can be modified
truncatedThreshold: 0.05
maxOutputNum: 1000
rawDetectionLength: 25200
rawDetectionLength: 32130 #25200
keepTopK: 100
segProtoDim: 32
instanceDownScale: 4
......
......@@ -177,7 +177,7 @@ bool MultiPostProcess::Exec() {
auto seg = std::make_shared<ios::SemanticSeg>();
seg->class_label = is;
seg->class_name = semanticClassNames[is];
cv::Mat mask_mat = cv::Mat::zeros(inputWidth / semanticDownScale, inputHeight / semanticDownScale, CV_32FC1);
cv::Mat mask_mat = cv::Mat::zeros(inputHeight / semanticDownScale, inputWidth / semanticDownScale, CV_32FC1);
for (int x = 0; x < inputWidth / semanticDownScale; x++) {
for (int y = 0; y < inputHeight / semanticDownScale; y++) {
float e = rawSemanticSegs[is * mask_mat.cols * mask_mat.rows + y * mask_mat.cols + x];
......@@ -205,7 +205,7 @@ bool MultiPostProcess::Exec() {
// Depth
auto depth = std::make_shared<ios::Depth>();
auto rawDepth = rawDepths->data_->mutable_cpu_data();
cv::Mat mask_mat = cv::Mat::zeros(inputWidth / depthDownScale, inputHeight / depthDownScale, CV_32FC1);
cv::Mat mask_mat = cv::Mat::zeros(inputHeight / depthDownScale, inputWidth / depthDownScale, CV_32FC1);
for (int x = 0; x < inputWidth / depthDownScale; x++) {
for (int y = 0; y < inputHeight / depthDownScale; y++) {
float e = rawDepth[y * mask_mat.cols + x];
......
test/multi_res.jpg

241 KB | W: | H:

test/multi_res.jpg

251 KB | W: | H:

test/multi_res.jpg
test/multi_res.jpg
test/multi_res.jpg
test/multi_res.jpg
  • 2-up
  • Swipe
  • Onion skin
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment