Calculation Results
Not calculated| # | Layer | Type | Input Shape | Output Shape | Weights | Biases | Trainable | Non-Trainable | Total | Share |
|---|
Formula Used
Standard convolution parameters equal kernel elements times grouped input channels and output filters. Bias terms add one value for each output filter. Frozen layers remain counted but move outside trainable totals.
Conv2D = (kernel height × kernel width × input channels ÷ groups × output filters) + bias Conv3D = (kernel depth × kernel height × kernel width × input channels ÷ groups × output filters) + bias Depthwise = (kernel height × kernel width × input channels × depth multiplier) + bias Pointwise = (input channels × output filters) + bias Dense = (input units × output units) + bias Batch normalization trainable = 2 × channels Batch normalization running statistics = 2 × channels
How to Use
Enter the network input dimensions and choose a numeric precision. Add layers manually or load a preset architecture. Press calculate to review shapes, parameters, memory, warnings, and charts.
Reorder layers by dragging their headers within the architecture builder. Freeze any layer to separate its values from trainable parameters. Export results when the final network configuration is valid.
Example Data
| Layer | Configuration | Parameters |
|---|---|---|
| Conv2D | 3×3, 3 input channels, 32 filters, bias | 896 |
| Batch normalization | 32 channels, running statistics included | 128 total values |
| Dense | 128 inputs, 10 outputs, bias | 1,290 |
Frequently Asked Questions
What counts as a CNN parameter?
Weights, biases, normalization scales, offsets, and selected state values can count. Pooling and activation layers usually contain no learned parameters. This calculator separates every category clearly.
Are frozen parameters removed?
No, frozen parameters remain part of the stored model. They are excluded only from trainable totals. Their memory footprint remains unchanged.
Why do grouped convolutions use fewer weights?
Each filter connects to only one input channel group. Dividing input channels reduces connected kernel values. Groups must divide both relevant channel counts.
How are batch normalization values counted?
Gamma and beta are normally trainable. Running mean and variance are normally non-trainable. The running-statistics checkbox controls their inclusion.
Does pooling change parameter counts?
Pooling changes spatial dimensions without learning kernel weights. Therefore, standard pooling contributes zero parameters. Output shape still changes substantially.
How is model memory estimated?
Parameter count is multiplied by bytes per selected precision. Training estimates add gradients and optimizer state. Actual frameworks may add temporary buffers.
Can this calculator handle depthwise separable convolution?
Yes, select depthwise or separable convolution layer types. Depth multipliers and pointwise filters are supported. Both stages appear in calculated totals.
Why can output dimensions become invalid?
Large kernels, dilation, strides, or custom padding can shrink dimensions. Any result below one is invalid. The calculator reports the failing layer.
Can architecture data be saved?
Yes, export JSON or save architecture data in local storage. Imported files restore network settings and layers. Share links encode the current configuration.