From 307a77f04be29875f40d337cfff6df747df09de6 Mon Sep 17 00:00:00 2001 From: nihuini Date: Fri, 18 May 2018 19:40:40 +0800 Subject: [PATCH] convert LogisticRegressionOutput --- tools/mxnet/mxnet2ncnn.cpp | 11 +++++++++-- 1 file changed, 9 insertions(+), 2 deletions(-) diff --git a/tools/mxnet/mxnet2ncnn.cpp b/tools/mxnet/mxnet2ncnn.cpp index 82a17157f60..a3e1e259a8d 100644 --- a/tools/mxnet/mxnet2ncnn.cpp +++ b/tools/mxnet/mxnet2ncnn.cpp @@ -939,6 +939,10 @@ int main(int argc, char** argv) { fprintf(pp, "%-16s", "UnaryOp"); } + else if (n.op == "LogisticRegressionOutput") + { + fprintf(pp, "%-16s", "Sigmoid"); + } else if (n.op == "max") { fprintf(pp, "%-16s", "Reduction"); @@ -1040,7 +1044,7 @@ int main(int argc, char** argv) } } - if (n.op == "SoftmaxOutput") + if (n.op == "SoftmaxOutput" || n.op == "LogisticRegressionOutput") { // drop label input_size--; @@ -1057,7 +1061,7 @@ int main(int argc, char** argv) continue; } - if (n.op == "SoftmaxOutput") + if (n.op == "SoftmaxOutput" || n.op == "LogisticRegressionOutput") { // drop label if (j == 1) @@ -1549,6 +1553,9 @@ int main(int argc, char** argv) int op_type = 8; fprintf(pp, " 0=%d", op_type); } + else if (n.op == "LogisticRegressionOutput") + { + } else if (n.op == "max") { int operation = 4;