L2CS R18
Fit diagram
Read at 100%
Clear selection
Download SVG
Download PNG
Click a block to read its description, or select it with Tab and Enter.
L2CS R18
Face-crop gaze, 90 bins per angle, 3 × 448 × 448 normalized RGB input, native eval. Shapes exclude batch.
LibreYOLO
L2CS R18
Face-crop gaze, 90 bins per angle, 3 × 448 × 448 normalized RGB input, native eval. Shapes exclude batch.
ResNet face encoder
Normalized face crop
3 × 448 × 448
Conv2d 7×7, stride2
3 to64; padding3;64×224×224
BatchNorm2d + ReLU
64 × 224 × 224
MaxPool2d 3×3, stride2
64 × 112 × 112; padding1
BasicBlock stage1, n=2
64 × 112 × 112
BasicBlock stage2, n=2
128 × 56 × 56
BasicBlock stage3, n=2
256 × 28 × 28
BasicBlock stage4, n=2
512 × 14 × 14
Stage1 preserves stride4; stages2/3/4 downsample to stride32.
Parallel angle heads and decode
AdaptiveAvgPool2d(1) + flatten
512-element feature vector
Linear yaw
512 to90 logits
Softmax in float32
90 probabilities
Angular-bin expectation
4 × sum(probability[i] × i) -180 degrees
Multiply π/180
yaw in radians
Linear pitch
512 to90 logits
Softmax in float32
90 probabilities
Angular-bin expectation
4 × sum(probability[i] × i) -180 degrees
Multiply π/180
pitch in radians
Native model tuple order: (yaw_logits, pitch_logits).
External decode returns columns [pitch, yaw] in radians.
Face detection/cropping is a caller pipeline, not part of this network.
Unused upstream fc_finetune layer is absent.
BasicBlock stage 1
First block
Input
64 channels
Conv2d 3×3
64 to64; stride1,padding1
BatchNorm2d
64 channels
ReLU
Conv2d 3×3
64 to64; stride1,padding1
BatchNorm2d
64 channels
+
ReLU
64 output channels
Repeat n=1
Input
64 channels
Conv2d 3×3
64 to64; stride1,padding1
BatchNorm2d
64 channels
ReLU
Conv2d 3×3
64 to64; stride1,padding1
BatchNorm2d
64 channels
+
ReLU
64 output channels
BasicBlock stage 2
First block
Input
64 channels
Conv2d 3×3
64 to128; stride2,padding1
BatchNorm2d
128 channels
ReLU
Conv2d 3×3
128 to128; stride1,padding1
BatchNorm2d
128 channels
+
Conv1×1
64 to128;s2
BatchNorm
128 channels
ReLU
128 output channels
Repeat n=1
Input
128 channels
Conv2d 3×3
128 to128; stride1,padding1
BatchNorm2d
128 channels
ReLU
Conv2d 3×3
128 to128; stride1,padding1
BatchNorm2d
128 channels
+
ReLU
128 output channels
BasicBlock stage 3
First block
Input
128 channels
Conv2d 3×3
128 to256; stride2,padding1
BatchNorm2d
256 channels
ReLU
Conv2d 3×3
256 to256; stride1,padding1
BatchNorm2d
256 channels
+
Conv1×1
128 to256;s2
BatchNorm
256 channels
ReLU
256 output channels
Repeat n=1
Input
256 channels
Conv2d 3×3
256 to256; stride1,padding1
BatchNorm2d
256 channels
ReLU
Conv2d 3×3
256 to256; stride1,padding1
BatchNorm2d
256 channels
+
ReLU
256 output channels
BasicBlock stage 4
First block
Input
256 channels
Conv2d 3×3
256 to512; stride2,padding1
BatchNorm2d
512 channels
ReLU
Conv2d 3×3
512 to512; stride1,padding1
BatchNorm2d
512 channels
+
Conv1×1
256 to512;s2
BatchNorm
512 channels
ReLU
512 output channels
Repeat n=1
Input
512 channels
Conv2d 3×3
512 to512; stride1,padding1
BatchNorm2d
512 channels
ReLU
Conv2d 3×3
512 to512; stride1,padding1
BatchNorm2d
512 channels
+
ReLU
512 output channels
Source: libreyolo/models/l2cs/nn.py and model.py. Revision a4d0ecc9e17f.
libreyolo.com