class_docstr: This is the configuration class to store the configuration of a [`CLIPModel`]. It is used to instantiate an CLIP
  model according to the specified arguments, defining the model architecture. Instantiating a configuration with the
  defaults will yield a similar configuration to that of the CLIP
  [openai/clip-vit-base-patch32](https://huggingface.co/openai/clip-vit-base-patch32) architecture.
  
  Configuration objects inherit from [`PretrainedConfig`] and can be used to control the model outputs. Read the
  documentation from [`PretrainedConfig`] for more information.
  
  
  Args:
      vocab_size (`int`, *optional*, defaults to 49408):
          Vocabulary size of the CLIP text model. Defines the number of different tokens that can be represented by
          the `inputs_ids` passed when calling [`CLIPModel`].
      hidden_size (`int`, *optional*, defaults to 512):
          Dimensionality of the encoder layers and the pooler layer.
      intermediate_size (`int`, *optional*, defaults to 2048):
          Dimensionality of the "intermediate" (i.e., feed-forward) layer in the Transformer encoder.
      num_hidden_layers (`int`, *optional*, defaults to 12):
          Number of hidden layers in the Transformer encoder.
      num_attention_heads (`int`, *optional*, defaults to 8):
          Number of attention heads for each attention layer in the Transformer encoder.
      max_position_embeddings (`int`, *optional*, defaults to 77):
          The maximum sequence length that this model might ever be used with. Typically set this to something large
          just in case (e.g., 512 or 1024 or 2048).
      hidden_act (`str` or `function`, *optional*, defaults to `"quick_gelu"`):
          The non-linear activation function (function or string) in the encoder and pooler. If string, `"gelu"`,
          `"relu"`, `"selu"` and `"gelu_new"` ``"quick_gelu"` are supported. layer_norm_eps (`float`, *optional*,
          defaults to 1e-5): The epsilon used by the layer normalization layers.
      attention_dropout (`float`, *optional*, defaults to 0.0):
          The dropout ratio for the attention probabilities.
      dropout (`float`, *optional*, defaults to 0.0):
          The dropout probabilitiy for all fully connected layers in the embeddings, encoder, and pooler.
      initializer_range (`float`, *optional*, defaults to 0.02):
          The standard deviation of the truncated_normal_initializer for initializing all weight matrices.
      initializer_factor (`float``, *optional*, defaults to 1):
          A factor for initializing all weight matrices (should be kept to 1, used internally for initialization
          testing).
  
  Example:
  
  ```python
  >>> from transformers import CLIPTextConfig, CLIPTextModel
  
  >>> # Initializing a CLIPTextConfig with openai/clip-vit-base-patch32 style configuration
  >>> configuration = CLIPTextConfig()
  
  >>> # Initializing a CLIPTextModel (with random weights) from the openai/clip-vit-base-patch32 style configuration
  >>> model = CLIPTextModel(configuration)
  
  >>> # Accessing the model configuration
  >>> configuration = model.config
  ```
