Convolutional Layers are deep learning layers that are commonly used on images. But their purpose is to extract features from spatial data.
The convolution layer uses filters of certain width and height, these filters convolve on the whole image. In Convolution Layers, weights are in the form of 1D, 2D, or 3D matrix. This weight matrix is multiple with the images.
Convolution Layer Parameters
Filters: Convolution layers can have many filters which are specified by filters parameter in Keras. Filters have sizes as width and height. filter size is called the kernel.
The number of pixels that filter moves is called Stride, stride will have different values of each dimension, such as in 2D there will be different values for row and column. in 3D there will be 3rd value for depth.
Keras
Conv1D
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | tf.keras.layers.Conv1D( filters, kernel_size, strides=1, padding="valid", data_format="channels_last", dilation_rate=1, groups=1, activation=None, use_bias=True, kernel_initializer="glorot_uniform", bias_initializer="zeros", kernel_regularizer=None, bias_regularizer=None, activity_regularizer=None, kernel_constraint=None, bias_constraint=None, **kwargs ) |
Conv2D
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | tf.keras.layers.Conv2D( filters, kernel_size, strides=(1, 1), padding="valid", data_format=None, dilation_rate=(1, 1), groups=1, activation=None, use_bias=True, kernel_initializer="glorot_uniform", bias_initializer="zeros", kernel_regularizer=None, bias_regularizer=None, activity_regularizer=None, kernel_constraint=None, bias_constraint=None, **kwargs ) |
Conv3D
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 | tf.keras.layers.Conv3D( filters, kernel_size, strides=(1, 1, 1), padding="valid", data_format=None, dilation_rate=(1, 1, 1), groups=1, activation=None, use_bias=True, kernel_initializer="glorot_uniform", bias_initializer="zeros", kernel_regularizer=None, bias_regularizer=None, activity_regularizer=None, kernel_constraint=None, bias_constraint=None, **kwargs ) |
No comments:
Post a Comment