microsoft / microsoft/onnxruntime

[Documentation] [questinon] How to trace intermediate tensor shapes: can logging level help here?

Open
#15,352 1 comment 0 reactions 0 assignees View on GitHub
documentation
Dominant language
C++
Stars
21.9k
Forks
4.2k
Avg merge
4d 11h
Merged PRs (30d)
184

Description

### Describe the documentation issue

For some inputs our model throws in onnxrt with some shape mismatch. So it seems that our tests don't cover all graph paths.

Is it possible to ask onnxrt to trace/print all intermediate tensor shapes (maybe via some InferenceSession options / env variable)? I looked up logging levels https://onnxruntime.ai/docs/api/c/group___global.html#ga1c0fbcf614dbd0e2c272ae1cc04c629c, but it's not written there what exactly they affect.

This probably would have worked, but our execution fails, so not sure if the intermediate outputs are still preserved in this case: https://github.com/microsoft/onnxruntime/issues/1455#issuecomment-1050615116

### Page / URL

_No response_

Contributor guide

Open the contributing guide

Research direction

Start with the linked ONNX Runtime global logging documentation and the referenced issue comment. Determine whether logging levels or InferenceSession options expose intermediate tensor shapes when execution fails, and document the supported tracing method and the effect of each relevant logging level.

Written by the indexing model from the issue text.

Assessment

Tech stack
machine-learning
Domain
documentation, machine-learning
Issue type
Documentation
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.