File tree Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Expand file tree Collapse file tree 1 file changed +2
-1
lines changed Original file line number Diff line number Diff line change 1919
2020import  torch 
2121from  huggingface_hub .utils  import  validate_hf_hub_args 
22+ from  typing_extensions  import  Self 
2223
2324from  ..quantizers  import  DiffusersAutoQuantizer 
2425from  ..utils  import  deprecate , is_accelerate_available , logging 
@@ -148,7 +149,7 @@ class FromOriginalModelMixin:
148149
149150    @classmethod  
150151    @validate_hf_hub_args  
151-     def  from_single_file (cls , pretrained_model_link_or_path_or_dict : Optional [str ] =  None , ** kwargs ):
152+     def  from_single_file (cls , pretrained_model_link_or_path_or_dict : Optional [str ] =  None , ** kwargs )  ->   Self :
152153        r""" 
153154        Instantiate a model from pretrained weights saved in the original `.ckpt` or `.safetensors` format. The model 
154155        is set in evaluation mode (`model.eval()`) by default. 
    
 
   
 
     
   
   
          
     
  
    
     
 
    
      
     
 
     
    You can’t perform that action at this time.
  
 
    
  
     
    
      
        
     
 
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments