microsoft / microsoft/onnxruntime
[Feature Request] TensorRT EP - Allow not setting kTF32 to remove WARNINGs
- Dominant language
- C++
- Stars
- 21.9k
- Forks
- 4.2k
- Avg merge
- 4d 11h
- Merged PRs (30d)
- 184
Description
### Describe the feature request
Running TRT EP with NVIDIA_TF32_OVERRIDE=0 causes a ton of warnings on usage as shown below:
```
2026-04-22 11:53:26.6952791 [W:onnxruntime:CSharpOnnxRuntime, tensorrt_execution_provider.h:92 onnxruntime::TensorrtLogger::log]
[2026-04-22 09:53:26 WARNING] Environment variable NVIDIA_TF32_OVERRIDE=0 but BuilderFlag::kTF32 is set. Disabling TF32.
2026-04-22 11:53:26.6967291 [W:onnxruntime:CSharpOnnxRuntime, tensorrt_execution_provider.h:92 onnxruntime::TensorrtLogger::log]
[2026-04-22 09:53:26 WARNING] Environment variable NVIDIA_TF32_OVERRIDE=0 but BuilderFlag::kTF32 is set. Disabling TF32.
```
this causes confusion for users and as it's warning they fear something is wrong. Defaulting to TF32 is the main issue but that can't be changed anymore I guess. I cannot find any option in ORT to actually not set or set kTF32 to false, so please add this so we can avoid these warnings.
Or please advise have we can avoid this warnings fully?
For C#/.NET usage, but I guess in general too.
### Describe scenario use case
Avoid runtime warnings.
Contributor guide
Research direction
Begin with onnxruntime::TensorrtLogger::log in tensorrt_execution_provider.h:92 and trace where BuilderFlag::kTF32 is configured for the TensorRT execution provider. The issue does not name a setter or test; completion should allow NVIDIA_TF32_OVERRIDE=0 users to avoid the repeated warnings in C#/.NET and other usage.
Written by the indexing model from the issue text.
Assessment
- Tech stack
- cpp, csharp
- Domain
- machine-learning
- Issue type
- Feature
- Difficulty
- 4/5
- Estimated time
- 3-5 days
- Activity status
- Quiet
- Clarity
- Mostly clear
- Newbie friendliness
- 48/100