class_docstr_tok: ["This","is","the","configuration","class","to","store","the","configuration","of","a","[","`","CLIPModel","`","]",".","It","is","used","to","instantiate","an","CLIP","model","according","to","the","specified","arguments",",","defining","the","model","architecture",".","Instantiating","a","configuration","with","the","defaults","will","yield","a","similar","configuration","to","that","of","the","CLIP","[","openai\/clip-vit-base-patch32","]","(","https",":","\/\/huggingface.co\/openai\/clip-vit-base-patch32",")","architecture",".","Configuration","objects","inherit","from","[","`","PretrainedConfig","`","]","and","can","be","used","to","control","the","model","outputs",".","Read","the","documentation","from","[","`","PretrainedConfig","`","]","for","more","information",".","Args",":","vocab_size","(","`","int","`",",","*","optional","*",",","defaults","to","49408",")",":","Vocabulary","size","of","the","CLIP","text","model",".","Defines","the","number","of","different","tokens","that","can","be","represented","by","the","`","inputs_ids","`","passed","when","calling","[","`","CLIPModel","`","]",".","hidden_size","(","`","int","`",",","*","optional","*",",","defaults","to","512",")",":","Dimensionality","of","the","encoder","layers","and","the","pooler","layer",".","intermediate_size","(","`","int","`",",","*","optional","*",",","defaults","to","2048",")",":","Dimensionality","of","the","``","intermediate","''","(","i.e.",",","feed-forward",")","layer","in","the","Transformer","encoder",".","num_hidden_layers","(","`","int","`",",","*","optional","*",",","defaults","to","12",")",":","Number","of","hidden","layers","in","the","Transformer","encoder",".","num_attention_heads","(","`","int","`",",","*","optional","*",",","defaults","to","8",")",":","Number","of","attention","heads","for","each","attention","layer","in","the","Transformer","encoder",".","max_position_embeddings","(","`","int","`",",","*","optional","*",",","defaults","to","77",")",":","The","maximum","sequence","length","that","this","model","might","ever","be","used","with",".","Typically","set","this","to","something","large","just","in","case","(","e.g.",",","512","or","1024","or","2048",")",".","hidden_act","(","`","str","`","or","`","function","`",",","*","optional","*",",","defaults","to","`","``","quick_gelu","''","`",")",":","The","non-linear","activation","function","(","function","or","string",")","in","the","encoder","and","pooler",".","If","string",",","`","``","gelu","''","`",",","`","``","relu","''","`",",","`","``","selu","''","`","and","`","``","gelu_new","''","`","``","``","quick_gelu","''","`","are","supported",".","layer_norm_eps","(","`","float","`",",","*","optional","*",",","defaults","to","1e-5",")",":","The","epsilon","used","by","the","layer","normalization","layers",".","attention_dropout","(","`","float","`",",","*","optional","*",",","defaults","to","0.0",")",":","The","dropout","ratio","for","the","attention","probabilities",".","dropout","(","`","float","`",",","*","optional","*",",","defaults","to","0.0",")",":","The","dropout","probabilitiy","for","all","fully","connected","layers","in","the","embeddings",",","encoder",",","and","pooler",".","initializer_range","(","`","float","`",",","*","optional","*",",","defaults","to","0.02",")",":","The","standard","deviation","of","the","truncated_normal_initializer","for","initializing","all","weight","matrices",".","initializer_factor","(","`","float","``",",","*","optional","*",",","defaults","to","1",")",":","A","factor","for","initializing","all","weight","matrices","(","should","be","kept","to","1",",","used","internally","for","initialization","testing",")",".","Example",":","``","`","python",">",">",">","from","transformers","import","CLIPTextConfig",",","CLIPTextModel",">",">",">","#","Initializing","a","CLIPTextConfig","with","openai\/clip-vit-base-patch32","style","configuration",">",">",">","configuration","=","CLIPTextConfig","(",")",">",">",">","#","Initializing","a","CLIPTextModel","(","with","random","weights",")","from","the","openai\/clip-vit-base-patch32","style","configuration",">",">",">","model","=","CLIPTextModel","(","configuration",")",">",">",">","#","Accessing","the","model","configuration",">",">",">","configuration","=","model.config","``","`"]
code: def __init__(
      self,
      vocab_size=49408,
      hidden_size=512,
      intermediate_size=2048,
      num_hidden_layers=12,
      num_attention_heads=8,
      max_position_embeddings=77,
      hidden_act="quick_gelu",
      layer_norm_eps=0.00001,
      dropout=0.0,
      attention_dropout=0.0,
      initializer_range=0.02,
      initializer_factor=1.0,
      pad_token_id=1,
      bos_token_id=0,
      eos_token_id=2,
      **kwargs,
  ):
      super().__init__(
          pad_token_id=pad_token_id,
          bos_token_id=bos_token_id,
          eos_token_id=eos_token_id,
          **kwargs,
      )
  
      self.vocab_size = vocab_size
      self.hidden_size = hidden_size
      self.intermediate_size = intermediate_size
      self.dropout = dropout
      self.num_hidden_layers = num_hidden_layers
      self.num_attention_heads = num_attention_heads
      self.max_position_embeddings = max_position_embeddings
      self.layer_norm_eps = layer_norm_eps
      self.hidden_act = hidden_act
      self.initializer_range = initializer_range
      self.initializer_factor = initializer_factor
      self.attention_dropout = attention_dropout
  
imports: import copy
  import os
  from collections import OrderedDict
  from typing import TYPE_CHECKING, Any, Mapping, Optional, Union
  from ...configuration_utils import PretrainedConfig
  from ...onnx import OnnxConfig
  from ...utils import logging
label_desc: Use image node_id 1 to create a new CLIPTextConfig object from inherited base classes: PretrainedConfig with example: obj = CLIPTextConfig(vocab_size, hidden_size, intermediate_size, num_hidden_layers, num_attention_heads, max_position_embeddings, hidden_act, layer_norm_eps, dropout, attention_dropout, initializer_range, initializer_factor, pad_token_id, bos_token_id, eos_token_id)