CSPBlock<T>
Models & Types · AiDotNet.ComputerVision.Detection.Backbones
Cross-Stage Partial block used in CSP-Darknet.
Inheritance: LayerBase<T> → CSPBlock<T>
Implements: IShapeContract
How It Works
A real LayerBase rather than a bare holder class, so CSPDarknet can publish its
stages as Layers. As a plain class its weights were unreachable from every base walk:
the model reported no learnable parameters at all, and five training invariants “passed” in
under a millisecond by short-circuiting on a zero-length parameter vector.
Constructors
| Constructor | Summary |
|---|---|
CSPBlock(int inChannels, int outChannels, int numBlocks, int stride, IActivationFunction<T> activation) |
Properties
| Property | Summary |
|---|---|
bool SupportsTraining { get; } |
Methods
| Method | Summary |
|---|---|
IReadOnlyList<ILayer<T>> GetSubLayers() |
|
IReadOnlyList<OutputAxisContract> OutputAxesFor(int inputRank) |
|
long GetParameterCount() |
|
void ReadParameters(BinaryReader reader) |
|
void ResetState() |
|
void SetTrainingMode(bool isTraining) |
|
void UpdateParameters(T learningRate) |
|
void WriteParameters(BinaryWriter writer) |