src/transformers/models/regnet/modeling_tf_regnet.py/TFRegNetForImageClassification/__init__
class TFRegNetForImageClassification:    def __init__(self, config: RegNetConfig, *inputs, **kwargs):
        super().__init__(config, *inputs, **kwargs)
        self.num_labels = config.num_labels
        self.regnet = TFRegNetMainLayer(config, name="regnet")
        # classification head
        self.classifier = [
            tf.keras.layers.Flatten(),
            tf.keras.layers.Dense(config.num_labels, name="classifier.1") if config.num_labels > 0 else tf.identity,
        ]