我正在尝试使用Autograd包复制this standard example。
虽然我可以从这个存储库复制其他示例,但这个特定的示例抛出了一个错误,如下所示:
/home/avuis/anaconda/lib/python3.6/sitepackages/autograd/numpy/numpy_vjps.py:444: FutureWarning:
Using a non-tuple sequence for multidimensional indexing is deprecated; use `arr[tuple(seq)]` instead of `arr[seq]`.
In the future this will be interpreted as an array index, `arr[np.array(seq)]`, which will result either in an error or a different result.
return lambda g: g[idxs]此相关版本是否不兼容?如果是这样,有什么快速解决这个问题的方法吗?
提前谢谢你,
发布于 2018-09-13 20:52:28
尝试将您的scipy包更新到较新的版本。我使用的版本是1.0.0,示例可以正常工作。
但是,即使做了这样的更改,这个示例也不起作用。它运行时没有错误,但不会产生任何结果。我的猜测是Hessian和Jacobian近似是错误的,最小化算法不收敛。如果尝试另一种最小化算法,它确实会收敛(缓慢但稳定)。存储库中应该表示输出的当前图像已过时,因为在最新版本的代码中,风车中的类数是3,而不是5。
https://stackoverflow.com/questions/52262308
复制相似问题