diff --git a/onnx-benchmark/README.md b/onnx-benchmark/README.md index c9c9feff..86953d82 100644 --- a/onnx-benchmark/README.md +++ b/onnx-benchmark/README.md @@ -35,11 +35,7 @@ Author: AMD-Xilinx - [3.3.8 File of parameters](#338-file-of-parameters) - [4 Additional features](#4-additional-features) - [4.1 Auto quantization](#41-auto-quantization) -<<<<<<< HEAD - [4.2 Tricks](#42-tricks) -======= - - [4.2 tricks](#42-tricks) ->>>>>>> b02f64fa (Merge branch 'VitisAI:main' into main_ci_add) # RYZENAI-ONNX-CNNs-BENCHMARK @@ -83,7 +79,6 @@ conda env config vars set VAIP_CONFIG_HOME="C:\Program Files\RyzenAI\1.2.0\voe-4 conda deactivate conda activate ryzen-ai-1.2.0 conda env config vars list -<<<<<<< HEAD ``` In case of PHOENIX device: @@ -101,8 +96,6 @@ Downgrade onnx to 1.16.1 to resolve an issue with the 1.16.2 release https://github.com/onnx/onnx/issues/6267 ``` pip install onnx==1.16.1 -======= ->>>>>>> b02f64fa (Merge branch 'VitisAI:main' into main_ci_add) ``` In case of PHOENIX device: @@ -116,6 +109,13 @@ conda activate ryzen-ai-1.2.0 conda env config vars list ``` +Downgrade onnx to 1.16.1 to resolve an issue with the 1.16.2 release +https://github.com/onnx/onnx/issues/6267 +``` +pip install onnx==1.16.1 +``` + + --- # 3 ONNX Benchmark @@ -269,9 +269,5 @@ Prior to quantization, the user is required to download some images, for example python performance_benchmark.py -m ".\models\resnet50\resnet50_fp32.onnx" -e VitisAIEP --calib --num_calib 10 ``` -<<<<<<< HEAD ## 4.2 Tricks -======= -## 4.2 tricks ->>>>>>> b02f64fa (Merge branch 'VitisAI:main' into main_ci_add) Once executed in the GUI, the equivalent command line is copied to the clipboard, making it easy to paste into the terminal. diff --git a/onnx-benchmark/utilities.py b/onnx-benchmark/utilities.py index e40d08f7..ee8cb67a 100644 --- a/onnx-benchmark/utilities.py +++ b/onnx-benchmark/utilities.py @@ -469,28 +469,8 @@ def ggquantize(args): newopset = 17 original_model = onnx.load(input_model_path) opset_version = original_model.opset_import[0].version -<<<<<<< HEAD # temporary fix: after conversion the opset is not updated to 17 but to 1 - if opset_version<11: - if opset_version==1 : - ggprint(f'[WARNING] The model opset version is 1, which seems unlikely. This might be the result of a previous opset conversion.') - else: - ggprint(f'The model OPSET is {opset_version} and should be updated to {newopset}') - user_response = ask_update() - if user_response == 'y': - output_updated = f"{base_name}_opset17{extension}" - converted_model = version_converter.convert_version(original_model, newopset) - #print(f"The model after conversion:\n{converted_model}") - onnx.save(converted_model, output_updated) - print(f'The update model was saved with name {output_updated}') - # verify opset - updated_model = onnx.load(output_updated) - ggprint(f"Updated model opset version: {updated_model.opset_import[0].version}") - input_model_path = output_updated - else: - ggprint("You chose not to update") -======= if opset_version<11: ggprint(f'The model OPSET is {opset_version} and should be updated to {newopset}') user_response = ask_update() @@ -503,7 +483,6 @@ def ggquantize(args): input_model_path = output_updated else: print("You chose not to update") ->>>>>>> b02f64fa (Merge branch 'VitisAI:main' into main_ci_add) # free memory del original_model gc.collect()