import gin

@gin.configurable
class SOFIAv1ModelsConfig:
    def __init__(
        self,
        # Backbone.
        variant: str = "small",              # 'tiny_tiny' | 'tiny' | 'small' | 'small_v2'
        in_channels: int = 3,
        input_size: int = 256,
        dcn_variant: str = "v2",             # 'v2' (stable) | 'v4' (faster, leaks)
        # Heads.
        d_descriptor: int = 1024,
        return_normalized: bool = False,
        # Altitude-FiLM.
        use_film_altitude: bool = True,
        altitude_norm: float = 500.0,
        # Text-FiLM.
        use_text_film_uav: bool = True,
        use_text_film_sat: bool = True,
        text_film_dim: int = 1024,
        text_film_hidden: int = 256,
    ) -> None:
        self.variant = variant
        self.in_channels = in_channels
        self.input_size = input_size
        self.dcn_variant = dcn_variant
        self.d_descriptor = d_descriptor
        self.return_normalized = return_normalized
        self.use_film_altitude = use_film_altitude
        self.altitude_norm = altitude_norm
        self.use_text_film_uav = use_text_film_uav
        self.use_text_film_sat = use_text_film_sat
        self.text_film_dim = text_film_dim
        self.text_film_hidden = text_film_hidden

        
