Refactor tokenizer test and add to cmake#8450
Merged
facebook-github-bot merged 1 commit intomainfrom Feb 15, 2025
Merged
Conversation
🔗 Helpful Links🧪 See artifacts and rendered test results at hud.pytorch.org/pr/pytorch/executorch/8450
Note: Links to docs will display an error until the docs builds have been completed. ✅ You can merge normally! (1 Unrelated Failure)As of commit b1a9127 with merge base 8148603 ( BROKEN TRUNK - The following job failed but were present on the merge base:👉 Rebase onto the `viable/strict` branch to avoid these failures
This comment was automatically generated by Dr. CI and updates every 15 minutes. |
41b88a2 to
15d4cd0
Compare
15d4cd0 to
71976c7
Compare
Contributor
|
@lucylq has imported this pull request. If you are a Meta employee, you can view this diff on Phabricator. |
71976c7 to
ddccce2
Compare
facebook-github-bot
pushed a commit
that referenced
this pull request
Feb 14, 2025
Summary:
Refactor tokenizer test to use env instead of resource path.
Add to cmake tests.
Test Plan:
## Internal
```
buck2 test fbsource//xplat/executorch/extension/llm/tokenizer/test:test_tiktoken
buck2 test fbsource//xplat/executorch/extension/llm/tokenizer/test:test_bpe_tokenizer
buck2 test fbcode//executorch/extension/llm/tokenizer/test:test_tiktoken
buck2 test fbcode//executorch/extension/llm/tokenizer/test:test_bpe_tokenizer
```
## OSS
build et
```
./install_executorch.sh
```
build test
```
CMAKE_PREFIX_PATH="$(python3 -c 'import torch as _; print(_.__path__[0])')"
cmake . \
-DCMAKE_INSTALL_PREFIX=cmake-out \
-DCMAKE_PREFIX_PATH="${CMAKE_PREFIX_PATH}" \
-DEXECUTORCH_USE_CPP_CODE_COVERAGE=ON \
-DEXECUTORCH_BUILD_KERNELS_OPTIMIZED=ON \
-DEXECUTORCH_BUILD_KERNELS_QUANTIZED=ON \
-DEXECUTORCH_BUILD_EXTENSION_DATA_LOADER=ON \
-DEXECUTORCH_BUILD_EXTENSION_FLAT_TENSOR=ON \
-DEXECUTORCH_BUILD_EXTENSION_LLM=ON \
-DEXECUTORCH_BUILD_EXTENSION_MODULE=ON \
-DEXECUTORCH_BUILD_EXTENSION_RUNNER_UTIL=ON \
-DEXECUTORCH_BUILD_EXTENSION_TENSOR=ON \
-DEXECUTORCH_BUILD_DEVTOOLS=ON \
-DEXECUTORCH_BUILD_XNNPACK=ON \
-DEXECUTORCH_BUILD_TESTS=ON \
-Bcmake-out
cmake --build cmake-out -j9 --target install
```
test
```
cd cmake-out
ctest -R tokenizer
Test project /data/users/lfq/executorch/cmake-out
Start 54: extension_llm_tokenizer_test
1/1 Test #54: extension_llm_tokenizer_test ..... Passed 3.66 sec
100% tests passed, 0 tests failed out of 1
Total Test time (real) =--sanitized--
Differential Revision: D69642007
Pulled By: lucylq
Contributor
|
This pull request was exported from Phabricator. Differential Revision: D69642007 |
facebook-github-bot
pushed a commit
that referenced
this pull request
Feb 14, 2025
Summary:
Refactor tokenizer test to use env instead of resource path.
Add to cmake tests.
Test Plan:
## Internal
```
buck2 test fbsource//xplat/executorch/extension/llm/tokenizer/test:test_tiktoken
buck2 test fbsource//xplat/executorch/extension/llm/tokenizer/test:test_bpe_tokenizer
buck2 test fbcode//executorch/extension/llm/tokenizer/test:test_tiktoken
buck2 test fbcode//executorch/extension/llm/tokenizer/test:test_bpe_tokenizer
```
## OSS
build et
```
./install_executorch.sh
```
build test
```
CMAKE_PREFIX_PATH="$(python3 -c 'import torch as _; print(_.__path__[0])')"
cmake . \
-DCMAKE_INSTALL_PREFIX=cmake-out \
-DCMAKE_PREFIX_PATH="${CMAKE_PREFIX_PATH}" \
-DEXECUTORCH_USE_CPP_CODE_COVERAGE=ON \
-DEXECUTORCH_BUILD_KERNELS_OPTIMIZED=ON \
-DEXECUTORCH_BUILD_KERNELS_QUANTIZED=ON \
-DEXECUTORCH_BUILD_EXTENSION_DATA_LOADER=ON \
-DEXECUTORCH_BUILD_EXTENSION_FLAT_TENSOR=ON \
-DEXECUTORCH_BUILD_EXTENSION_LLM=ON \
-DEXECUTORCH_BUILD_EXTENSION_MODULE=ON \
-DEXECUTORCH_BUILD_EXTENSION_RUNNER_UTIL=ON \
-DEXECUTORCH_BUILD_EXTENSION_TENSOR=ON \
-DEXECUTORCH_BUILD_DEVTOOLS=ON \
-DEXECUTORCH_BUILD_XNNPACK=OFF \
-DEXECUTORCH_BUILD_TESTS=ON \
-Bcmake-out
cmake --build cmake-out -j9 --target install
```
test
```
cd cmake-out
ctest -R tokenizer
Test project /data/users/lfq/executorch/cmake-out
Start 54: extension_llm_tokenizer_test
1/1 Test #54: extension_llm_tokenizer_test ..... Passed 3.66 sec
100% tests passed, 0 tests failed out of 1
Total Test time (real) =--sanitized--
Differential Revision: D69642007
Pulled By: lucylq
ddccce2 to
a72e252
Compare
Contributor
|
This pull request was exported from Phabricator. Differential Revision: D69642007 |
Summary:
Refactor tokenizer test to use env instead of resource path.
Add to cmake tests.
Test Plan:
## Internal
```
buck2 test fbsource//xplat/executorch/extension/llm/tokenizer/test:test_tiktoken
buck2 test fbsource//xplat/executorch/extension/llm/tokenizer/test:test_bpe_tokenizer
buck2 test fbcode//executorch/extension/llm/tokenizer/test:test_tiktoken
buck2 test fbcode//executorch/extension/llm/tokenizer/test:test_bpe_tokenizer
```
## OSS
build et
```
./install_executorch.sh
```
build test
```
CMAKE_PREFIX_PATH="$(python3 -c 'import torch as _; print(_.__path__[0])')"
cmake . \
-DCMAKE_INSTALL_PREFIX=cmake-out \
-DCMAKE_PREFIX_PATH="${CMAKE_PREFIX_PATH}" \
-DEXECUTORCH_USE_CPP_CODE_COVERAGE=ON \
-DEXECUTORCH_BUILD_KERNELS_OPTIMIZED=ON \
-DEXECUTORCH_BUILD_KERNELS_QUANTIZED=ON \
-DEXECUTORCH_BUILD_EXTENSION_DATA_LOADER=ON \
-DEXECUTORCH_BUILD_EXTENSION_FLAT_TENSOR=ON \
-DEXECUTORCH_BUILD_EXTENSION_LLM=ON \
-DEXECUTORCH_BUILD_EXTENSION_MODULE=ON \
-DEXECUTORCH_BUILD_EXTENSION_RUNNER_UTIL=ON \
-DEXECUTORCH_BUILD_EXTENSION_TENSOR=ON \
-DEXECUTORCH_BUILD_DEVTOOLS=ON \
-DEXECUTORCH_BUILD_XNNPACK=OFF \
-DEXECUTORCH_BUILD_TESTS=ON \
-Bcmake-out
cmake --build cmake-out -j9 --target install
```
test
```
cd cmake-out
ctest -R tokenizer
Test project /data/users/lfq/executorch/cmake-out
Start 54: extension_llm_tokenizer_test
1/1 Test #54: extension_llm_tokenizer_test ..... Passed 3.66 sec
100% tests passed, 0 tests failed out of 1
Total Test time (real) =--sanitized--
Differential Revision: D69642007
Pulled By: lucylq
a72e252 to
b1a9127
Compare
Contributor
|
This pull request was exported from Phabricator. Differential Revision: D69642007 |
larryliu0820
approved these changes
Feb 15, 2025
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
Add this suggestion to a batch that can be applied as a single commit.This suggestion is invalid because no changes were made to the code.Suggestions cannot be applied while the pull request is closed.Suggestions cannot be applied while viewing a subset of changes.Only one suggestion per line can be applied in a batch.Add this suggestion to a batch that can be applied as a single commit.Applying suggestions on deleted lines is not supported.You must change the existing code in this line in order to create a valid suggestion.Outdated suggestions cannot be applied.This suggestion has been applied or marked resolved.Suggestions cannot be applied from pending reviews.Suggestions cannot be applied on multi-line comments.Suggestions cannot be applied while the pull request is queued to merge.Suggestion cannot be applied right now. Please check back later.
Summary
Refactor tokenizer test to use env instead of resource path.
Add to cmake tests.
Test plan
build et
build test
test