constants
constants
¶
Constants for encoder configurations, backbone types, and output keys.
SpatialBackboneType
¶
Bases: StrEnum
Backbones producing (B, C, H, W) spatial feature maps via timm features_only.
FlatBackboneType
¶
Bases: StrEnum
Backbones producing (B, S, D) token sequences via timm forward_features.
DinoV2SigLIPBackboneType
¶
Bases: StrEnum
DINOv2+SigLIP paired RGB vision backbone identifiers.
ImageTextModelType
¶
Bases: StrEnum
Available image+text multimodal encoders.
AttentionImplementation
¶
Bases: StrEnum
Attention implementation types.
PoolingMethod
¶
Bases: StrEnum
Feature pooling methods for spatial and flat RGB encoders.
BatchNormHandling
¶
Bases: StrEnum
How to handle BatchNorm layers in spatial RGB backbones.
BatchNorm is problematic for temporal data: when reshaping (B,T,C,H,W) to (B*T,C,H,W), batch statistics mix frames across time, leaking future information into each frame's representation. This causes train/test mismatch since the signal vanishes at inference.
LanguageEncoderType
¶
Bases: StrEnum
Available language encoders.
EncoderOutputKeys
¶
Bases: StrEnum
Types of encoder output keys to use for extracting an output feature from an encoder.