o
    ‘i  ã                   @   sF   d dl mZ d dlmZmZ dd„ Zdefdd„Zedkr!ed	ƒ‚d
S )é    )ÚList)Ú_compile_graph_to_code_tableÚ_generate_upgraders_graphc                    s>   ‡ fdd„‰ i }| D ]}|d }|d }ˆ |ƒ}|||< q
|S )Nc                    s    t | tƒs| S ‡ fdd„| D ƒS )Nc                    s   g | ]}ˆ |ƒ‘qS © r   )Ú.0Úi©Úlistifyr   új/var/www/html/eduruby.in/lip-sync/lip-sync-env/lib/python3.10/site-packages/torch/jit/generate_bytecode.pyÚ
<listcomp>   s    z4format_bytecode.<locals>.listify.<locals>.<listcomp>)Ú
isinstanceÚtuple)Úcontentr   r   r
   r	      s   
z format_bytecode.<locals>.listifyr   é   r   )ÚtableZformatted_tableÚentryÚ
identifierr   r   r   r
   Úformat_bytecode   s   
r   Úreturnc                  C   s@   g } t ƒ }| ¡ D ]\}}t||ƒ}|t|ƒi}|  |¡ q	| S )N)r   Úitemsr   r   Úappend)Zyaml_contentZupgraders_graph_mapZupgrader_nameZupgrader_graphZbytecode_tabler   r   r   r
   Úgenerate_upgraders_bytecode   s   
r   Ú__main__z)This file is not meant to be run directlyN)	Útypingr   Ztorch._Cr   r   r   r   Ú__name__ÚRuntimeErrorr   r   r   r
   Ú<module>   s    
ÿ