File tree Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Expand file tree Collapse file tree 1 file changed +8
-5
lines changed Original file line number Diff line number Diff line change @@ -155,8 +155,8 @@ func (s *VllmSimulator) Start(ctx context.Context) error {
155155	}
156156
157157	// For Data Parallel, start data-parallel-size - 1 additional simulators 
158+ 	g , ctx  :=  errgroup .WithContext (ctx )
158159	if  s .config .DPSize  >  1  {
159- 		g , ctx  :=  errgroup .WithContext (context .Background ())
160160		for  i  :=  2 ; i  <=  s .config .DPSize ; i ++  {
161161			newConfig , err  :=  s .config .Copy ()
162162			if  err  !=  nil  {
@@ -173,12 +173,15 @@ func (s *VllmSimulator) Start(ctx context.Context) error {
173173				return  newSim .startSim (ctx )
174174			})
175175		}
176- 		if  err  :=  g .Wait (); err  !=  nil  {
177- 			return  err 
178- 		}
179176		s .logger  =  klog .LoggerWithValues (s .logger , "rank" , 0 )
180177	}
181- 	return  s .startSim (ctx )
178+ 	g .Go (func () error  {
179+ 		return  s .startSim (ctx )
180+ 	})
181+ 	if  err  :=  g .Wait (); err  !=  nil  {
182+ 		return  err 
183+ 	}
184+ 	return  nil 
182185}
183186
184187func  (s  * VllmSimulator ) startSim (ctx  context.Context ) error  {
 
 
   
 
     
   
   
          
    
    
     
    
      
     
     
    You can’t perform that action at this time.
  
 
    
  
    
      
        
     
       
      
     
   
 
    
    
  
 
  
 
     
    
0 commit comments