
    Z j                     d    S r SSKJr  SSKJr  SSKJr  \" SS9\ " S S	\5      5       5       rS	/rg
)z'Swin2SR Transformer model configuration    )strict   )PreTrainedConfig)auto_docstringz caidas/swin2sr-classicalsr-x2-64)
checkpointc                     ^  \ rS rSr% SrSrSSSS.rSr\\	\   -  \
\\4   -  \S	'   S
r\\	\   -  \
\\4   -  \S'   Sr\\S'   Sr\S-  \S'   Sr\\S'   Sr\	\   \
\S4   -  \S'   Sr\	\   \
\S4   -  \S'   Sr\\S'   Sr\\S'   Sr\\S'   Sr\\-  \S'   Sr\\-  \S'   Sr\\-  \S'   Sr\\S '   S!r\\S"'   S#r\\S$'   S%r\\S&'   S'r\\S('   S)r \\S*'   S+r!\\S,'   S-r"\\S.'   U 4S/ jr#S0r$U =r%$ )1Swin2SRConfig   a  
num_channels_out (`int`, *optional*, defaults to `num_channels`):
    The number of output channels. If not set, it will be set to `num_channels`.
depths (`list(int)`, *optional*, defaults to `[6, 6, 6, 6, 6, 6]`):
    Depth of each layer in the Transformer encoder.
num_heads (`list(int)`, *optional*, defaults to `[6, 6, 6, 6, 6, 6]`):
    Number of attention heads in each layer of the Transformer encoder.
window_size (`int`, *optional*, defaults to 8):
    Size of windows.
upscale (`int`, *optional*, defaults to 2):
    The upscale factor for the image. 2/3/4/8 for image super resolution, 1 for denoising and compress artifact
    reduction
img_range (`float`, *optional*, defaults to 1.0):
    The range of the values of the input image.
resi_connection (`str`, *optional*, defaults to `"1conv"`):
    The convolutional block to use before the residual connection in each stage.
upsampler (`str`, *optional*, defaults to `"pixelshuffle"`):
    The reconstruction reconstruction module. Can be 'pixelshuffle'/'pixelshuffledirect'/'nearest+conv'/None.

Example:

```python
>>> from transformers import Swin2SRConfig, Swin2SRModel

>>> # Initializing a Swin2SR caidas/swin2sr-classicalsr-x2-64 style configuration
>>> configuration = Swin2SRConfig()

>>> # Initializing a model (with random weights) from the caidas/swin2sr-classicalsr-x2-64 style configuration
>>> model = Swin2SRModel(configuration)

>>> # Accessing the model configuration
>>> configuration = model.config
```swin2sr	embed_dim	num_heads
num_layers)hidden_sizenum_attention_headsnum_hidden_layers@   
image_size   
patch_sizer   num_channelsNnum_channels_out   )   r   r   r   r   r   .depths   window_sizeg       @	mlp_ratioTqkv_biasg        hidden_dropout_probattention_probs_dropout_probg?drop_path_rategelu
hidden_actFuse_absolute_embeddingsg{Gz?initializer_rangegh㈵>layer_norm_eps   upscaleg      ?	img_range1convresi_connectionpixelshuffle	upsamplerc                    > U R                   c  U R                  OU R                   U l         [        U R                  5      U l        [
        TU ]  " S0 UD6  g )N )r   r   lenr   r   super__post_init__)selfkwargs	__class__s     ڂ/root/GenerationalWealth/GenerationalWealth/venv/lib/python3.13/site-packages/transformers/models/swin2sr/configuration_swin2sr.pyr2   Swin2SRConfig.__post_init__Y   sE    595J5J5R 1 1X\XmXmdkk*''    )r   r   )&__name__
__module____qualname____firstlineno____doc__
model_typeattribute_mapr   intlisttuple__annotations__r   r   r   r   r   r   r   r   floatr   boolr   r    r!   r#   strr$   r%   r&   r(   r)   r+   r-   r2   __static_attributes____classcell__)r5   s   @r6   r	   r	      sa    D J #*)M 57Jd3i%S/1645Jd3i%S/15L##'cDj'Is*<FDIc3h'<-?ItCy5c?*?KIuHd'**03 %#+3"%NECK%J$)T)#u# NE GSIu"OS"#Is#( (r8   r	   N)	r=   huggingface_hub.dataclassesr   configuration_utilsr   utilsr   r	   __all__r/   r8   r6   <module>rM      sK    . . 3 # =>D($ D(  ?D(N 
r8   