Skip to content

Commit

Permalink
Fix input shape related compile logs for MIGraphX EP to be semantical…
Browse files Browse the repository at this point in the history
…ly correct (microsoft#22624)

As the title suggests, recompilation is done if a mismatch is detected.
Changed the logs to reflect that behavior.
  • Loading branch information
sstamenk authored and ankitm3k committed Dec 11, 2024
1 parent 2ea4266 commit 86ee63c
Showing 1 changed file with 2 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -1152,7 +1152,7 @@ Status MIGraphXExecutionProvider::Compile(const std::vector<FusedNodeAndGraph>&

if (!no_input_shape) {
if (!load_precompiled_model(prog, load_compiled_model_, std::string{load_compiled_path_})) {
LOGS_DEFAULT(INFO) << "No Input shapes detected quantizing model";
LOGS_DEFAULT(INFO) << "No input shapes detected quantizing model";
prog = migraphx::parse_onnx_buffer(onnx_string_buffer, options);

// Read in the calibration data and map it to an migraphx paramater map for the calibration ops
Expand Down Expand Up @@ -1293,7 +1293,7 @@ Status MIGraphXExecutionProvider::Compile(const std::vector<FusedNodeAndGraph>&
// re-compile the program
if (!input_shape_match) {
if (!load_precompiled_model(prog, load_compiled_model_, std::string{load_compiled_path_})) {
LOGS_DEFAULT(VERBOSE) << "No Input shapes mismatch detected. Recompiling" << std::endl;
LOGS_DEFAULT(VERBOSE) << "Input shape mismatch detected. Recompiling" << std::endl;
#ifndef ENABLE_TRAINING_CORE
#if HIP_VERSION_MAJOR > 6 || (HIP_VERSION_MAJOR == 6 && HIP_VERSION_MINOR >= 2)
cmp_options.set_external_data_path(model_path_.has_parent_path() ? model_path_.parent_path().string() : std::filesystem::current_path().string());
Expand Down

0 comments on commit 86ee63c

Please sign in to comment.