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

whisper.Android WhisperCppDemo very slow android specific transcibe times for 3s recording a res of 31227ms #1022

Open
Anioz opened this issue Jun 16, 2023 · 1 comment

Comments

@Anioz
Copy link

Anioz commented Jun 16, 2023

System info shows support on samsung note10 device for fp16_va, neon, arm_fma, release build was made with Android studio and file contents:
Default provided file contents where tested first before trying the below options, all in release build model tiny-en.bin

for Android.mk:
ifeq ($(TARGET_ARCH_ABI),arm64-v8a)
include $(CLEAR_VARS)
LOCAL_MODULE := libwhisper_v8fp16_va
include $(LOCAL_PATH)/Whisper.mk
# Enable VFPv16, NEON, and FMA instruction sets
LOCAL_CFLAGS += -march=armv8.2-a+fp16 -mfpu=neon-v8fp16_va
include $(BUILD_SHARED_LIBRARY)
endif

for Application mk:
APP_STL := c++_static
APP_ABI := arm64-v8a

Extra manifest declarations are added:
android:largeHeap="true"
android:hardwareAccelerated="true" (this one could possibly be irrelevant because most of the time since a certain sdk level its
always been at true even without declaring this specifically)

None of these seem to bring the times within acceptable time parameters however, I would love to try some things out if you propose them and will share the results when tested.

Please put me in the right direction as I love your work and want to maximize its performance on Android devices

*Edit: Ive found that disabling R8 shrinking minifyenabled = false increases transcribe times by 50% (3040ms speech, 14762ms transcribe time coming down from 31227ms) This was done with default project repo values

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

No branches or pull requests

2 participants