-
Notifications
You must be signed in to change notification settings - Fork 829
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Include SAM Fast in torch.compile nightly benchmark workflow #2856
Changes from 8 commits
085eb8c
bcda479
156352c
b6eb538
684b99e
c695afd
48e872f
301ac9c
d12c116
e89c1ba
e65e083
File filter
Filter by extension
Conversations
Jump to
Diff view
Diff view
There are no files selected for viewing
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -20,10 +20,10 @@ jobs: | |
cd .. | ||
pwd | ||
rm -rf _tool | ||
- name: Setup Python 3.8 | ||
- name: Setup Python 3.10 | ||
uses: actions/setup-python@v4 | ||
with: | ||
python-version: 3.8 | ||
python-version: 3.10.9 | ||
architecture: x64 | ||
- name: Setup Java 17 | ||
uses: actions/setup-java@v3 | ||
|
@@ -39,5 +39,8 @@ jobs: | |
sudo apt-get update -y | ||
sudo apt-get install -y apache2-utils | ||
pip install -r benchmarks/requirements-ab.txt | ||
chmod +x examples/large_models/segment_anything_fast/install_segment_anything_fast.sh | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Please make this a separate step There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Will update the PR. There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I'm thinking this should be a script under benchmarks. You can call it There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Sounds good. I will create this script. |
||
source examples/large_models/segment_anything_fast/install_segment_anything_fast.sh | ||
export SEGMENT_ANYTHING_FAST_USE_FLASH_4=0 | ||
- name: Benchmark gpu nightly | ||
run: python benchmarks/auto_benchmark.py --input benchmarks/benchmark_config_torch_compile_gpu.yaml --skip false --nightly True |
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,18 @@ | ||
--- | ||
sam_fast_vit_b: | ||
process_batch_size_4: | ||
benchmark_engine: "ab" | ||
url: https://torchserve.pytorch.org/mar_files/sam-fast-vit-b-process-batch-size-4.tar.gz | ||
agunapal marked this conversation as resolved.
Show resolved
Hide resolved
|
||
workers: | ||
- 4 | ||
batch_delay: 100 | ||
batch_size: | ||
- 1 | ||
input: "./examples/large_models/segment_anything_fast/kitten.jpg" | ||
requests: 1000 | ||
concurrency: 4 | ||
backend_profiling: False | ||
exec_env: "local" | ||
processors: | ||
- "cpu" | ||
- "gpus": "all" |
Original file line number | Diff line number | Diff line change |
---|---|---|
|
@@ -4,6 +4,7 @@ | |
pip uninstall torchtext torchdata torch torchvision torchaudio -y | ||
|
||
# Install nightly PyTorch and torchvision from the specified index URL | ||
pip install chardet | ||
There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. What is this for ? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Included this dependency because one of the previous benchmark runs failed because of the absence of this module: https://github.com/pytorch/serve/actions/runs/7255062486/job/19764967013 There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. Was this happening locally? I didnt notice this. If not, can you please move this to the dependencies section of the benchmark run? There was a problem hiding this comment. Choose a reason for hiding this commentThe reason will be displayed to describe this comment to others. Learn more. I think I noticed it locally as well. I will include it in the |
||
pip install --pre torch torchvision torchaudio --index-url https://download.pytorch.org/whl/nightly/cu121 --ignore-installed | ||
|
||
# Optional: Display the installed PyTorch and torchvision versions | ||
|
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
can we just have 3.10?
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
One of the previous runs had failed when I specified just 3.10: https://github.com/pytorch/serve/actions/runs/7255048620/job/19764929373
Commit ID: bcda479
We can choose the versions according to https://raw.githubusercontent.com/actions/python-versions/main/versions-manifest.json.
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
You need to use quotes, check this workflow https://github.com/pytorch/serve/blob/master/.github/workflows/regression_tests_cpu_binaries.yml#L20
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Oh I understand. I will update the workflow accordingly.