mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-07-11 17:48:34 +00:00
Fix a warning in pool.cc (#8168)
The warning is: "Potential comparison of a constant with another constant. at D:\a_work\1\s\onnxruntime\core\providers\cuda\nn\pool.cc@167,21". It was found by VS static code analyzer in our CUDA EP.
This commit is contained in:
parent
821492f6f5
commit
9b75be3d3e
1 changed files with 1 additions and 1 deletions
|
|
@ -164,7 +164,7 @@ Status Pool<T, PoolType>::ComputeInternal(OpKernelContext* context) const {
|
|||
}
|
||||
|
||||
cudnnPoolingMode_t mode = CUDNN_POOLING_MAX;
|
||||
if (PoolType::type == onnxruntime::PoolType::kAveragePool) {
|
||||
if constexpr (PoolType::type == onnxruntime::PoolType::kAveragePool) {
|
||||
mode = pool_attrs_.count_include_pad ? CUDNN_POOLING_AVERAGE_COUNT_INCLUDE_PADDING
|
||||
: CUDNN_POOLING_AVERAGE_COUNT_EXCLUDE_PADDING;
|
||||
}
|
||||
|
|
|
|||
Loading…
Reference in a new issue