File tree Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Expand file tree Collapse file tree 1 file changed +3
-1
lines changed Original file line number Diff line number Diff line change @@ -3849,7 +3849,9 @@ def _distribution_configuration(self, distribution):
3849
3849
if get_mp_parameters (distribution ):
3850
3850
distribution_config ["mp_parameters" ] = get_mp_parameters (distribution )
3851
3851
# first make sure torch_distributed is enabled if instance type is p5
3852
- torch_distributed_enabled = distribution .get ("torch_distributed" ).get ("enabled" , False )
3852
+ torch_distributed_enabled = False
3853
+ if "torch_distributed" in distribution :
3854
+ torch_distributed_enabled = distribution .get ("torch_distributed" ).get ("enabled" , False )
3853
3855
smdistributed = distribution ["smdistributed" ]
3854
3856
smdataparallel_enabled = smdistributed .get ("dataparallel" , {}).get ("enabled" , False )
3855
3857
p5_enabled = "p5.48xlarge" in self .instance_type
You can’t perform that action at this time.
0 commit comments