Skip to content

Commit a11e78b

Browse files
committed
Update base for Update on "[ET Device Support] Schema changes: device info on Tensor and buffer-level device array"
This diff adds device placement information to the ExecuTorch schema to support representing tensor-level device type information, which will be the basic requirement for the following tensor_parser updates. This is part of the Phase 1 implementation to make ET device type work E2E without user-specified device placement. Design doc: https://docs.google.com/document/d/1lwd9BlohmwkN5EEvRulO_b-XnZBwv1nMb5l2K3jfuwA/edit?tab=t.0#heading=h.o6anuvkix4bu Differential Revision: [D93635657](https://our.internmc.facebook.com/intern/diff/D93635657/) [ghstack-poisoned]
2 parents 380b705 + 569cf41 commit a11e78b

284 files changed

Lines changed: 12135 additions & 7594 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.
Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1 +1 @@
1-
659af3c353e49b35c191cdd2dba3b3c79d0e6822
1+
release/2.11

.ci/docker/common/install_pytorch.sh

Lines changed: 2 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -32,9 +32,9 @@ install_pytorch_and_domains() {
3232
pip_install "$(echo dist/*.whl)"
3333

3434
# Grab the pinned audio and vision commits from PyTorch
35-
TORCHAUDIO_VERSION=$(cat .github/ci_commit_pins/audio.txt)
35+
TORCHAUDIO_VERSION=release/2.11
3636
export TORCHAUDIO_VERSION
37-
TORCHVISION_VERSION=$(cat .github/ci_commit_pins/vision.txt)
37+
TORCHVISION_VERSION=release/0.26
3838
export TORCHVISION_VERSION
3939

4040
install_domains

.ci/scripts/export_model_artifact.sh

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -334,6 +334,7 @@ if [ "$MODEL_NAME" = "voxtral_realtime" ]; then
334334
VR_QUANT_ARGS="--qlinear-encoder 8da4w --qlinear 8da4w --qlinear-group-size 32 --qembedding 8w"
335335
elif [ "$QUANT_NAME" = "quantized-int4-metal" ]; then
336336
VR_QUANT_ARGS="--qlinear-encoder fpa4w --qlinear fpa4w"
337+
VR_DTYPE_ARGS="--dtype bf16"
337338
elif [ "$QUANT_NAME" = "quantized-int4-tile-packed" ]; then
338339
VR_QUANT_ARGS="--qlinear-encoder 4w --qlinear-encoder-packing-format tile_packed_to_4d --qlinear 4w --qlinear-packing-format tile_packed_to_4d --qembedding 8w"
339340
VR_DTYPE_ARGS="--dtype bf16"
@@ -373,6 +374,7 @@ if [ "$MODEL_NAME" = "voxtral_realtime" ]; then
373374
fi
374375
# Copy tokenizer from downloaded model weights
375376
cp "$LOCAL_MODEL_DIR/tekken.json" "${OUTPUT_DIR}/tekken.json"
377+
rm -rf "$LOCAL_MODEL_DIR"
376378
ls -al "${OUTPUT_DIR}"
377379
echo "::endgroup::"
378380
exit 0

.ci/scripts/test_lora.sh

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -139,7 +139,8 @@ Okay, so I need to calculate 15% of 80."
139139
EXPECTED_QUANT_LORA_PREFIX="
140140
<|im_start|>user Calculate 15% of 80?<|im_end|><|im_start|>assistant
141141
To calculate 15% of 80, we can multiply 80 by 15/100.
142-
So, 15% of 80 is equal to (80 * 15) / 100 = 1200 / 100 = 12.
142+
80 * 15/100 = 12.
143+
So, 15% of 80 is 12.
143144
#### 12
144145
The answer is: 12<|im_end|>"
145146

.ci/scripts/test_model_e2e.sh

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -248,7 +248,7 @@ if [ "$AUDIO_URL" != "" ]; then
248248
elif [[ "$MODEL_NAME" == *whisper* ]] || [ "$MODEL_NAME" = "voxtral_realtime" ]; then
249249
conda install -y -c conda-forge "ffmpeg<8"
250250
pip install datasets soundfile
251-
pip install torchcodec==0.11.0.dev20260217 --extra-index-url https://download.pytorch.org/whl/nightly/cpu
251+
pip install torchcodec==0.11.0 --extra-index-url https://download.pytorch.org/whl/test/cpu
252252
python -c "from datasets import load_dataset;import soundfile as sf;sample = load_dataset('distil-whisper/librispeech_long', 'clean', split='validation')[0]['audio'];sf.write('${MODEL_DIR}/$AUDIO_FILE', sample['array'][:sample['sampling_rate']*30], sample['sampling_rate'])"
253253
fi
254254

.ci/scripts/test_wheel_package_qnn.sh

Lines changed: 11 additions & 11 deletions
Original file line numberDiff line numberDiff line change
@@ -158,17 +158,17 @@ print(module_vars["TORCH_VERSION"])
158158
PY
159159
)
160160

161-
NIGHTLY_VERSION=$(
162-
"$PYBIN" - <<'PY'
163-
import runpy
164-
module_vars = runpy.run_path("torch_pin.py")
165-
print(module_vars["NIGHTLY_VERSION"])
166-
PY
167-
)
168-
echo "=== [$LABEL] Install torch==${TORCH_VERSION}.${NIGHTLY_VERSION} ==="
169-
170-
# Install torchao based on the pinned PyTorch version
171-
"$PIPBIN" install torch=="${TORCH_VERSION}.${NIGHTLY_VERSION}" --index-url "https://download.pytorch.org/whl/nightly/cpu"
161+
# NIGHTLY_VERSION=$(
162+
# "$PYBIN" - <<'PY'
163+
# import runpy
164+
# module_vars = runpy.run_path("torch_pin.py")
165+
# print(module_vars["NIGHTLY_VERSION"])
166+
# PY
167+
# )
168+
echo "=== [$LABEL] Install torch==${TORCH_VERSION} ==="
169+
170+
# Install torch based on the pinned PyTorch version, preferring the PyTorch test index
171+
"$PIPBIN" install torch=="${TORCH_VERSION}" --extra-index-url "https://download.pytorch.org/whl/test"
172172
"$PIPBIN" install wheel
173173

174174
# Install torchao based on the pinned commit from third-party/ao submodule

.ci/scripts/utils.sh

Lines changed: 3 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -53,7 +53,7 @@ dedupe_macos_loader_path_rpaths() {
5353
pushd ..
5454
torch_lib_dir=$(python -c "import importlib.util; print(importlib.util.find_spec('torch').submodule_search_locations[0])")/lib
5555
popd
56-
56+
5757
if [[ -z "${torch_lib_dir}" || ! -d "${torch_lib_dir}" ]]; then
5858
return
5959
fi
@@ -141,9 +141,9 @@ install_pytorch_and_domains() {
141141

142142
dedupe_macos_loader_path_rpaths
143143
# Grab the pinned audio and vision commits from PyTorch
144-
TORCHAUDIO_VERSION=$(cat .github/ci_commit_pins/audio.txt)
144+
TORCHAUDIO_VERSION=release/2.11
145145
export TORCHAUDIO_VERSION
146-
TORCHVISION_VERSION=$(cat .github/ci_commit_pins/vision.txt)
146+
TORCHVISION_VERSION=release/0.26
147147
export TORCHVISION_VERSION
148148

149149
install_domains

.ci/scripts/wheel/pre_build_script.sh

Lines changed: 6 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -26,7 +26,12 @@ fi
2626
# we should update the core job in test-infra to enable long paths before
2727
# checkout to avoid needing to do this.
2828
pushd extension/llm/tokenizers
29-
git submodule update --init
29+
UNAME_S=$(uname -s)
30+
if [[ $UNAME_S == *"MINGW"* || $UNAME_S == *"MSYS"* ]]; then
31+
git -c http.sslBackend=openssl submodule update --init
32+
else
33+
git submodule update --init
34+
fi
3035
popd
3136

3237
# On Windows, enable symlinks and re-checkout the current revision to create

.github/pytorch-probot.yml

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -3,6 +3,8 @@ tracking_issue: 7679
33
ciflow_push_tags:
44
- ciflow/android
55
- ciflow/apple
6+
- ciflow/cuda
7+
- ciflow/metal
68
- ciflow/nightly
79
- ciflow/trunk
810
- ciflow/binaries

.github/workflows/add-unanswered-to-project.yml

Lines changed: 4 additions & 4 deletions
Original file line numberDiff line numberDiff line change
@@ -50,10 +50,10 @@ jobs:
5050
"Jerry-Ge", "gggekov", "fumchin", "wwwind", "benkli01", "Tessil", "maddun01", "Michiel-Olieslagers", "armwaheed", "agrima1304",
5151
"emmakujala", "annietllnd", "MatthiasHertel80", "AlexTawseArm", "jmahbs", "morgolock", "Christoffer-JL", "ArmRyan", "xingguo01",
5252
"tgonzalezorlandoarm", "chizkiyahu", "sarah-blades", "itsMarco-G", "usamahz", "haowhsu-quic", "shewu-quic", "winskuo-quic",
53-
"chunit-quic", "DannyYuyang-quic", "chuntl", "thchenqti", "jethroqti", "chenweng-quic", "cymbalrush", "DenisVieriu97", "billmguo",
54-
"StrycekSimon", "jirioc", "robert-kalmar", "skywall", "MartinPavella", "roman-janik-nxp", "novak-vaclav", "neuropilot-captain",
55-
"dijopaul", "cad-rlc", "cad-audio", "ynimmaga", "daniil-lyakhov", "emmanuel-ferdman", "cavusmustafa", "anzr299", "suryasidd",
56-
"Jiseong-oh", "alexdean08",
53+
"chunit-quic", "DannyYuyang-quic", "chuntl", "thchenqti", "jethroqti", "chenweng-quic", "qti-horodnic", "qti-mmadhava", "quic-boyuc",
54+
"cymbalrush", "DenisVieriu97", "billmguo", "StrycekSimon", "jirioc", "robert-kalmar", "skywall", "MartinPavella", "roman-janik-nxp",
55+
"novak-vaclav", "neuropilot-captain", "dijopaul", "cad-rlc", "cad-audio", "ynimmaga", "daniil-lyakhov", "emmanuel-ferdman",
56+
"cavusmustafa", "anzr299", "suryasidd", "Jiseong-oh", "alexdean08",
5757
// explicitly include the dependabot bot login seen in PRs
5858
"dependabot[bot]"
5959
]);

0 commit comments

Comments
 (0)