I am encountering problems while using PyInstaller to package a Qt application that contains a spaCy language model

56 views Asked by At

enter image description here

My Python version is 3.10.13, using a .venv environment. The spaCy model I load is zh_core_web_trf. The code runs normally in VSCode, but when I package it with PyInstaller, it shows an error. I have already packaged the model files and spaCy-related modules, and have also installed spacy-transform.

I have tried switching between Conda and venv environments, as well as including hidden imports in the .spec file, and changing the code from spacy.load(modelname) to modelname.load().

0

There are 0 answers