Loading...
Searching...
No Matches
convolutional_relu_layer.h
Go to the documentation of this file.
73 ActivationOp::Function get_output_activation() const override { return ActivationOp::Function::ReLU; }
Index get_padding_height() const
Returns the padding applied along the height axis.
Shape get_input_shape() const override
Returns the input tensor shape (height, width, channels).
Definition convolutional_relu_layer.h:40
Shape get_output_shape() const override
Returns the output tensor shape after the fused conv+ReLU.
pair< Index, Index > get_padding() const
Definition convolutional_relu_layer.h:63
void set(const Shape &={0, 0, 0}, const Shape &={3, 3, 1, 1}, const Shape &={1, 1}, const string &="Valid", const string &="convolutional_relu_layer")
Reconfigures the layer with new shapes and convolution settings.
void set_input_shape(const Shape &) override
Updates the layer for a new input shape and reinitializes derived sizes.
Index get_kernel_height() const
Definition convolutional_relu_layer.h:55
ActivationOp::Function get_output_activation() const override
Returns the layer's output activation (Identity for most layers; overridden by Dense/Bounding).
Definition convolutional_relu_layer.h:73
Index get_row_stride() const
Definition convolutional_relu_layer.h:60
void set_row_stride(const Index)
Index get_input_height() const
Definition convolutional_relu_layer.h:51
Index get_output_width() const
Returns the output feature map width.
Index get_input_width() const
Definition convolutional_relu_layer.h:52
void set_column_stride(const Index)
Index get_kernel_width() const
Definition convolutional_relu_layer.h:56
void write_JSON_body(JsonWriter &) const override
Writes the layer configuration to a JSON writer.
void read_JSON_body(const Json *) override
Reads the layer configuration from a JSON node.
Index get_kernels_number() const
Definition convolutional_relu_layer.h:58
Index get_padding_width() const
Returns the padding applied along the width axis.
void on_compute_dtype_changed() override
Rebuilds the fused convolution operator when the compute dtype changes.
Definition convolutional_relu_layer.h:86
ConvolutionalRelu(const Shape &={3, 3, 1}, const Shape &={3, 3, 1, 1}, const Shape &={1, 1}, const string &="Valid", const string &="convolutional_relu_layer")
Constructs a fused convolution+ReLU layer.
Index get_column_stride() const
Definition convolutional_relu_layer.h:61
void set_convolution_type(const string &)
Sets convolution type ("Valid" or "Same") and updates padding.
Index get_output_height() const
Returns the output feature map height.
Index get_kernel_channels() const
Definition convolutional_relu_layer.h:57
Index get_input_channels() const
Definition convolutional_relu_layer.h:53
bool get_use_padding() const
Definition convolutional_relu_layer.h:71
Definition json.h:85
Definition json.h:23
Layer()=default
Definition adaptive_moment_estimation.h:14
Fused 2D convolution + ReLU activation (uses cuDNN fused epilogue on GPU).
Definition operators.h:497
Fixed-capacity small-vector describing tensor dimensions (rank up to MaxRank).
Definition tensor_utilities.h:42