Skip to content
Draft
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
180 commits
Select commit Hold shift + click to select a range
51c4a5a
Vulkan tests use executorch_core
kirklandsign May 8, 2025
4863988
Handle avg_pool2d with padding == 0 as no padding
3l1 May 8, 2025
bf5b99a
Update buck2 to 2025-05-06 (#10742)
swolchok May 8, 2025
bb7e50f
Tests use executorch_core
kirklandsign May 8, 2025
b1d00e2
[ET-VK] Introduce generic export pass for fusing Q/DQ nodes (#10771)
pytorchbot May 8, 2025
5e8295e
[ET-VK] Implement linear_qcs4w (#10772)
pytorchbot May 8, 2025
d9c6f80
Arm backend: Add model name to -llama_inputs (#10775)
mansnils May 8, 2025
3c21e3a
Arm Backend: Update unit tests for TOSA 1.0 (#10776)
SaoirseARM May 8, 2025
6346bfd
Automatically announce declared options (#10766)
jathu May 8, 2025
c352813
Arm backend: Remove redundant validation check for op_where (#10773)
Sebastian-Larsson May 8, 2025
d24eda4
Arm backend: Replace asserts with exceptions in permutation code (#10…
Sebastian-Larsson May 8, 2025
a37b369
Minor vector sizing change. (#10753)
trivedivivek May 8, 2025
380c4f1
Allow options to be set by presets (#10767)
jathu May 8, 2025
d25ce54
Convert the unit test from java to kotlin (#10702)
phaiting May 8, 2025
ac26555
Create a macos-arm64 preset (#10768)
jathu May 8, 2025
5ad676d
Extract trace from prepare_and_convert and remove export_program
mcremon-meta May 8, 2025
277c39d
Make constant_folding's _DEFAULT_SKIP_TARGETS public
ThomasJannaud May 8, 2025
b1b46ee
: constant fold None
ThomasJannaud May 9, 2025
6e3cb79
to make TIE quantized conv operator to fall back to hifi quantized co…
wl1026sun May 9, 2025
01a5d81
Arm Backend: Use tosa_ref_model only if it is avaiable
digantdesai May 9, 2025
7e1f3e3
Use std::align_alloc in file_data_loader
lucylq May 9, 2025
6759d35
fix transpose / permutations fusion pass
ThomasJannaud May 9, 2025
54a14d9
Arm backend: Suppress colors in pre-push if non-interactive (#10783)
perheld May 9, 2025
f7c906f
Cortex-M: Use q/dq ops in Arm Ethos Runner (#10782)
digantdesai May 9, 2025
b98c3ab
Save some size in pattern/{bitwise,comparison}_op.h (#10489)
swolchok May 9, 2025
80752f4
Reapply #9842: Save some size in dtype_util when dtype selective buil…
swolchok May 9, 2025
f688329
Reapply #9841: Migrate elementwise_util callers to the variants with …
swolchok May 9, 2025
b866837
Use torchtune 0.6.1 (#10792)
kirklandsign May 9, 2025
6e959be
bugfix
digantdesai May 9, 2025
bf50527
fix bug with sequential backends
mcr229 May 9, 2025
1c2b7ba
Remove FLATC_EXECUTABLE and the ability to bring your own flatc (#10781)
jathu May 9, 2025
b173722
Introduce assertj test lib to make the throw exception test more accu…
phaiting May 10, 2025
fbb3ad1
Arm backend: Fix ensures check in UnsqueezeScalarPlaceholdersPass (#1…
YufengShi-dudu May 12, 2025
4909db1
Arm backend: Update rescale to handle more dtypes
oscarandersson8218 May 2, 2025
fa2e1f2
Arm backend: Rename const-tensors for TOSA 1.0
oscarandersson8218 May 6, 2025
0a30c42
NXP Backend: Add eIQ Neutron Backend (#10196)
robert-kalmar May 12, 2025
b11807c
[llava] Remove torch.jit.save in llava example
larryliu0820 May 12, 2025
e113c00
Move EXECUTORCH_PAL_DEFAULT to default preset (#10798)
jathu May 12, 2025
adde519
Make a separate target for kernel utils (#10788)
kirklandsign May 12, 2025
4e5ffa3
[ET-VK] Return fence after waiting is done. (#10808)
pytorchbot May 12, 2025
500842a
Update backends-coreml.md (#10816)
metascroy May 12, 2025
a868166
Xnnpack test for program-data separation (#10817)
pytorchbot May 12, 2025
42b55f4
Move EXECUTORCH_LOG_LEVEL to default preset (#10799)
jathu May 12, 2025
d966a47
Forward-fixing G3 lt kernel
mcremon-meta May 12, 2025
e3a6825
Move EXECUTORCH_ENABLE_PROGRAM_VERIFICATION to default preset (#10800)
jathu May 12, 2025
d4c9a30
[jit] Remove TorchScript from doc (#10825)
larryliu0820 May 12, 2025
2e890df
Android Qwen thinking mode prompt support (#10668)
kirklandsign May 12, 2025
27e159e
mediatek llama runner use executorch_core (#10754)
kirklandsign May 12, 2025
1da5168
Rename "topic: not user facing" (#10828)
pytorchbot May 12, 2025
df8fc61
[jit] Remove @torch.jit.export (#10824)
larryliu0820 May 12, 2025
4a738bd
Move EXECUTORCH_ENABLE_EVENT_TRACER to default preset (#10801)
jathu May 12, 2025
4006cd2
Refactor _to_edge_and_lower_llama to remove args
jackzhxng May 13, 2025
2ee2e03
Move OPTIMIZE_SIZE to default preset (#10802)
jathu May 13, 2025
756f86a
Delete EXECUTORCH_BUILD_ANDROID_JNI (#10803)
jathu May 13, 2025
d7201ab
[Executorch][llm] Add support for ring kv cache and ring attention (#…
pytorchbot May 13, 2025
6f4df1a
Refactor _get_source_transforms to remove args
jackzhxng May 13, 2025
473c77b
Move simple options to default preset (#10804)
jathu May 13, 2025
aa73a55
Default to file load mode in module (#10827)
GregoryComer May 13, 2025
19d3bce
[ET-VK] Removing un used push constants for conv2d pw. (#10841)
pytorchbot May 13, 2025
65d931e
Correct model name in examples/arm/run.sh (#10815)
mansnils May 13, 2025
b30f912
Use certifi certs for buck download (#10095)
GregoryComer May 13, 2025
7993bb2
Arm backend: Update partitioner de-tagging iteration order (#10813)
oscarandersson8218 May 13, 2025
dcd25eb
Arm backend: Refactor pass tests for TOSA V1.0 (#10843)
oscarandersson8218 May 13, 2025
f8e7264
Move dependent options to default preset (#10805)
jathu May 13, 2025
0bb059f
[Executorch][llm] Add ring buffer based kv cache and mask calculation…
pytorchbot May 13, 2025
e71b3aa
Arm backend: Fix mypy linting in pre-push (#10850)
AdrianLundell May 13, 2025
e7ec913
Delete executorch_print_configuration_summary (#10806)
jathu May 13, 2025
0b231c4
[Executorch][llm] Make custom update cache op operate on indices (#10…
pytorchbot May 13, 2025
d338eea
Update ownership for the build system (#10837)
jathu May 13, 2025
3ffe697
Add floatValue to ExecuTorch value
f-meloni May 13, 2025
ef30b25
[Executorch][llm] Enable leveraging ring kv cache via module swap (#1…
pytorchbot May 13, 2025
f1ef702
Qualcomm AI Engine Direct - Flags for CI (#9536)
winskuo-quic May 13, 2025
d0360b7
BUCK forward fix on NXP backend
iseeyuan May 13, 2025
e13b086
Arm backend: Merge decompose/convert meandim pass (#10844)
AdrianLundell May 13, 2025
518324f
Build flatcc for the host (#10855)
jathu May 13, 2025
d0b4ed6
Arm backend: Decompose sum in pass (#10852)
AdrianLundell May 13, 2025
9ded0a2
Allow graceful handling of cpuinfo init failure
GregoryComer May 13, 2025
b20419d
Use the install method for flatc (#10859)
jathu May 13, 2025
4a89327
Remove EXECUTORCH_SEPARATE_FLATCC_HOST_PROJECT (#10860)
jathu May 13, 2025
abaee69
Update documents for Express SDK update (#10462)
neuropilot-captain May 14, 2025
62cf849
Update CI for HF Optimum models (#10820)
guangy10 May 14, 2025
ed80e3b
[LlamaDemo] Replace some tokens
kirklandsign May 14, 2025
001e5ef
Change lowbit example to use 4-bit as default in example (#10865)
metascroy May 14, 2025
a21022c
[Executorch][llm] Enable local global attention in export_llama scrip…
pytorchbot May 14, 2025
f785386
Arm backend: Update operator support for TOSA-1.0+INT+u55 (#10849)
per May 14, 2025
e1738cc
Arm backend: Update NEGATE with TOSA 1.0 support (#10845)
per May 14, 2025
fa5048b
Support prequant qwen3 (#10839)
metascroy May 14, 2025
101746e
Arm backend: Example external model to be used by the ahead of time a…
Juanfi8 May 14, 2025
12b5eb6
Add a pass to fuse mul.Scalar into dequant
mcremon-meta May 14, 2025
f39e694
fix Swift compiler assert (#10874)
rmaz May 14, 2025
587f2f8
[jit] Remove more reference to TorchScript (#10856)
larryliu0820 May 14, 2025
e7d39c2
Fix broken tests
jackzhxng May 14, 2025
d67fb52
Use the built-in notify crate for OSS Buck (#10884)
shoumikhin May 14, 2025
1b593ad
Recipe and Input class definitions with e2e export (#10034)
tarun292 May 15, 2025
c913634
Refactor quantize.py functions to remove args
jackzhxng May 15, 2025
5222489
Arm backend: Add validation for same dtype to operators (#10872)
Sebastian-Larsson May 15, 2025
ccabb2e
Arm backend: Refactor misc tests for TOSA V1.0 (#10851)
oscarandersson8218 May 15, 2025
b09e793
Arm backend: Increase atol, rtol to tosa_BI test in test_unary.py (#1…
fumchin May 15, 2025
02d315d
Arm backend: Check in tosa.fbs for TOSA 0.80 and 1.0 (#10870)
oscarandersson8218 May 15, 2025
b427188
Arm backend: Increase atol and rtol to tosa_BI test in test_conv_cons…
fumchin May 15, 2025
b058afb
Arm backend: Add test for DeiT Tiny for TOSA BI (#10846)
martinlsm May 15, 2025
9dece67
Arm backend: Add DecomposeLinalgVectorNorm pass + tests (#10848)
wwwind May 15, 2025
0121dae
Arm backend: Update parse_test_name script (#10902)
AdrianLundell May 15, 2025
43ab323
Arm backend: Add arange.default dummy tests (#10901)
AdrianLundell May 15, 2025
0a6f622
Arm Backend: Updated TosaPipelineBI default qtol (#10907)
SaoirseARM May 15, 2025
879235b
Introduce `platform-config` in CompileSpec for MediaTek backend (#10464)
neuropilot-captain May 15, 2025
56eb18b
Pipe in local_global attention (#10883)
jackzhxng May 15, 2025
47164cc
Update lint_urls.sh (#10919)
shoumikhin May 15, 2025
41063f7
Update llama runner README.md (#10869)
jackzhxng May 15, 2025
9f6c0f2
Update Qwen3 README.md (#10882)
jackzhxng May 15, 2025
a63a648
Default CMAKE_SYSTEM_PROCESSOR to the host (#10912)
jathu May 15, 2025
24789c8
Added debug logs for loading/executing model methods (#10915)
leafs1 May 15, 2025
78fe7ee
Define PYTHON_EXECUTABLE only once in cmake (#10911)
jathu May 15, 2025
7175ca4
Fix CatFromSliceCopyPass indexing issue.
abeakkas May 16, 2025
71767c3
Update javadoc in Module.java
kirklandsign May 16, 2025
bc0fdf3
Add getitem support in graph builder.
hsharma35 May 16, 2025
1244672
Don't build executor runner with Apple frameworks (#10933)
shoumikhin May 16, 2025
e09f33c
Android check pte exists
kirklandsign May 16, 2025
d069d65
Add pass to convert kwargs to args + populate optional args.
hsharma35 May 16, 2025
4b67dc9
Arm backend: Do not delegate casting to FP dtypes with BI profile (#1…
YufengShi-dudu May 16, 2025
12af535
Arm backend: Fix TOSA 1.0 node visitor for sum (#10908)
per May 16, 2025
6f015f6
Arm backend: Improve broadcasting (#10940)
oscarandersson8218 May 16, 2025
2ec8678
Arm backend: Refactor Quantizer test to allow for TOSA 1.0 (#10905)
SaoirseARM May 16, 2025
54e7c75
Arm backend: Add validation steps to op_neg (#10942)
Sebastian-Larsson May 16, 2025
94d1381
Arm backend: Reenable test_fuse_const_ops_tosa_BI (#10847)
martinlsm May 16, 2025
f39a1bb
Arm backend: Allocate the scratch buffer runtime rather than in the p…
gggekov May 16, 2025
5c6d4e5
Arm backend: Refactor test_scalars to new naming standard (#10944)
AdrianLundell May 16, 2025
fd87e98
Arm backend: Convert remaining asserts in operators to raise errors (…
Sebastian-Larsson May 16, 2025
8953279
Broadcast implementation in quantized_add
suvadeep89 May 16, 2025
a0d9c7e
Arm backend: Fix sigmoid int16 and int32 flakyness (#10548)
oscarandersson8218 May 16, 2025
8d53a28
Remove op_registration_util.bzl and rely on shim (#10935)
lucylq May 16, 2025
d0464f8
Sync shim_et/xplat/executorch/kernels/optimized/op_registration_util.…
lucylq May 16, 2025
d0848ca
Forward fix #10851 for arm backend
iseeyuan May 16, 2025
502db64
Create a pybind preset (#10932)
jathu May 16, 2025
d18a52d
Fix libflatccrt race (#10918)
jathu May 16, 2025
309faf8
Update ModuleTest.swift (#10948)
shoumikhin May 16, 2025
851b373
Make test_fuse_mul_into_dequant use GraphBuilder.
eigen-k May 16, 2025
9cce48d
Fix export llava (#10947)
jackzhxng May 16, 2025
7719d31
Mostly sync BlasKernel.cpp with ATen ReducedPrecisionGemvFastPathKern…
pytorchbot May 16, 2025
3cdc4b8
Update Android demo app README.md (#10922)
jackzhxng May 16, 2025
d9fcea1
Build pybind preset in CI (#10936)
jathu May 16, 2025
f8218d1
Copy executorch codegen from pytorch torchgen to executorch repo
larryliu0820 May 16, 2025
6f59e89
Android backend used by method
kirklandsign May 17, 2025
9aaea31
Add copy API to ExecuTorchValue (#10954)
bsoyluoglu May 17, 2025
9663bfb
Hook up PreprocessAll flow to EdgeManager
mcr229 May 18, 2025
7d9dd46
Arm backend: Remove fast scratch part for now
kirklandsign May 19, 2025
6ad47df
Arm backend: Do not run model unit tests in parallel (#10953)
zingo May 19, 2025
bb50792
init
anzr299 May 19, 2025
6925c5e
small fix
anzr299 May 19, 2025
5e23cb9
minor fix
anzr299 May 19, 2025
e04a901
add data aware wc
anzr299 May 19, 2025
fb5750e
minor fix
anzr299 May 19, 2025
de72d65
Delete redundant pybind workflows (#10957)
jathu May 19, 2025
78227f0
Suppport unary log in xnnpack delegate (#10952)
leafs1 May 19, 2025
3032398
Make test_no_replace_quant_permute_dequant_with_requantize use GraphB…
eigen-k May 19, 2025
95e27ed
Make test_replace_quant_view_dequant_with_requantize use GraphBuilder.
eigen-k May 19, 2025
ea9eeb8
add quantization support for disable_dynamic_shapes
anzr299 May 19, 2025
a905728
ToOutVarPass skips inplace ops
JacobSzwejbka May 19, 2025
770569d
minor fix
anzr299 May 19, 2025
e365e15
Add input size validation to Module.execute (#10701)
keyprocedure May 19, 2025
4d7b64e
support function + method variants
JacobSzwejbka May 19, 2025
b2f9ef9
Remove ReplaceTCopyWithTransform
mcremon-meta May 19, 2025
9aedbeb
Arm backend: Make the CI green by not testing Dedicated_Sram for the …
gggekov May 19, 2025
cb3eba0
Fix Windows build (#10946)
SS-JIA May 19, 2025
d1c2683
Qualcomm AI Engine Direct - fix for pytorch uplevel (#10769)
haowhsu-quic May 20, 2025
b73f9d5
Lint links for modified lines only on PR (#10994)
shoumikhin May 20, 2025
7d9b15f
Add etdump to android
kirklandsign May 20, 2025
40736e2
Move optimized target definitions to op_registration.bzl (#10986)
pytorchbot May 20, 2025
7d194cf
Add a android log implementation
kirklandsign May 20, 2025
56018e1
Dtype selective build for optimized ops (#10992)
pytorchbot May 20, 2025
9916cee
partitioner update
anzr299 May 20, 2025
379129d
Arm backend: Add support for BN fusing during QAT (#10967)
oscarandersson8218 May 20, 2025
d509ee3
Arm backend: Refactor models to allow for TOSA 1.0 (#10904)
SaoirseARM May 20, 2025
08dfe52
Arm backend: Adjust AvgPool2d padding when window is not divisible by…
tom-arm May 20, 2025
da62d5f
Arm backend: Clean up matmul tests (#10971)
oscarandersson8218 May 20, 2025
78779b0
Merge branch 'export_llama_executorch' into main
anzr299 May 20, 2025
3871a5f
Merge main
anzr299 May 20, 2025
0c20955
update for latest
anzr299 May 20, 2025
d3730ea
quant and fp16 temp fix
cavusmustafa Jun 5, 2025
3fef8fd
enable import override for export_to_edge with openvino
cavusmustafa Jun 6, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
1 change: 1 addition & 0 deletions .buckconfig
Original file line number Diff line number Diff line change
Expand Up @@ -39,6 +39,7 @@

[buck2]
restarter=true
file_watcher=notify

[oss]
folly_cxx_tests = False
2 changes: 1 addition & 1 deletion .ci/docker/ci_commit_pins/buck2.txt
Original file line number Diff line number Diff line change
@@ -1 +1 @@
2024-12-16
2025-05-06
16 changes: 5 additions & 11 deletions .ci/scripts/build-qnn-sdk.sh
100644 → 100755
Original file line number Diff line number Diff line change
Expand Up @@ -11,17 +11,12 @@ set -o xtrace

build_qnn_backend() {
echo "Start building qnn backend."
export ANDROID_NDK_ROOT=/opt/ndk
export QNN_SDK_ROOT=/tmp/qnn/2.28.0.241029
export ANDROID_NDK_ROOT=${ANDROID_NDK_ROOT:-/opt/ndk}
export QNN_SDK_ROOT=${QNN_SDK_ROOT:-/tmp/qnn/2.28.0.241029}
export EXECUTORCH_ROOT="$(cd -- "$(dirname -- "${BASH_SOURCE[0]}")/../.." && pwd)"

# Workaround to avoid issues around missing flatccrt library (depending on the
# number of jobs used), see issue #7300:
# Build twice (second time with `--no_clean`) to make sure libflatccrt.a is
# available.
# TODO: Remove this workaround once the underlying issue is fixed.
bash backends/qualcomm/scripts/build.sh --skip_aarch64 --job_number 2 --release || \
bash backends/qualcomm/scripts/build.sh --skip_aarch64 --job_number 2 --release --no_clean
parallelism=$(( $(nproc) - 1 ))
bash backends/qualcomm/scripts/build.sh --skip_aarch64 --job_number ${parallelism} --release
}

set_up_aot() {
Expand All @@ -39,8 +34,7 @@ set_up_aot() {
-DEXECUTORCH_BUILD_EXTENSION_MODULE=ON \
-DEXECUTORCH_BUILD_EXTENSION_TENSOR=ON \
-DEXECUTORCH_ENABLE_EVENT_TRACER=ON \
-DPYTHON_EXECUTABLE=python3 \
-DEXECUTORCH_SEPARATE_FLATCC_HOST_PROJECT=OFF
-DPYTHON_EXECUTABLE=python3
cmake --build $PWD --target "PyQnnManagerAdaptor" "PyQnnWrapperAdaptor" -j$(nproc)
# install Python APIs to correct import path
# The filename might vary depending on your Python and host version.
Expand Down
27 changes: 9 additions & 18 deletions .ci/scripts/test_llava.sh
Original file line number Diff line number Diff line change
Expand Up @@ -93,8 +93,7 @@ cmake_build_llava_runner_for_android() {
-DCMAKE_TOOLCHAIN_FILE=$ANDROID_NDK/build/cmake/android.toolchain.cmake \
-DANDROID_ABI=arm64-v8a \
${LLAVA_COMMON_CMAKE_ARGS} \
-DCMAKE_PREFIX_PATH="$python_lib" \
-DLLAVA_RUNNER_NO_TORCH_DUMMY_IMAGE=ON \
-DCMAKE_PREFIX_PATH="$python_lib" \
-B${BUILD_DIR}/${dir} \
${dir}

Expand All @@ -107,11 +106,10 @@ export_llava() {
$PYTHON_EXECUTABLE -m executorch.examples.models.llava.export_llava --pte-name llava.pte --with-artifacts
}

# Download a new image with different size, to test if the model can handle different image sizes
prepare_image_tensor() {
# Download a new image
download_image() {
echo "Downloading image"
curl -o basketball.jpg https://upload.wikimedia.org/wikipedia/commons/7/73/Chicago_Bulls_and_New_Jersey_Nets%2C_March_28%2C_1991.jpg
$PYTHON_EXECUTABLE -m executorch.examples.models.llava.image_util --image-path basketball.jpg --output-path image.pt
}

run_and_verify() {
Expand All @@ -121,20 +119,18 @@ run_and_verify() {
echo "Export failed. Abort"
exit 1
fi
if [[ ! -f "image.pt" ]]; then
echo "image.pt is missing."
if [[ ! -f "basketball.jpg" ]]; then
echo "basketball.jpg is missing."
exit 1
fi
if [[ ! -f "tokenizer.bin" ]]; then
echo "tokenizer.bin is missing."
exit 1
fi



RUNTIME_ARGS="--model_path=llava.pte \
--tokenizer_path=tokenizer.bin \
--image_path=image.pt \
--image_path=basketball.jpg \
--prompt=ASSISTANT: \
--temperature=0 \
--seq_len=650"
Expand All @@ -149,13 +145,8 @@ run_and_verify() {

# verify result.txt
RESULT=$(cat result.txt)
# set the expected prefix to be the same as prompt because there's a bug in sdpa_with_kv_cache that causes <unk> tokens.
if [[ "$(uname)" == "Darwin" ]]; then
EXPECTED_PREFIX="ASSISTANT: image captures a basketball game in progress, with several players on the court. One of the players is dribbling the ball, while the others are in various"
else
# set the expected prefix to be the same as prompt because there's a bug in sdpa_with_kv_cache that causes <unk> tokens.
EXPECTED_PREFIX="ASSISTANT: image"
fi
EXPECTED_PREFIX="ASSISTANT: image captures a basketball game in progress, with several players on the court. "

if [[ "${RESULT}" == *"${EXPECTED_PREFIX}"* ]]; then
echo "Expected result prefix: ${EXPECTED_PREFIX}"
echo "Actual result: ${RESULT}"
Expand Down Expand Up @@ -184,5 +175,5 @@ fi
export_llava

# Step3. Run
prepare_image_tensor
download_image
run_and_verify
6 changes: 1 addition & 5 deletions .ci/scripts/test_model.sh
Original file line number Diff line number Diff line change
Expand Up @@ -87,10 +87,6 @@ test_model() {
bash examples/models/llava/install_requirements.sh
STRICT="--no-strict"
fi
if [[ "$MODEL_NAME" == "llama3_2_vision_encoder" || "$MODEL_NAME" == "llama3_2_text_decoder" ]]; then
# Install requirements for llama vision.
bash examples/models/llama3_2_vision/install_requirements.sh
fi
if [[ "${MODEL_NAME}" == "qwen2_5" ]]; then
# Install requirements for export_llama
bash examples/models/llama/install_requirements.sh
Expand Down Expand Up @@ -205,7 +201,7 @@ test_model_with_qnn() {
# TODO(guangyang): Make QNN chipset matches the target device
QNN_CHIPSET=SM8450

"${PYTHON_EXECUTABLE}" -m examples.qualcomm.scripts.${EXPORT_SCRIPT} -b ${CMAKE_OUTPUT_DIR} -m ${QNN_CHIPSET} --compile_only $EXTRA_FLAGS
"${PYTHON_EXECUTABLE}" -m examples.qualcomm.scripts.${EXPORT_SCRIPT} -b ${CMAKE_OUTPUT_DIR} -m ${QNN_CHIPSET} --ci --compile_only $EXTRA_FLAGS
EXPORTED_MODEL=$(find "./${EXPORT_SCRIPT}" -type f -name "${MODEL_NAME}*.pte" -print -quit)
}

Expand Down
3 changes: 0 additions & 3 deletions .ci/scripts/unittest-linux.sh
Original file line number Diff line number Diff line change
Expand Up @@ -24,9 +24,6 @@ if [[ "$BUILD_TOOL" == "cmake" ]]; then
CMAKE_ARGS="-DEXECUTORCH_BUILD_PYBIND=ON -DEXECUTORCH_BUILD_XNNPACK=ON -DEXECUTORCH_BUILD_KERNELS_QUANTIZED=ON" \
.ci/scripts/setup-linux.sh "$@"

# Install llama3_2_vision dependencies.
PYTHON_EXECUTABLE=python ./examples/models/llama3_2_vision/install_requirements.sh

.ci/scripts/unittest-linux-cmake.sh
elif [[ "$BUILD_TOOL" == "buck2" ]]; then
# Removing this breaks sccache in the Buck build, apparently
Expand Down
1 change: 0 additions & 1 deletion .ci/scripts/unittest-macos.sh
Original file line number Diff line number Diff line change
Expand Up @@ -29,7 +29,6 @@ if [[ "$BUILD_TOOL" == "cmake" ]]; then
# Install llama3_2_vision dependencies.
PYTHON_EXECUTABLE=python \
${CONDA_RUN} --no-capture-output \
./examples/models/llama3_2_vision/install_requirements.sh

.ci/scripts/unittest-macos-cmake.sh
elif [[ "$BUILD_TOOL" == "buck2" ]]; then
Expand Down
8 changes: 4 additions & 4 deletions .github/scripts/label_utils.py
Original file line number Diff line number Diff line change
Expand Up @@ -22,12 +22,12 @@

LABEL_ERR_MSG_TITLE = "This PR needs a `release notes:` label"
LABEL_ERR_MSG = f"""# {LABEL_ERR_MSG_TITLE}
If your changes are user facing and intended to be a part of release notes, please use a label starting with `release notes:`.
If your change should be included in the release notes (i.e. would users of this library care about this change?), please use a label starting with `release notes:`.

If not, please add the `topic: not user facing` label.
If not, please add the `release notes: none` label.

To add a label, you can comment to pytorchbot, for example
`@pytorchbot label "topic: not user facing"`
`@pytorchbot label "release notes: none"`

For more information, see
https://github.com/pytorch/pytorch/wiki/PyTorch-AutoLabel-Bot#why-categorize-for-release-notes-and-how-does-it-work.
Expand Down Expand Up @@ -115,7 +115,7 @@ def has_required_labels(pr: "GitHubPR") -> bool:
pr_labels = pr.get_labels()
# Check if PR is not user facing
is_not_user_facing_pr = any(
label.strip() == "topic: not user facing" for label in pr_labels
label.strip() == "release notes: none" for label in pr_labels
)
return is_not_user_facing_pr or any(
label.strip() in get_release_notes_labels(pr.org, pr.project)
Expand Down
20 changes: 10 additions & 10 deletions .github/workflows/_link_check.yml
Original file line number Diff line number Diff line change
Expand Up @@ -18,11 +18,11 @@ jobs:
timeout: 120
script: |
./scripts/lint_urls.sh $(
{ [ "${{ github.event_name }}" = "pull_request" ] \
&& git diff --name-only "${{ github.event.pull_request.base.sha }}...${{ github.event.pull_request.head.sha }}"; } \
|| \
{ [ "${{ github.event_name }}" = "push" ] \
&& git diff --name-only "${{ github.event.before }}...${{ github.sha }}"; }
if [ "${{ github.event_name }}" = "pull_request" ]; then
echo "${{ github.event.pull_request.base.sha }}" "${{ github.event.pull_request.head.sha }}"
else
echo "${{ github.event.before }}" "${{ github.sha }}"
fi
) || {
echo
echo "URL lint failed."
Expand All @@ -43,11 +43,11 @@ jobs:
timeout: 60
script: |
./scripts/lint_xrefs.sh $(
{ [ "${{ github.event_name }}" = "pull_request" ] \
&& git diff --name-only "${{ github.event.pull_request.base.sha }}...${{ github.event.pull_request.head.sha }}"; } \
|| \
{ [ "${{ github.event_name }}" = "push" ] \
&& git diff --name-only "${{ github.event.before }}...${{ github.sha }}"; }
if [ "${{ github.event_name }}" = "pull_request" ]; then
echo "${{ github.event.pull_request.base.sha }}" "${{ github.event.pull_request.head.sha }}"
else
echo "${{ github.event.before }}" "${{ github.sha }}"
fi
) || {
echo
echo "Xref lint failed."
Expand Down
2 changes: 1 addition & 1 deletion .github/workflows/android-perf.yml
Original file line number Diff line number Diff line change
Expand Up @@ -367,7 +367,7 @@ jobs:
PYTHON_EXECUTABLE=python bash .ci/scripts/build-qnn-sdk.sh

mkdir -p aar-out
PYTHON_EXECUTABLE=python ANDROID_ABIS="arm64-v8a" BUILD_AAR_DIR=aar-out EXECUTORCH_BUILD_QNN=ON QNN_SDK_ROOT=/tmp/qnn/2.28.0.241029 bash scripts/build_android_library.sh
PYTHON_EXECUTABLE=python ANDROID_ABIS="arm64-v8a" BUILD_AAR_DIR=aar-out EXECUTORCH_BUILD_QNN=ON QNN_SDK_ROOT=/tmp/qnn/2.28.0.241029 EXECUTORCH_ANDROID_PROFILING=ON bash scripts/build_android_library.sh
mkdir -p extension/benchmark/android/benchmark/app/libs
cp aar-out/executorch.aar extension/benchmark/android/benchmark/app/libs
pushd extension/benchmark/android/benchmark
Expand Down
55 changes: 55 additions & 0 deletions .github/workflows/build-presets.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,8 +6,63 @@ on:
branches:
- main
- release/*
paths:
- .github/workflows/build-presets.yml
workflow_dispatch:

concurrency:
group: ${{ github.workflow }}-${{ github.event.pull_request.number || github.sha }}-${{ github.event_name == 'workflow_dispatch' }}-${{ github.event_name == 'schedule' }}
cancel-in-progress: true

jobs:
apple:
uses: pytorch/test-infra/.github/workflows/macos_job.yml@main
strategy:
fail-fast: false
matrix:
preset: [macos-arm64, pybind]
with:
job-name: build
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
runner: macos-latest-xlarge
python-version: 3.12
submodules: recursive
timeout: 90
script: |
set -eux
${CONDA_RUN} ./install_requirements.sh > /dev/null
${CONDA_RUN} cmake --preset ${{ matrix.preset }}
${CONDA_RUN} cmake --build cmake-out --parallel

linux:
uses: pytorch/test-infra/.github/workflows/linux_job_v2.yml@main
strategy:
fail-fast: false
matrix:
preset: [pybind]
runner: [linux.2xlarge, linux.arm64.2xlarge]
docker-image: [executorch-ubuntu-22.04-clang12, executorch-ubuntu-22.04-gcc11-aarch64]
# Excluding specific runner + docker image combinations that don't make sense:
# - Excluding the ARM64 gcc image on the x86 runner (linux.2xlarge)
# - Excluding the x86 clang image on the ARM64 runner (linux.arm64.2xlarge)
exclude:
- runner: linux.2xlarge
docker-image: executorch-ubuntu-22.04-gcc11-aarch64
- runner: linux.arm64.2xlarge
docker-image: executorch-ubuntu-22.04-clang12
with:
job-name: build
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
runner: ${{ matrix.runner }}
docker-image: ${{ matrix.docker-image }}
submodules: recursive
timeout: 90
script: |
set -eux
# The generic Linux job chooses to use base env, not the one setup by the image
CONDA_ENV=$(conda env list --json | jq -r ".envs | .[-1]")
conda activate "${CONDA_ENV}"

./install_requirements.sh > /dev/null
cmake --preset ${{ matrix.preset }}
cmake --build cmake-out --parallel
32 changes: 1 addition & 31 deletions .github/workflows/pull.yml
Original file line number Diff line number Diff line change
Expand Up @@ -343,34 +343,6 @@ jobs:
PYTHON_EXECUTABLE=python bash .ci/scripts/setup-linux.sh --build-tool "${BUILD_TOOL}"
PYTHON_EXECUTABLE=python bash examples/xnnpack/quantization/test_quantize.sh "${BUILD_TOOL}" mv2

test-pybind-build-linux:
name: test-pybind-build-linux
uses: pytorch/test-infra/.github/workflows/linux_job_v2.yml@main
permissions:
id-token: write
contents: read
strategy:
fail-fast: false
with:
runner: linux.2xlarge
docker-image: executorch-ubuntu-22.04-clang12
submodules: 'recursive'
ref: ${{ github.event_name == 'pull_request' && github.event.pull_request.head.sha || github.sha }}
timeout: 90
script: |
# The generic Linux job chooses to use base env, not the one setup by the image
CONDA_ENV=$(conda env list --json | jq -r ".envs | .[-1]")
conda activate "${CONDA_ENV}"

# build module for executorch.extension.pybindings.portable_lib
BUILD_TOOL="cmake"
PYTHON_EXECUTABLE=python \
CMAKE_ARGS="-DEXECUTORCH_BUILD_PYBIND=ON -DEXECUTORCH_BUILD_XNNPACK=ON" \
bash .ci/scripts/setup-linux.sh --build-tool "${BUILD_TOOL}"

# see if we can import the module successfully
python -c "from executorch.extension.pybindings import portable_lib; print('success!')"

test-binary-size-linux-gcc:
name: test-binary-size-linux-gcc
uses: pytorch/test-infra/.github/workflows/linux_job_v2.yml@main
Expand Down Expand Up @@ -434,9 +406,7 @@ jobs:
output=$(ls -la cmake-out/test/size_test)
arr=($output)
size=${arr[4]}
# threshold=48120 on devserver with gcc11.4
# todo(lfq): update once binary size is below 50kb.
threshold="47552"
threshold="47560"
if [[ "$size" -le "$threshold" ]]; then
echo "Success $size <= $threshold"
else
Expand Down
Loading
Loading