+
    „°ñj  ã                   óÔ   € ^ RI Ht ^ RIt^ RIt^ RIt^ RIHtHt ^ RI	H
t
 R R ltR R lt ! R	 R
]P                  4      t ! R R]P                  4      t ! R R]4      tR R ltR# )é    )ÚoverrideN)ÚComfyExtensionÚio)Ú_DynamicGroupc                ó$   € V ^8„  d   QhR\         /# )é   Ú	lora_name)Ústr)Úformats   "ÚAC:\Ai_Coding\apps\studio\ComfyUI\comfy_extras\nodes_lora_stack.pyÚ__annotate__r   
   s   € ÷ Xñ Xœsñ Xó    c                 ót   € \         P                  ! R V 4      p\        P                  P	                  VRRR7      # )ÚlorasT)Ú	safe_loadÚreturn_metadata)Úfolder_pathsÚget_full_path_or_raiseÚcomfyÚutilsÚload_torch_file)r	   Ú	lora_paths   & r   Ú_load_lora_filer   
   s1   € Ü×3Ò3°G¸YÓG€IÜ�;‰;×&Ñ& y¸DÐRVÐ&ÓWÐWr   c                óN   € V ^8„  d   QhR\         \        P                  ,          /# ©r   Úreturn)Úlistr   ÚInput)r   s   "r   r   r      s   € ÷ ñ œœRŸX™X�ñ r   c            
      óú   € \         P                  P                  R \        P                  ! R4      RR7      \         P
                  P                  RRRRRRR	7      \         P                  P                  R
