Skip to content

Commit

Permalink
Bump PT pin to 20241028 (#1419)
Browse files Browse the repository at this point in the history
* Bump PT pin to 20241014

* Push bump to 1028 and add migration to export_for_training
  • Loading branch information
Jack-Khuu authored Dec 12, 2024
1 parent 4fdbe10 commit 7b86dc3
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions install/install_requirements.sh
Original file line number Diff line number Diff line change
Expand Up @@ -62,10 +62,10 @@ echo "Using pip executable: $PIP_EXECUTABLE"
# NOTE: If a newly-fetched version of the executorch repo changes the value of
# PYTORCH_NIGHTLY_VERSION, you should re-run this script to install the necessary
# package versions.
PYTORCH_NIGHTLY_VERSION=dev20241013
PYTORCH_NIGHTLY_VERSION=dev20241028

# Nightly version for torchvision
VISION_NIGHTLY_VERSION=dev20241013
VISION_NIGHTLY_VERSION=dev20241028

# Nightly version for torchtune
TUNE_NIGHTLY_VERSION=dev20241013
Expand Down
4 changes: 2 additions & 2 deletions torchchat/export.py
Original file line number Diff line number Diff line change
Expand Up @@ -122,7 +122,7 @@ def export_for_server(
from executorch.exir.tracer import Value

from torch._export import capture_pre_autograd_graph
from torch.export import export, ExportedProgram
from torch.export import export, export_for_training, ExportedProgram

from torchchat.model import apply_rotary_emb, Attention
from torchchat.utils.build_utils import get_precision
Expand Down Expand Up @@ -238,7 +238,7 @@ def _to_core_aten(
raise ValueError(
f"Expected passed in model to be an instance of fx.GraphModule, got {type(model)}"
)
core_aten_ep = export(model, example_inputs, dynamic_shapes=dynamic_shapes)
core_aten_ep = export_for_training(model, example_inputs, dynamic_shapes=dynamic_shapes)
if verbose:
logging.info(f"Core ATen graph:\n{core_aten_ep.graph}")
return core_aten_ep
Expand Down

0 comments on commit 7b86dc3

Please sign in to comment.