forked from Melody-Zhou/tensorRT_Pro-YOLOv8
-
Notifications
You must be signed in to change notification settings - Fork 0
/
Copy pathmake_pb.sh
27 lines (19 loc) · 959 Bytes
/
make_pb.sh
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
#!/bin/bash
# 请修改protoc为你要使用的版本protoc
protoc=/data/sxai/lean/protobuf3.11.4/bin/protoc
#protoc=/data/sxai/temp/protobuf-build3.18.x/bin/protoc
echo Create directory "pbout"
rm -rf pbout
mkdir -p pbout
$protoc onnx-ml.proto --cpp_out=pbout
$protoc onnx-operators-ml.proto --cpp_out=pbout
echo Copy pbout/onnx-ml.pb.cc to ../src/tensorRT/onnx/onnx-ml.pb.cpp
cp pbout/onnx-ml.pb.cc ../src/tensorRT/onnx/onnx-ml.pb.cpp
echo Copy pbout/onnx-operators-ml.pb.cc to ../src/tensorRT/onnx/onnx-operators-ml.pb.cpp
cp pbout/onnx-operators-ml.pb.cc ../src/tensorRT/onnx/onnx-operators-ml.pb.cpp
echo Copy pbout/onnx-ml.pb.h to ../src/tensorRT/onnx/onnx-ml.pb.h
cp pbout/onnx-ml.pb.h ../src/tensorRT/onnx/onnx-ml.pb.h
echo Copy pbout/onnx-operators-ml.pb.h to ../src/tensorRT/onnx/onnx-operators-ml.pb.h
cp pbout/onnx-operators-ml.pb.h ../src/tensorRT/onnx/onnx-operators-ml.pb.h
echo Remove directory "pbout"
rm -rf pbout