1

运行“ https://github.com/tensorflow/federated/blob/master/tensorflow_federated/python/research/gans/experiments/emnist/run_experiments.py ”时出现以下错误(我正在尝试重新生成论文的结果):

ModuleNotFoundError: No module named 'tensorflow_federated.python.research'
  1. 这是我的 anaconda 环境信息的完整列表:conda environment information
  2. 我在 Ubuntu 16.04 中使用 Pycharm:IDE
  3. 最后但并非最不重要的一点是,我尝试在终端中执行代码,但错误仍然存​​在,所以恐怕问题与 Pycharm IDE 无关。该问题与IDE无关

如果您能给我一些建议,我们将不胜感激。

4

1 回答 1

2

本研究项目遵循 TensorFlow Federated 使用bazel构建系统的实践。python 脚本不能直接运行。

安装 bazel 后,尝试以下命令行:

$ bazel run \
tensorflow_federated/python/research/gans/experiments/emnist:run_experiments
于 2020-03-23T14:56:50.627 回答