Noodle
Loading...
Searching...
No Matches
ConvMem Struct Reference

Memory-backed convolution parameter bundle. More...

#include <noodle.h>

Public Attributes

uint16_t K = 3
 Kernel width, or tap count for 1D convolution.
uint16_t P = 0
 Padding per side; 65535 requests SAME-style 2D padding.
uint16_t S = 1
 Convolution stride.
uint16_t OP = 0
 User-computed output padding for transpose convolution.
const float * weight = nullptr
 Pointer to packed weight values.
const float * bias = nullptr
 Pointer to packed bias values, or nullptr.
Activation act = ACT_RELU
 Activation applied after adding bias.

Detailed Description

Memory-backed convolution parameter bundle.

weight points to packed floats in the same order as file-backed weights: [O][I][K][K] for 2D convolution, [O][I][K] for 1D convolution, [C][K][K] for depthwise convolution, and [O][I][K][K] for transpose convolution. bias may be nullptr in overloads that allow zero bias.

For transpose convolution with explicit padding, callers choose OP to match the desired output width: V = (W - 1) * S - 2 * P + K + OP.

Member Data Documentation

◆ act

Activation ConvMem::act = ACT_RELU

Activation applied after adding bias.

◆ bias

const float* ConvMem::bias = nullptr

Pointer to packed bias values, or nullptr.

◆ K

uint16_t ConvMem::K = 3

Kernel width, or tap count for 1D convolution.

◆ OP

uint16_t ConvMem::OP = 0

User-computed output padding for transpose convolution.

◆ P

uint16_t ConvMem::P = 0

Padding per side; 65535 requests SAME-style 2D padding.

◆ S

uint16_t ConvMem::S = 1

Convolution stride.

◆ weight

const float* ConvMem::weight = nullptr

Pointer to packed weight values.


The documentation for this struct was generated from the following file: