温馨提示:本文翻译自stackoverflow.com,查看原文请点击:python - Why model.fit_generator() has Attribution Error?
keras python

python - 为什么model.fit_generator()出现归因错误?

发布于 2020-04-05 23:57:49

我正在使用更新的模型重新运行内核。以前内核运行良好,我已经运行了6次。但是今天,该内核引发了以下错误:

---------------------------------------------------------------------------
AttributeError                            Traceback (most recent call last)
<ipython-input-18-e6baca729854> in <module>
      1 # don't use hardcode video numbers
----> 2 pred = model.predict_generator(pred_gen, steps=len(filenames)//BATCH_SIZE)

...

    AttributeError: module 'tensorflow.python.ops.script_ops' has no attribute 'numpy_function'

查看更多

提问者
Shark Deng
被浏览
130
Shark Deng 2020-02-17 19:59

问题已经解决了。今天当我再次运行代码时,它运行良好且没有错误,并且速度非常快。我想网络连接有问题。