relu 作为激活函数和层之间有什么区别吗?

Is there any difference between relu as an activation function or a layer?

relu作为激活函数和层有区别吗?例如

Conv2D(filters=8, kernel_size=(3, 3), activation='relu',padding='SAME', name='conv_2')

Conv2D(filters=8, kernel_size=(3, 3),padding='SAME', name='conv_2'),
ReLU()

没有实际区别,除了后者你可以 assign/set Relu()* 的参数。在第一种情况下,我相信它使用默认参数。

*https://www.tensorflow.org/api_docs/python/tf/keras/layers/ReLU