提交 50bf46d4 编写于 作者: M mindspore-ci-bot 提交者: Gitee

!4271 fix bug that same input tensor will repeat some times in graphIndex

Merge pull request !4271 from hangq/master
......@@ -682,8 +682,7 @@ build_lite()
cp ${BASEPATH}/mindspore/lite/build/src/libmindspore-lite.so ${OUTPUT_DIR}/lib/
mkdir -p ${OUTPUT_DIR}/third_party/protobuf/lib
cp -r ${BASEPATH}/third_party/protobuf/build/include/ ${OUTPUT_DIR}/third_party/protobuf/
cp -r ${BASEPATH}/third_party/protobuf/build/lib/libprotobuf.so.19 ${OUTPUT_DIR}/third_party/protobuf/lib/
cp -r ${BASEPATH}/third_party/protobuf/build/lib/libprotobuf.so.19.0.0 ${OUTPUT_DIR}/third_party/protobuf/lib/
cp -r ${BASEPATH}/third_party/protobuf/build/lib/libprotobuf.so.19.0.0 ${OUTPUT_DIR}/third_party/protobuf/lib/libprotobuf.so.19
mkdir -p ${OUTPUT_DIR}/third_party/flatbuffers
cp -r ${BASEPATH}/third_party/flatbuffers/include/ ${OUTPUT_DIR}/third_party/flatbuffers/
cd ..
......
......@@ -29,6 +29,7 @@
#include "src/ir/primitive_t_value.h"
#include "src/ir/tensor.h"
#include "src/param_value_lite.h"
#include "src/common/utils.h"
namespace mindspore::lite {
std::set<std::string> RemoveNodeInAnfExporter{"tuple_getitem", "make_tuple"};
......@@ -249,11 +250,12 @@ schema::MetaGraphT *AnfExporter::Export(const FuncGraphPtr &funcGraph) {
if (tensor->data.empty()) {
tensor->nodeType = schema::NodeType_ValueNode;
tensor->format = schema::Format_NHWC;
// tensor->refCount = lite::MSCONST_WEIGHT_REFCOUNT;
if (!IsContain(metaGraphT->inputIndex, input)) {
metaGraphT->inputIndex.emplace_back(input);
}
}
}
}
return metaGraphT.release();
}
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册