From 7e778e21799d28941dcf4808fecb233c235807f7 Mon Sep 17 00:00:00 2001 From: Vivek Khandelwal Date: Wed, 3 Apr 2024 10:48:37 +0530 Subject: [PATCH] build: manually update PyTorch version (#3094) Set PyTorch and TorchVision version to nightly release 2024-04-01. Signed-Off By: Vivek Khandelwal --- build_tools/ci/build_posix.sh | 1 - .../Torch/Transforms/AbstractInterpLibrary.cpp | 18 ++++++++++++++++++ pytorch-hash.txt | 2 +- pytorch-requirements.txt | 2 +- torchvision-requirements.txt | 2 +- 5 files changed, 21 insertions(+), 4 deletions(-) diff --git a/build_tools/ci/build_posix.sh b/build_tools/ci/build_posix.sh index fec5e252e..bacb736ba 100755 --- a/build_tools/ci/build_posix.sh +++ b/build_tools/ci/build_posix.sh @@ -50,7 +50,6 @@ cmake -S "$repo_root/externals/llvm-project/llvm" -B "$build_dir" \ -DLLVM_EXTERNAL_TORCH_MLIR_SOURCE_DIR="$repo_root" \ -DLLVM_TARGETS_TO_BUILD=host \ -DMLIR_ENABLE_BINDINGS_PYTHON=ON \ - -DTORCH_MLIR_ENABLE_LTC=ON echo "::endgroup::" echo "::group::Build" diff --git a/lib/Dialect/Torch/Transforms/AbstractInterpLibrary.cpp b/lib/Dialect/Torch/Transforms/AbstractInterpLibrary.cpp index 38df3af98..444fdca68 100644 --- a/lib/Dialect/Torch/Transforms/AbstractInterpLibrary.cpp +++ b/lib/Dialect/Torch/Transforms/AbstractInterpLibrary.cpp @@ -5868,6 +5868,24 @@ StringRef mlir::torch::Torch::getAbstractInterpLibrary() { " %3 = torch.prim.TupleConstruct %1, %0, %0 : !torch.list, !torch.list, !torch.list -> !torch.tuple, list, list>\n" " return %3 : !torch.tuple, list, list>\n" " }\n" +" func.func @__torch__.torch.jit._shape_functions._batch_norm_with_update(%arg0: !torch.list, %arg1: !torch.optional>, %arg2: !torch.optional>, %arg3: !torch.optional>, %arg4: !torch.optional>) -> !torch.tuple, list, list, list> {\n" +" %int0 = torch.constant.int 0\n" +" %true = torch.constant.bool true\n" +" %int1 = torch.constant.int 1\n" +" %0 = torch.aten.__getitem__.t %arg0, %int1 : !torch.list, !torch.int -> !torch.int\n" +" %1 = torch.prim.ListConstruct %0 : (!torch.int) -> !torch.list\n" +" %2 = torch.prim.ListConstruct : () -> !torch.list\n" +" %3 = torch.aten.len.t %arg0 : !torch.list -> !torch.int\n" +" torch.prim.Loop %3, %true, init() {\n" +" ^bb0(%arg5: !torch.int):\n" +" %6 = torch.aten.__getitem__.t %arg0, %arg5 : !torch.list, !torch.int -> !torch.int\n" +" %7 = torch.aten.append.t %2, %6 : !torch.list, !torch.int -> !torch.list\n" +" torch.prim.Loop.condition %true, iter()\n" +" } : (!torch.int, !torch.bool) -> ()\n" +" %4 = torch.prim.ListConstruct %int0 : (!torch.int) -> !torch.list\n" +" %5 = torch.prim.TupleConstruct %2, %1, %1, %4 : !torch.list, !torch.list, !torch.list, !torch.list -> !torch.tuple, list, list, list>\n" +" return %5 : !torch.tuple, list, list, list>\n" +" }\n" " func.func @__torch__.torch.jit._shape_functions.cross_entropy_loss(%arg0: !torch.list, %arg1: !torch.list, %arg2: !torch.optional>, %arg3: !torch.int, %arg4: !torch.int, %arg5: !torch.float) -> !torch.list {\n" " %int-1 = torch.constant.int -1\n" " %true = torch.constant.bool true\n" diff --git a/pytorch-hash.txt b/pytorch-hash.txt index 54e47e2f1..09efb313d 100644 --- a/pytorch-hash.txt +++ b/pytorch-hash.txt @@ -1 +1 @@ -c823f7a4de48a06d5d57bb92556f772eea1aa83c +e1c8416590b718ab97e06089e57b650ae3909711 diff --git a/pytorch-requirements.txt b/pytorch-requirements.txt index 027c5377d..f16081073 100644 --- a/pytorch-requirements.txt +++ b/pytorch-requirements.txt @@ -1,3 +1,3 @@ -f https://download.pytorch.org/whl/nightly/cpu/torch_nightly.html --pre -torch==2.4.0.dev20240318 +torch==2.4.0.dev20240401 diff --git a/torchvision-requirements.txt b/torchvision-requirements.txt index 4110fce6b..d0862c1f5 100644 --- a/torchvision-requirements.txt +++ b/torchvision-requirements.txt @@ -1,3 +1,3 @@ -f https://download.pytorch.org/whl/nightly/cpu/torch_nightly.html --pre -torchvision==0.18.0.dev20240318 +torchvision==0.19.0.dev20240401