Skip to content
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

Add GPT-2 GGML x86 and Android Benchmarks #130

Merged
merged 1 commit into from
Sep 11, 2023

Conversation

mariecwhite
Copy link
Collaborator

@mariecwhite mariecwhite commented Sep 5, 2023

Includes F32, F16 and INT4 versions.

@mariecwhite mariecwhite force-pushed the ggml-android branch 30 times, most recently from 6faec99 to 40e7cf9 Compare September 6, 2023 09:31
@mariecwhite mariecwhite force-pushed the ggml-android branch 18 times, most recently from 974bdbe to d94f0e0 Compare September 11, 2023 10:48
@mariecwhite mariecwhite changed the title Ggml android Add GPT-2 GGML x86 and Android Benchmarks Sep 11, 2023

on:
workflow_dispatch:
pull_request:
Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Remove before merging

@mariecwhite mariecwhite requested a review from pzread September 11, 2023 10:50
./experimental/ggml/benchmark_ggml.sh "${TARGET_DEVICE}" "${GGML_BUILD_DIR}" "${RESULTS_PATH}"
cat "${RESULTS_PATH}"

# adb push "./experimental/ggml/set_android_scaling_governor.sh" "/data/local/tmp"
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Can you add a comment to explain the reason these lines are commented out?

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I was supposed to remove all of this! Removed.

},
)

ALL_DEVICES = [MOBILE_PIXEL_6_PRO]
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: Missing a newline

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Added.

set -xeuo pipefail

VENV_DIR="${OOBI_VENV_DIR:-ggml-benchmarks.venv}"
PYTHON="${PYTHON:-/usr/bin/python3}"
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This might work in broader environments

Suggested change
PYTHON="${PYTHON:-/usr/bin/python3}"
PYTHON="${PYTHON:-"$(which python3)"}"

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Thanks, changed.

)

if [[ "${TARGET_DEVICE_NAME}" =~ ^(pixel-4|pixel-6-pro|moto-edge-x30)$ ]]; then
BENCHMARK_SCRIPT="run_benchmarks_android.py"
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

nit: Maybe have one indent as these are in a if block? Same on the else block

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Updated.

@@ -0,0 +1,51 @@
#!/bin/sh

# Copyright 2023 The IREE Authors
Copy link

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Suggested change
# Copyright 2023 The IREE Authors
# Copyright 2023 The OpenXLA Authors

Copy link
Collaborator Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Changed.

@mariecwhite mariecwhite requested a review from pzread September 11, 2023 21:47
@mariecwhite mariecwhite marked this pull request as ready for review September 11, 2023 21:49
@mariecwhite mariecwhite merged commit e67c882 into iree-org:main Sep 11, 2023
6 checks passed
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants