美文网首页
opennmt安装踩坑记录

opennmt安装踩坑记录

作者: p_w | 来源:发表于2020-12-31 21:16 被阅读0次

    两种安装方式:
    1、pip install
    这种安装方式装的opennmt是1.2.0版本,会导致onmt_build_vocab等命令无法识别。
    解决方法:

    pip install --upgrade OpenNMT-py==2.0.0rc1

    2、build

    git clone https://github.com/OpenNMT/OpenNMT-py.git
    cd OpenNMT-py
    python setup.py install

    这种方式中会出现的错误opennmt-py 2.0.0rc2 has requirement pyyaml==5.3.1, but you'll have pyyaml 3.13 which is incompatible.
    pip之后依然会:Cannot uninstall 'PyYAML'. It is a distutils installed project and thus we cannot accurately determine which files belong to it which would lead to only a partial uninstall.
    解决方案:

    pip install --ignore-installed PyYAML==5.3.1

    相关文章

      网友评论

          本文标题:opennmt安装踩坑记录

          本文链接:https://www.haomeiwen.com/subject/vihuohtx.html