Community
cancel
Showing results for 
Search instead for 
Did you mean: 
S_Kobayashi
Beginner
409 Views

Model conversion error in 2020.3

Hello, I'm using 2020.3.
I converted "human-pose-estimation-3d-0001" using converter.py, but the conversion fails.

openvino@dd50f6fa0747:~$ /opt/intel/openvino/deployment_tools/tools/model_downloader/converter.py --name human-pose-estimation-3d-0001
========= Converting human-pose-estimation-3d-0001 to ONNX
Conversion to ONNX command: /usr/bin/python3 /opt/intel/openvino/deployment_tools/tools/model_downloader/pytorch_to_onnx.py --model-path=/home/openvino/public/human-pose-estimation-3d-0001 --model-name=PoseEstimationWithMobileNet --model-param=is_convertible_by_mo=True --import-module=model --weights=/home/openvino/public/human-pose-estimation-3d-0001/human-pose-estimation-3d-0001.pth --input-shape=1,3,256,448 --input-names=data --output-names=features,heatmaps,pafs --output-file=/home/openvino/public/human-pose-estimation-3d-0001/human-pose-estimation-3d-0001.onnx

ONNX check passed successfully.

========= Converting human-pose-estimation-3d-0001 to IR (FP16)
Conversion command: /usr/bin/python3 -- /opt/intel/openvino/deployment_tools/model_optimizer/mo.py --framework=onnx --data_type=FP16 --output_dir=/home/openvino/public/human-pose-estimation-3d-0001/FP16 --model_name=human-pose-estimation-3d-0001 --input=data '--mean_values=data[128.0,128.0,128.0]' '--scale_values=data[255.0,255.0,255.0]' --output=features,heatmaps,pafs --input_model=/home/openvino/public/human-pose-estimation-3d-0001/human-pose-estimation-3d-0001.onnx

Model Optimizer arguments:
Common parameters:
	- Path to the Input Model: 	/home/openvino/public/human-pose-estimation-3d-0001/human-pose-estimation-3d-0001.onnx
	- Path for generated IR: 	/home/openvino/public/human-pose-estimation-3d-0001/FP16
	- IR output name: 	human-pose-estimation-3d-0001
	- Log level: 	ERROR
	- Batch: 	Not specified, inherited from the model
	- Input layers: 	data
	- Output layers: 	features,heatmaps,pafs
	- Input shapes: 	Not specified, inherited from the model
	- Mean values: 	data[128.0,128.0,128.0]
	- Scale values: 	data[255.0,255.0,255.0]
	- Scale factor: 	Not specified
	- Precision of IR: 	FP16
	- Enable fusing: 	True
	- Enable grouped convolutions fusing: 	True
	- Move mean values to preprocess section: 	False
	- Reverse input channels: 	False
ONNX specific parameters:
Model Optimizer version: 	
[ ERROR ]  Exception occurred during running replacer "REPLACEMENT_ID" (<class 'extensions.front.user_data_repack.UserDataRepack'>): No node with name features. 
 For more information please refer to Model Optimizer FAQ (https://docs.openvinotoolkit.org/latest/_docs_MO_DG_prepare_model_Model_Optimizer_FAQ.html), question #51. 
FAILED:
human-pose-estimation-3d-0001

 

"single-human-pose-estimation-0001" as well.
I get same error when I convert using the downloader.py and converter.py.

I get an error when using Docker.
Are there any workarounds?

When I do the same thing in 2020.2, I can convert without any problems and no error.

Also, when converting in mo.py, "Model Optimizer version:" is not shown in 2020.3 as a blank field.
2020.2 is shown as "2020.2.0-60-g0bc66e26ff".

0 Kudos
4 Replies
Vladimir_Dudnik
Employee
409 Views

Hello,

have you installed required python modules with requirement_pytorch.in ?

Regards,
  Vladimir

S_Kobayashi
Beginner
409 Views

Hi Vladimir.

Yes, I installed it with "pip install -r ./requirements-pytorch.in".

The mo and converter tool are installed under a virtual environment(venv).
"sudo . /install_prerequisites.sh venv" to install them.
requirements-pytorch.in is also installed under the venv environment.

Again, it's not a problem in 2020.2, but only in 2020.3.


Regards,

Max_L_Intel
Moderator
409 Views

Hi Kobayashi.

Seems like this is the problem with PyTorch 1.5 version described in https://github.com/opencv/open_model_zoo/pull/1149
As a workaround you could either use PyTorch version lower than 1.5 for PyTorch-ONNX model conversion or use the hot fix provided within the pull request in the link above.

Thanks for using OpenVINO toolkit.

S_Kobayashi
Beginner
409 Views

I used hotfix for pytorch_to_onnx.py and it solved the problem.
Thanks for the useful information.

Reply