o
    پi                     @   sT   d dl mZmZ d dlZd dlmZmZ eG dd deZeG dd deZdS )    )	dataclassfieldN)VAEArchConfig	VAEConfigc                   @   sX  e Zd ZU dZeed< dZeed< dZedB ed< dZeed< d	Z	e
ed
f ed< dZeed< dZe
ed
f ed< dZe
ed
f ed< dZeed< dZeed< dZeed< dZeed< dZedB ed< dZeed< dZeed< dZeed< d ZeejB ed!< dZe
ed
f dB ed"< dZe
ed
f dB ed#< dZedB ed$< dZeed%< dZeed&< dS )'GlmImageVAEArchConfig   spatial_compression_ratio`   base_dimNdecoder_base_dim   z_dim)r         r   .dim_multr   num_res_blocks attn_scales)FTTtemperal_downsampleg        dropoutFis_residual   input_channelsout_channels
patch_sizer   scale_factor_temporal   scale_factor_spatialTclip_outputr   scaling_factorlatents_meanlatents_stdshift_factorlatent_channelsin_channels) __name__
__module____qualname__r   int__annotations__r
   r   r   r   tupler   r   floatr   boolr   r   r   r   r   r   r   r   r   torchTensorr    r!   r"   r#   r$   r   r   r   f/home/ubuntu/.local/lib/python3.10/site-packages/sglang/multimodal_gen/configs/models/vaes/glmimage.pyr      s.   
 r   c                   @   sh   e Zd ZU eedZeed< dZeed< dZ	eed< dZ
eed< dZeed< d	d
 Zdd Zdd ZdS )GlmImageVAEConfig)default_factoryarch_configTuse_feature_cacheF
use_tilinguse_temporal_tilinguse_parallel_tilingc                 C   s   dt | jj S Nr   )lenr2   r   selfr   r   r/   get_vae_scale_factor0   s   z&GlmImageVAEConfig.get_vae_scale_factorc                 C   s   | j | j d | _d S r7   )tile_sample_min_num_framestile_sample_stride_num_framesblend_num_framesr9   r   r   r/   __post_init__3   s   

zGlmImageVAEConfig.__post_init__c                 C   s$   dt | jj | j_| jj| j_d S r7   )r8   r2   r   vae_scale_factorr   r9   r   r   r/   	post_init8   s   
zGlmImageVAEConfig.post_initN)r%   r&   r'   r   r   r2   r)   r3   r,   r4   r5   r6   r;   r?   rA   r   r   r   r/   r0   &   s   
 r0   )	dataclassesr   r   r-   .sglang.multimodal_gen.configs.models.vaes.baser   r   r   r0   r   r   r   r/   <module>   s    