mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-06-04 23:59:56 +00:00
fix build failure with --cmake_extra_defines onnxruntime_DEBUG_NODE_INPUTS_OUTPUTS=1 (#8587)
* fix build failure with --cmake_extra_defines onnxruntime_DEBUG_NODE_INPUTS_OUTPUTS=1 * another compile error and add onnxruntime_USE_ROCM * braces alignment Co-authored-by: suffian khan <sukha@microsoft.com>
This commit is contained in:
parent
d14b08d09c
commit
deab284e4c
2 changed files with 7 additions and 1 deletions
|
|
@ -1043,6 +1043,11 @@ if (NOT onnxruntime_ENABLE_TRAINING_TORCH_INTEROP)
|
|||
DEPENDS ${all_dependencies}
|
||||
)
|
||||
|
||||
if (onnxruntime_USE_ROCM)
|
||||
target_include_directories(onnxruntime_test_debug_node_inputs_outputs PRIVATE ${onnxruntime_ROCM_HOME}/hipfft/include ${onnxruntime_ROCM_HOME}/include ${onnxruntime_ROCM_HOME}/hipcub/include ${onnxruntime_ROCM_HOME}/hiprand/include ${onnxruntime_ROCM_HOME}/rocrand/include)
|
||||
target_include_directories(onnxruntime_test_debug_node_inputs_outputs PRIVATE ${ONNXRUNTIME_ROOT} ${CMAKE_CURRENT_BINARY_DIR}/amdgpu/onnxruntime)
|
||||
endif(onnxruntime_USE_ROCM)
|
||||
|
||||
target_compile_definitions(onnxruntime_test_debug_node_inputs_outputs
|
||||
PRIVATE DEBUG_NODE_INPUTS_OUTPUTS)
|
||||
endif(onnxruntime_DEBUG_NODE_INPUTS_OUTPUTS)
|
||||
|
|
|
|||
|
|
@ -851,9 +851,10 @@ std::vector<OrtValue> OpTester::ExecuteModel(
|
|||
expected_shape.NumDimensions());
|
||||
for (size_t d = 0; d < inferred_dims.size(); ++d) {
|
||||
// check equal unless the input involved a symbolic dimension
|
||||
if (inferred_dims[d] != -1)
|
||||
if (inferred_dims[d] != -1) {
|
||||
EXPECT_EQ(expected_shape[d], inferred_dims[d])
|
||||
<< "Output idx = " << idx << " dim = " << d;
|
||||
}
|
||||
}
|
||||
}
|
||||
Check(expected_data, ort_value.Get<Tensor>(), provider_type);
|
||||
|
|
|
|||
Loading…
Reference in a new issue