Loading restyle-encoder-fp16.onnx on onnxruntime-gpu 1.15.0 throws this error. I downloaded model twice to check if file is corrupted.
2023-12-19 08:09:20.780145985 [E:onnxruntime:, inference_session.cc:1644 operator()] Exception during initialization: /onnxruntime_src/onnxruntime/core/optimizer/initializer.cc:43 onnxruntime::Initializer::Initializer(const onnx::TensorProto&, const onnxruntime::Path&) [ONNXRuntimeError] : 2 : INVALID_ARGUMENT : corrupted protobuf data: tensor shape size(1) does not match the data size(0) in proto
Traceback (most recent call last):
File "/home/user/Documents/AI_tools/test_restyle.py", line 3, in <module>
sess = onnxruntime.InferenceSession("/home/user/Downloads/restyle-encoder-fp16.onnx", providers=["CPUExecutionProvider"])
File "/home/user/mambaforge/envs/onnx_env/lib/python3.10/site-packages/onnxruntime/capi/onnxruntime_inference_collection.py", line 383, in __init__
self._create_inference_session(providers, provider_options, disabled_optimizers)
File "/home/user/mambaforge/envs/onnx_env/lib/python3.10/site-packages/onnxruntime/capi/onnxruntime_inference_collection.py", line 435, in _create_inference_session
sess.initialize_session(providers, provider_options, disabled_optimizers)
onnxruntime.capi.onnxruntime_pybind11_state.RuntimeException: [ONNXRuntimeError] : 6 : RUNTIME_EXCEPTION : Exception during initialization: /onnxruntime_src/onnxruntime/core/optimizer/initializer.cc:43 onnxruntime::Initializer::Initializer(const onnx::TensorProto&, const onnxruntime::Path&) [ONNXRuntimeError] : 2 : INVALID_ARGUMENT : corrupted protobuf data: tensor shape size(1) does not match the data size(0) in proto
Loading
restyle-encoder-fp16.onnx
ononnxruntime-gpu 1.15.0
throws this error. I downloaded model twice to check if file is corrupted.