tensorflow / tensorflow/models
[Help] Run inference without box decoder and the preprocessor
Nobody has claimed this yet.
- Dominant language
- Python
- Stars
- 77.7k
- Forks
- 44.8k
- PR merge metrics
- No merged PRs in 30d
Description
Hi,
I am trying to compare the ONNX predictions vs original model predictions. The main problem for me is that I need only the cut version of ONNX model and that is why I need to run the partial inference.
In Tensorflow v1 it was possible to get tensor by name, so doing the inference in the intermediate layers was easier but I don't understand how to do it in hee.
Below I attach the ONNX generation script. How can I do the equivalent inference with saved_model in TensorFlow for this part of the graph (without box decoder and the preprocessor)?
python -m tf2onnx.convert --opset 12 --output "./model.onnx" --saved-model ./saved_model --inputs-as-nchw "StatefulPartitionedCall/Preprocessor/stack:0" --inputs "StatefulPartitionedCall/Preprocessor/stack:0[1,640,640,3]" --outputs StatefulPartitionedCall/concat_1:0,StatefulPartitionedCall/concat:0
Would be very grateful for any help,
Best Regards
Contributor guide
First steps
- Read the whole issue, then the project's contributing guide.
- Comment on the issue to say you are picking it up — it saves two people doing the same work.
- Fork the repository and make your change on a branch.
- Open a pull request that references the issue number.
Assessment
This issue has not been assessed yet.