('Keyword argument not understood:', 'decay')
时间: 2024-01-18 15:03:20 浏览: 26
This error message typically occurs when you are passing an argument to a function or method that does not accept that argument. In this case, it seems like you are passing the argument "decay" to a function or method that does not have a parameter named "decay".
To resolve this error, you should check the documentation for the function or method you are using to see what arguments it accepts. Ensure that the argument you are passing is spelled correctly and matches the name of a valid argument for that function or method.
相关问题
'Keyword argument not understood:', 'stride'
This error message indicates that the code contains a keyword argument that is not recognized by the function or method being called. In this case, the argument "stride" is not understood by the function being called. This could be due to a typo, or the argument may not be supported by the function being used.
('Keyword argument not understood:', 'activation')
根据你提供的错误信息,看起来是在定义模型时出现了一个错误。错误信息中指出了一个不被理解的关键字参数'activation'。
根据你提供的代码,问题可能出现在以下这行代码中:
```
model.add(TimeDistributed(Conv1D(filters=64, kernel_size=1, activation='relu', input_shape=(None, testX.shape[1], 1))))
```
这个问题可能是因为你使用了不适用于`Conv1D`的`activation`参数。在`Conv1D`中,通常不直接使用激活函数,而是在卷积层后面添加一个激活函数层。
要解决这个问题,你可以尝试修改代码如下:
```
model.add(TimeDistributed(Conv1D(filters=64, kernel_size=1, input_shape=(None, testX.shape[1], 1))))
model.add(Activation('relu'))
```
这样可以将`Conv1D`和激活函数分开使用,以避免出现参数不被理解的错误。
相关推荐
![zip](https://img-home.csdnimg.cn/images/20210720083736.png)
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![pdf](https://img-home.csdnimg.cn/images/20210720083512.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)
![](https://csdnimg.cn/download_wenku/file_type_ask_c1.png)