引入onnx 运行时库
import onnxruntime
加载模型
sess = onnxruntime.InferenceSession("./FaceDetector.onnx")
需要知道输入输出名称
input_name = input[0].name
output0_name = output[0].name
output1_name = output[1].name
output2_name = output[2].name
运行
output = sess.run([output0_name, output1_name, output2_name], {input_name: image})
prob = np.squeeze(output[0])