关于运行bert MRPC例子遇到的一些问题
首先声明一点,MRPC原文件本身 是本人最近 Technology goto Intertant获得的,所以不要指望本文能有什么特殊信息(滑稽)
各种错误集锦
(建议改为:人类迷惑行为大赏)
1. TensorFlow 绝对不能使用2.x 版本的!!!
因为!若你把所有软件的最新版本混在一起,就会发生剧烈的爆炸。对,就是爆炸,不要问我怎么知道的。爆炸时记得电子设备起火一定要使用干粉灭火器。
pypl相当于一个巨大的官方应用商店(- -)你可以在里面找到TensorFlow 2,然后在里面找到历史版本。都是要用pip安装的。
2. 在eclipse中,pyDev的 “包名”不能带减号(但是项目的示例的文件夹名字就是带减号的。。。)
3.在eclipse中,pyDev中,你需要工程源码文件拖动到你心建的同名工程里。语料库也可以复制,不过应该运行参数填对路径就不用复制了。。我没试过不复制的情况。
4. 手动安装的包名:
tokenization!这是个包可以装(虽然还不清楚他具体干啥的)
5. 加了个 from bert 就不出错了,我都要哭晕了
from bert import modeling from bert import optimization """加了个 from bert 就不出错了,我都要哭晕了 """
6. 没有安装tokenization的效果,解决见4:
ImportError: IMPORTANT: PLEASE READ THIS FOR ADVICE ON HOW TO SOLVE THIS ISSUE! Importing the numpy c-extensions failed. - Try uninstalling and reinstalling numpy. - If you have already done that, then: 1. Check that you expected to use Python3.7 from "C:\ProgramData\Anaconda3\python.exe", and that you have no directories in your PATH or PYTHONPATH that can interfere with the Python and numpy version "1.18.1" you're trying to use. 2. If (1) looks fine, you can open a new issue at https://github.com/numpy/numpy/issues. Please include details on: - how you installed Python - how you installed numpy - your operating system - whether or not you have multiple versions of Python installed - if you built from source, your compiler versions and ideally a build log - If you're working with a numpy git repository, try `git clean -xdf` (removes all files not under version control) and rebuild numpy. Note: this error has many possible causes, so please don't comment on an existing issue about this - open a new one instead. Original error was: DLL load failed: 找不到指定的模块。
以上。后续不定期更新。2020年3月20日10:57:17