Skip to content Skip to sidebar Skip to footer

Dsx Python Import Error : Undefined Symbol: Pyunicodeucs2_asutf8string

On IBM DSX, I have a spark service instance on which I have installed a few newer versions of packages such as numpy. I am facing an issue with the import of numpy. The following c

Solution 1:

This is because of a mismatch in the Unicode characters representation between Python that you are using and the package you are importing. Solution is to use the extension modules compiled with a Python binary built using the same size for Unicode characters. You can update the Python2 packages installed in IBM Data Science Expereince Notebooks by:

!pip freeze --user > requirements.txt
!whileread p; do pip install --user "${p}" --ignore-installed ; done <./requirements.txt

Restart the notebook kernel as a precaution.

Post a Comment for "Dsx Python Import Error : Undefined Symbol: Pyunicodeucs2_asutf8string"