"No module named '_sqlite3'" Is Displayed When a Pangu Model Training Job Is Executed
Symptom
When a pangu model training job is executed, "No module named '_sqlite3'" is displayed.
Cause Analysis
The sqlite3 dependency required by the Pangu Image is missing. As a result, the training fails.
Solution
- Run the corresponding installation command based on the current OS type to install the sqlite3 dependency.
- Ubuntu
sudo apt-get install libsqlite3-dev
- CentOS
sudo yum install sqlite-devel
- Ubuntu
- Run the following command to recompile Python (Python 3.7.5 is used as an example).
- Download the Python package.
wget https://repo.huaweicloud.com/python/3.7.5/Python-3.7.5.tar.xz
- Decompress the package.
tar -xf Python-3.7.5.tar.xz && cd Python-3.7.5 && ./configure --prefix=/usr/local/python3.7.5 --enable-shared
- Perform the installation.
make && make install
- Download the Python package.
Parent topic: Faults During Use