Skip to content

Commit d0a3cb4

Browse files
build: manually update PyTorch version (#3896)
This commit sets the PyTorch and TorchVision version to nightly release 2024-12-01. This commit also updates the test checks in `test/python/fx_importer/v2.3/auto_functionalized.py`. Failing tests are tracked through #3796. --------- Signed-off-by: Vivek Khandelwal <[email protected]>
1 parent 5077090 commit d0a3cb4

File tree

5 files changed

+18
-27
lines changed

5 files changed

+18
-27
lines changed

projects/pt1/e2e_testing/xfail_sets.py

Lines changed: 9 additions & 20 deletions
Original file line numberDiff line numberDiff line change
@@ -464,8 +464,6 @@
464464
"ReduceMaxAlongDimUnsignedInt_basic",
465465
"ReduceMinAlongDimUnsignedInt_basic",
466466
"ScalarImplicitFloatModule_basic",
467-
"SortIntListReverse_basic",
468-
"SortIntList_basic",
469467
"SplitDimDynamicModule_basic",
470468
"SplitDimStaticModule_basic",
471469
"SqrtIntModule_basic",
@@ -504,30 +502,21 @@
504502
"CrossEntropyLossNoReductionModule_basic",
505503
"ElementwiseExpm1IntModule_basic",
506504
"ElementwiseExpm1Module_basic",
507-
"IndexPutImpl1DFloatAccumulateModule_basic",
508-
"IndexPutImpl1DFloatNonAccumulateModule_basic",
509-
"IndexPutImpl1DIntAccumulateModule_basic",
510-
"IndexPutImpl1DIntNonAccumulateModule_basic",
511-
"IndexPutImpl2DFloatNonAccumulateModule_basic",
512-
"IndexPutImpl2DImplicitModule_basic",
513-
"IndexPutImpl2DIndexModule_basic",
514-
"IndexPutImpl2DNoneIndexStaticModule_basic",
515-
"IndexPutImpl3DFloatNonAccumulateModule_basic",
516-
"IndexPutImplIndexWithNoneModule_basic",
517505
"IsInfiniteModule_basic",
518506
"InterpolateDynamicModule_sizes_nearest",
519507
"IouOfModule_basic",
520508
"MeshgridIndexingIJ_basic",
521509
"MeshgridIndexingXY_basic",
522510
"Meshgrid_basic",
523-
"OneHotModule_basic",
524511
# RuntimeError: cannot mutate tensors with frozen storage
525-
"ElementwiseRreluTrainModule_basic",
526-
"ElementwiseRreluTrainStaticModule_basic",
527512
"ElementwiseRreluWithNoiseTrainModule_basic",
528513
"ElementwiseRreluWithNoiseTrainStaticModule_basic",
529514
"ElementwiseSignbitModule_basic",
530515
"ElementwiseCopysignModule_basic",
516+
"BernoulliFloatModule_basic",
517+
"BernoulliTensorModule_basic",
518+
"UniformModule_basic",
519+
"UniformStaticShapeModule_basic",
531520
}
532521

533522
FX_IMPORTER_CRASHING_SET = LINALG_CRASHING_SET | {
@@ -856,8 +845,6 @@
856845
"ScatterValueFloatModule_basic",
857846
"ScatterValueIntModule_basic",
858847
"SliceOutOfLowerBoundEndIndexModule_basic",
859-
"SortIntListReverse_basic",
860-
"SortIntList_basic",
861848
"SortTensorDescending_basic",
862849
"SortTensorInteger_basic",
863850
"SortTensorNegativeDimension_basic",
@@ -932,7 +919,6 @@
932919
"MeshgridIndexingXY_basic",
933920
"Meshgrid_basic",
934921
"MulIntModule_basic",
935-
"OneHotModule_basic",
936922
"ReduceFrobeniusNormComplexModule_basic",
937923
"ScalarImplicitIntModule_basic",
938924
"ScaledDotProductAttentionBoolMaskModule_basic",
@@ -951,10 +937,11 @@
951937
"UpSampleNearest2dStaticSize_basic",
952938
"UpSampleNearest2d_basic",
953939
# RuntimeError: cannot mutate tensors with frozen storage
954-
"ElementwiseRreluTrainModule_basic",
955-
"ElementwiseRreluTrainStaticModule_basic",
956940
"ElementwiseRreluWithNoiseTrainModule_basic",
957941
"ElementwiseRreluWithNoiseTrainStaticModule_basic",
942+
"BernoulliFloatModule_basic",
943+
"UniformModule_basic",
944+
"UniformStaticShapeModule_basic",
958945
}
959946

