File tree Expand file tree Collapse file tree 1 file changed +4
-10
lines changed Expand file tree Collapse file tree 1 file changed +4
-10
lines changed Original file line number Diff line number Diff line change @@ -316,11 +316,8 @@ def test_fsdp_full_state_dict_load(
316
316
):
317
317
if use_hsdp :
318
318
pytest .xfail ('Known Pytorch issue with HSDP, waiting for pytorch patch' )
319
- if version .parse (torch .__version__ ) < version .parse ('2.3.0' ):
320
- if use_tp :
321
- pytest .skip ('TP requires torch 2.3.0 or later' )
322
- if use_hsdp :
323
- pytest .skip ('HSDP requires torch 2.3.0 or later' )
319
+ if (use_tp or use_hsdp ) and version .parse (torch .__version__ ) < version .parse ('2.3.0' ):
320
+ pytest .skip ('HSDP and TP require torch 2.3.0 or later' )
324
321
if autoresume :
325
322
run_name = 'my-cool-autoresume-run'
326
323
else :
@@ -838,11 +835,8 @@ def test_fsdp_partitioned_state_dict_load(
838
835
):
839
836
if weights_only and autoresume :
840
837
pytest .skip ('Weights only with autoresume is not supported' )
841
- if version .parse (torch .__version__ ) < version .parse ('2.3.0' ):
842
- if use_tp :
843
- pytest .skip ('TP requires torch 2.3.0 or later' )
844
- if use_hsdp :
845
- pytest .skip ('HSDP requires torch 2.3.0 or later' )
838
+ if (use_tp or use_hsdp ) and version .parse (torch .__version__ ) < version .parse ('2.3.0' ):
839
+ pytest .skip ('HSDP and TP require torch 2.3.0 or later' )
846
840
847
841
load_ignore_keys = [] if load_ignore_keys is None else load_ignore_keys
848
842
You can’t perform that action at this time.
0 commit comments