You can not select more than 25 topics
Topics must start with a chinese character,a letter or number, can include dashes ('-') and can be up to 35 characters long.
|
-
- find_package(Protobuf)
-
- if(PROTOBUF_FOUND)
- include_directories(${PROTOBUF_INCLUDE_DIR})
- include_directories(${CMAKE_CURRENT_BINARY_DIR})
- protobuf_generate_cpp(ONNX_PROTO_SRCS ONNX_PROTO_HDRS onnx.proto)
- add_executable(onnx2ncnn onnx2ncnn.cpp ${ONNX_PROTO_SRCS} ${ONNX_PROTO_HDRS})
- set_target_properties(onnx2ncnn PROPERTIES CXX_STANDARD 11)
- target_link_libraries(onnx2ncnn ${PROTOBUF_LIBRARIES})
- else()
- message(WARNING "Protobuf not found, onnx model convert tool won't be built")
- endif()
|