ImportError**: cannot import name ‘COMMON_SAFE_ASCII_CHARACTERS‘ from ‘charset_normalizer.constant‘

ImportError: cannot import name ‘COMMON_SAFE_ASCII_CHARACTERS’ from ‘charset_normalizer.constant’ 解决办法

conda info --env查看环境 查看后发现缺少transformers,chardet模块

conda activate 想要激活的环境名称 激活想要安装的环境

conda list查看环境中的包

需要安装transformers即可,conda install transformers
需要安装chardet即可,conda install chardet

ImportError**: cannot import name ‘COMMON_SAFE_ASCII_CHARACTERS‘ from ‘charset_normalizer.constant‘_第1张图片

补充:
查看channels
conda config --show channels

删除channels
conda config --remove channels

删除所有channels
conda config --remove-key --channels

恢复默认
channels conda config --remove-key channels

你可能感兴趣的:(python)