960947
FX_IMPORTER_STABLEHLO_CRASHING_SET = {
@@ -979,6 +966,8 @@
979966
# torch export: RuntimeError: cannot mutate tensors with frozen storage
980967
"ElementwiseRreluWithNoiseTrainModule_basic",
981968
"ElementwiseRreluWithNoiseTrainStaticModule_basic",
969+
"CrossEntropyLossModule_basic",
970+
"CrossEntropyLossNoReductionModule_basic",
982971
}
983972

984973
STABLEHLO_PASS_SET = {

pytorch-hash.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
0d5247caf3ffd618d31cf4cf880c47b7dbd323a7
1+
798d5b7ddd08899fb62672d56044dbf1f63a4d17

pytorch-requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
-f https://download.pytorch.org/whl/nightly/cpu/torch/
22
--pre
3-
torch==2.6.0.dev20241107
3+
torch==2.6.0.dev20241201

test/python/fx_importer/v2.3/auto_functionalized.py

Lines changed: 6 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -59,8 +59,9 @@ def forward(self, x):
5959
# AssertionError: Current active mode <torch._subclasses.functional_tensor.FunctionalTensorMode object at 0x7a1106504fd0> not registered
6060
decomposition_table=[],
6161
)
62-
# CHECK: %[[TIED:.*]] = torch.operator "torch.torch_mlir_test.inplace_modify"({{.*}}) : (!torch.vtensor<[3,4],f32>) -> !torch.vtensor<[3,4],f32>
63-
# CHECK: torch.aten.mul.Tensor %[[TIED]], %[[TIED]]
62+
# The Torch 2.6 expects the IR to be same as the below one, while the torch versions < 2.6 does not, hence this check is kept as a "COM".
63+
# COM: torch.operator "torch.torch_mlir_test.inplace_modify"({{.*}}) : (!torch.vtensor<[3,4],f32>) -> ()
64+
# CHECK: torch.aten.mul.Tensor %{{.*}}, %{{.*}}
6465
print(m)
6566
m.operation.verify()
6667

@@ -86,7 +87,8 @@ def forward(self, x):
8687
# AssertionError: Current active mode <torch._subclasses.functional_tensor.FunctionalTensorMode object at 0x7a1106504fd0> not registered
8788
decomposition_table=[],
8889
)
89-
# CHECK: %[[TIED:.*]]:2 = torch.operator "torch.torch_mlir_test.inplace_modify_calc"(%0) : (!torch.vtensor<[3,4],f32>) -> (!torch.vtensor<[3,4],f32>, !torch.vtensor<[3,4],f32>)
90-
# CHECK: torch.aten.mul.Tensor %[[TIED]]#1, %[[TIED]]#0
90+
# The Torch 2.6 expects the IR to be same as the below one, while the torch versions < 2.6 does not, hence this check is kept as a "COM".
91+
# COM: %[[TIED:.*]] = torch.operator "torch.torch_mlir_test.inplace_modify_calc"(%arg0) : (!torch.vtensor<[3,4],f32>) -> !torch.vtensor<[3,4],f32>
92+
# CHECK: torch.aten.mul.Tensor %{{.*}}, %{{.*}}
9193
print(m)
9294
m.operation.verify()

torchvision-requirements.txt

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,3 +1,3 @@
11
-f https://download.pytorch.org/whl/nightly/cpu/torchvision/
22
--pre
3-
torchvision==0.20.0.dev20241107
3+
torchvision==0.20.0.dev20241201

0 commit comments

Comments
 (0)