エラー: PyInstaller からの Python* スクリプト実行ファイルOpenVINO™実行中に「ImportError: DLL 読み込みに失敗しました」と表示される
コンテンツタイプ: エラーメッセージ | 記事 ID: 000092459 | 最終改訂日: 2023/06/16
OpenVINO™ Python スクリプトを作成しました。
from openvino.inference_engine import IECore
ie = IECore()
print("Devices:", ie.available_devices)
PyInstaller を使用して実行可能ファイルをビルドするために、次の行を実行しました。
pyinstaller test.py --onefile
実行可能ファイルの実行時に次のエラーが発生します。
ImportError: DLL load failed: The specified module could not be found.
pathex: セクションには、次の pythonpath OpenVINO™を .spec ファイルで提供します。
pathex=['D:\openvino_install_dir','D:\\openvino_install_dir\openvino_env\Lib\\site-packages\\openvino\libs']
次のコマンドを実行して、実行可能ファイルを .spec ファイルからビルドします。
pyinstaller --clean test.spec