【发布时间】:2020-06-09 00:28:59
【问题描述】:
RuntimeError: 在另一个循环正在运行时无法运行事件循环
尝试在我的本地设置 tensorflow_federated。所有导入版本都是正确的:
CUDA = 10.1,
python = 3.6.9,
张量流 = 2.2.0,
tf_federated = 最新
Google Colab 中没有发生此错误。但是,当我尝试进行任何联合计算时,会发生在我的本地机器上。我收到运行时错误: RuntimeError: 在另一个循环正在运行时无法运行事件循环
RuntimeError Traceback (most recent call last)
<ipython-input-5-9c097e9baec9> in <module>
----> 1 tff.federated_computation(lambda: 'hi')()
~\AppData\Local\Continuum\anaconda3\envs\tflocal\lib\asyncio\base_events.py in run_forever(self)
426 if events._get_running_loop() is not None:
427 raise RuntimeError(
--> 428 'Cannot run the event loop while another loop is running')
429 self._set_coroutine_wrapper(self._debug)
430 self._thread_id = threading.get_ident()
RuntimeError: Cannot run the event loop while another loop is running
【问题讨论】:
-
另外,试试这个:github.com/tensorflow/federated/blob/master/docs/tutorials/… 我的内核在运行后被杀死了 - nest_asyncio.apply()
标签: tensorflow tensorflow2.0 tensorflow-serving tensorflow-federated