Q:
Exception: "concat" mode can only merge layers with matching output shapes except for the concat axis. Layer shapes: [(None, 512, 30, 512), (None, 16, 30, 40)]
作者說是keras.json文件需要改成
{ "image_dim_ordering": "th", "epsilon": 1e-07, "floatx": "float32", "backend": "theano" }
然后就可以跑了耶!ヽ(●′?`●)?
--------------------------分割線----------------------------------------------------------------------
test過程中遇到的warning:
Using Theano backend.
Using cuDNN version 6021 on context None
Mapped name None to device cuda: GeForce GTX 1070 (0000:01:00.0)
/home/yifang/anaconda2/envs/py35/lib/python3.5/site-packages/keras/backend/theano_backend.py:1500: UserWarning: DEPRECATION: the 'ds' parameter is not going to exist anymore as it is going to be replaced by the parameter 'ws'.
mode='max')
/home/yifang/anaconda2/envs/py35/lib/python3.5/site-packages/keras/backend/theano_backend.py:1500: UserWarning: DEPRECATION: the 'st' parameter is not going to exist anymore as it is going to be replaced by the parameter 'stride'.
mode='max')
/home/yifang/anaconda2/envs/py35/lib/python3.5/site-packages/keras/backend/theano_backend.py:1500: UserWarning: DEPRECATION: the 'padding' parameter is not going to exist anymore as it is going to be replaced by the parameter 'pad'.
mode='max')
- theano cudnn不兼容問題,解決過程:
- 測試theano能不能用gpu
theano官網(wǎng):使用gpu
By default, when device indicates preference for GPU computations, Theano will fall back to the CPU if there is a problem with the GPU. You can use the flag force_device=True to instead raise an error when Theano cannot use the GPU.
所以就是有問題,不是設(shè)置問題。
dnn.include_path (<class 'str'>)
Doc: Location of the cudnn header
Value: /usr/local/cuda/include
dnn.library_path (<class 'str'>)
Doc: Location of the cudnn link library.
Value: /usr/local/cuda/lib64