RRR7      .# )r	   r   z#The name of the LoRA file to apply.)ÚoptionsÚtooltipÚstrengthg      ð?g      Y@g{®Gáz„?zFHow strongly to apply this LoRA. 0 = off, negative inverts the effect.)ÚdefaultÚminÚmaxÚstepr!   ÚenabledTzATurn off to skip this LoRA without changing its file or strength.)r#   r!   g      YÀ)r   ÚCombor   r   Úget_filename_listÚFloatÚBoolean© r   r   Ú_lora_templater-      sv   € ä
�‰�‰�{¬L×,JÒ,JÈ7Ó,SØDð 	ó 	Fä
�‰�‰�z¨3°FÀÈDØgð 	ó 	iä
�
‰
×Ñ˜¨DØ!dð 	ó 	fðð r   c                   óL   a € ] tR t^t o ]R 4       t]V 3R lR l4       tRtV tR# )ÚLoadLoraModelc                ó  € \         P                  ! R R. RORR\         P                  P                  RRR7      \        P                  ! R\        4       ^^RR	R
7      .\         P                  P                  RR7      .R7      # )r/   zLoad LoRA (Model)úmodel/loaderszoApply a stack of LoRAs to a diffusion model. Add one row per LoRA; each row picks a LoRA file and its strength.Úmodelz1The diffusion model the LoRAs will be applied to.©r!   r   z'Each row applies one LoRA to the model.ÚLoRA©Útemplater$   r%   r!   Ú
group_namezThe modified diffusion model.©Únode_idÚdisplay_nameÚsearch_aliasesÚcategoryÚdescriptionÚinputsÚoutputs)Úloraú	load loraú
apply loraz
lora modelú
lora stack)r   ÚSchemaÚModelr   r   r-   ÚOutput©Úclss   &r   Údefine_schemaÚLoadLoraModel.define_schema   s|   € ä�yŠyØ#Ø,ÚZØ$ðGô —‘—‘˜wÐ0c�ÓdÜ×#Ò#ØÜ+Ó-ØØØEØ%ôð
ô —X‘X—_‘_Ð-L�_ÓMÐNô%
ð 	
r   c                óJ   <€ V ^8„  d   QhRS[ S[,          RS[P                  /# ©r   r   r   ©r   Údictr   Ú
NodeOutput)r   Ú__classdict__s   "€r   r   ÚLoadLoraModel.__annotate__3   s#   ø€ ÷ $ñ $¡4©¥:ð $±"·-±-ñ $r   c           
     ó  € V Fp  pVP                  R 4      pVR,          pV'       d   VR,          '       d   V^ 8X  d   K=  \        V4      w  rg\        P                  P	                  VRWe^ VR7      w  rKr  	  \
        P                  ! V4      # ©r	   r"   r'   N)Úlora_metadata©Úgetr   r   ÚsdÚload_lora_for_modelsr   rO   )	rH   r2   r   Úrowr	   r"   r@   ÚmetadataÚ_s	   &&&      r   ÚexecuteÚLoadLoraModel.execute2   sy   € ãˆCØŸ™ Ó,ˆIØ˜:•ˆHß C¨	§N¤N°hÀ!´mÙÜ,¨YÓ7‰NˆDÜ—x‘x×4Ñ4°U¸DÀ$ÐRSÐckÐ4Ól‰HˆE‘1ñ ô �}Š}˜UÓ#Ð#r   r,   N©	Ú__name__Ú
__module__Ú__qualname__Ú__firstlineno__ÚclassmethodrI   r\   Ú__static_attributes__Ú__classdictcell__©rP   s   @r   r/   r/      s+   ø‡ € Øñ
ó ð
ð, ÷$ó ö$r   r/   c                   óL   a € ] tR t^>t o ]R 4       t]V 3R lR l4       tRtV tR# )ÚLoadLoraTextEncoderc                ó  € \         P                  ! R R. RORR\         P                  P                  RRR7      \        P                  ! R\        4       ^^RR	R
7      .\         P                  P                  RR7      .R7      # )rh   zLoad LoRA (Text Encoder)r1   zqApply a stack of LoRAs to a CLIP text encoder. Add one row per LoRA; each row picks a LoRA file and its strength.Úclipz3The CLIP text encoder the LoRAs will be applied to.r3   r   z.Each row applies one LoRA to the text encoder.r4   r5   zThe modified CLIP text encoder.r8   )r@   rA   rB   z	clip lorarC   )r   rD   ÚClipr   r   r-   rF   rG   s   &r   rI   Ú!LoadLoraTextEncoder.define_schema?   s|   € ä�yŠyØ)Ø3ÚYØ$ðGô —‘—‘˜fÐ.c�ÓdÜ×#Ò#ØÜ+Ó-ØØØLØ%ôð
ô —W‘W—^‘^Ð,M�^ÓNÐOô%
ð 	
r   c                óJ   <€ V ^8„  d   QhRS[ S[,          RS[P                  /# rL   rM   )r   rP   s   "€r   r   Ú LoadLoraTextEncoder.__annotate__W   s#   ø€ ÷ #ñ #¡$¡t¥*ð #±·±ñ #r   c           
     ó  € V Fo  pVP                  R 4      pVR,          pV'       d   VR,          '       d   V^ 8X  d   K=  \        V4      w  rg\        P                  P	                  RW^ WWR7      w  r�Kq  	  \
        P                  ! V4      # rS   rU   )	rH   rj   r   rY   r	   r"   r@   rZ   r[   s	   &&&      r   r\   ÚLoadLoraTextEncoder.executeV   su   € ãˆCØŸ™ Ó,ˆIØ˜:•ˆHß C¨	§N¤N°hÀ!´mÙÜ,¨YÓ7‰NˆDÜ—h‘h×3Ñ3°D¸$ÀaÈÐ3Ój‰GˆA‰tñ ô �}Š}˜TÓ"Ð"r   r,   Nr^   rf   s   @r   rh   rh   >   s+   ø‡ € Øñ
ó ð
ð, ÷#ó ö#r   rh   c                   ó<   a € ] tR t^bt o ]V 3R lR l4       tRtV tR# )ÚLoraStackExtensionc                óT   <€ V ^8„  d   QhRS[ S[S[P                  ,          ,          /# r   )r   Útyper   Ú	ComfyNode)r   rP   s   "€r   r   ÚLoraStackExtension.__annotate__d   s"   ø€ ÷ 
ñ 
¡T©$©r¯|©|Õ*<Õ%=ñ 
r   c              ƒ  ó"   "  € \         \        .# 5i©N)r/   rh   )Úselfs   &r   Úget_node_listÚ LoraStackExtension.get_node_listc   s   é € ô Üð
ð 	
ùs   ‚r,   N)r_   r`   ra   rb   r   rz   rd   re   rf   s   @r   rr   rr   b   s   ø‡ € Ø÷
ó ö
r   rr   c                ó$   € V ^8„  d   QhR\         /# r   ©rr   )r   s   "r   r   r   k   s   € ÷  ñ  Ô 2ñ  r   c               ƒ   ó   "  € \        4       # 5irx   r}   r,   r   r   Úcomfy_entrypointr   k   s   é € ÜÓÐùs   ‚)Útyping_extensionsr   Úcomfy.sdr   Úcomfy.utilsr   Úcomfy_api.latestr   r   Úcomfy_api.latest._ior   r   r-   ru   r/   rh   rr   r   r,   r   r   Ú<module>r…      sU   ðÝ &ã Û Û ß /Ý .õXõ
ô!$�B—L‘Lô !$ôH!#˜"Ÿ,™,ô !#ôH
˜ô 
÷ r   