Skip to content

Commit

Permalink
Fix prepare imagenet (#1142)
Browse files Browse the repository at this point in the history
- Fix prepare_imagenet script in example_keras_mobilenetv2
- Mobilevit_xs in PyTorch tutorial output in ONNX opset 17
  • Loading branch information
lapid92 authored Jul 31, 2024
1 parent 9771975 commit f68485b
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -183,7 +183,7 @@
"if not os.path.isdir('imagenet/val'):\n",
" import subprocess\n",
" !git clone https://github.com/sony/model_optimization.git temp_mct && mv temp_mct/tutorials . && \\rm -rf temp_mct\n",
" !chmod +x prepare_imagenet.sh\n",
" !chmod +x tutorials/resources/scripts/prepare_imagenet.sh\n",
" subprocess.run(['tutorials/resources/scripts/prepare_imagenet.sh'])"
],
"metadata": {
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -250,7 +250,8 @@
"source": [
"mct.exporter.pytorch_export_model(model=quant_model,\n",
" save_model_path='./qmodel.onnx',\n",
" repr_dataset=representative_dataset_gen)"
" repr_dataset=representative_dataset_gen, \n",
" onnx_opset_version=17)"
]
},
{
Expand Down

0 comments on commit f68485b

Please sign in to comment.