-
Notifications
You must be signed in to change notification settings - Fork 589
New issue
Have a question about this project? # for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “#”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? # to your account
Add to F-Droid #520
Comments
Are you going to contribute to add it? |
I'll help if I can, Step one is obtaining your (original app author) approval. Or if there is a conflict ( like https://github.com/edeso/bubble2 wanting to use unrar-nonfree vs unrar-free) the app can be added via an alternative repository (vs the main repository). |
Could you tell us where we can find the above 12+ points? |
From the link in the first post;
|
We are very glad if you can contribute to add it to F-Droid as long as you state that the app is from this repo.
I have just gone through all the items and I think we are not violating any of them. |
Thank you! |
This would be more difficult than a normal app, since each language and each voice are included on the apk package. It should be done as for AnySoftKeyboard for example. I have done the fastlane data for one app, but this probably would be more difficult. Also the icon should be improved, anyone know if there is a svg of the logo? |
For the logo, please have a look at |
The major issue is that we don't know how to download model files in Android. If you can help, a better design is to download models for a certain language requested by the user. |
Ok, is still a png, but I can work on it, you are sure that is the correct one? on the official page I have found the other logo. Also, about helping on improve the download capability, I'm sorry, I can do only hint of other open-source project that already did it. |
Sorry that I did not notice this page before. Please find all of the logos of next-gen kaldi in the above pdf, including the one for Sherpa. |
Thanks, the logo seems to be too detailed in my honest opinion. Don't misunderstood, is beautiful, but will be difficult make it an adaptive icon. In the next weeks I will do my best and then ask a pr, but please dont expect too much, especially on the monochrome icon(maybe if looks to ugly I will drop it). |
Thanks for this great work! If publishing to f-droid.org isn't feasible right now, maybe you could set up your own repo in the meantime? This would result in automatic updates. |
I can help package this app. I tried to package sherpa-ncnn but it seems it's not maintained anymore. Which app should we package? There are lots of apks listed in the readme. |
sherpa-ncnn is developed and maintained by us. Do you have any issues with sherpa-ncnn? |
Yes, as I said in k2-fsa/sherpa-ncnn#237, the version name and version code need to be bumped for every new version. And I need to add fastlane files in the repo. |
Maybe I can help publishing on F-Droid. I already have 20 apps there. https://mvnrepository.com/artifact/com.bihe0832.android/lib-sherpa-onnx/6.22.3 With such a library we can simply add it to build gradle and do not need to load the library later.
The model should not be placed in "assets" folder but be downloaded later and placed in
In older Android versions it is also possible to put files there "manually". (Android/data/com.k2fsa.sherpa.onnx.tts.engine/ files ...) In order to keep it simple we should probably have the relevant code just for the tts engine in a separate repo and not in a huge repo like this with some files just being symlinks to other folders etc. Maybe someone can help getting this done :-) |
@woheller69 please watch this fork https://github.com/jing332/SherpaOnnxTtsEngineAndroid and also read the issue #569 |
I managed to build it using pre-built libraries from https://github.com/k2-fsa/sherpa-onnx/releases/download/v1.10.41/sherpa-onnx-v1.10.41-android.tar.bz2 (just libonnxruntime.so and libsherpa-onnx-jni.so) I used German voice Piper Thorsten Medium. It seems the app only copies espeak-ng-data folder to external directory and keeps the onnx model and tokens.txt in assets.
instead of
in Tts.kt the app crashes and says it does not find the model. My project is here: https://github.com/woheller69/ttsEngine BTW, I think there are a few wrong tokens in Thorsten voice: |
Please post the complete logs.
We indeed support not using model files from assets. |
I managed to load the model from external directory, everything works fine. But the problem is now that I somehow crashed my settings for TTS as reported in #670. Other than that everything works fine. No problem on other devices. |
In order to publish on F-Droid we need to automatically build the libraries and move them to the jniLibs folder. At the moment my code works for the above 5 languages. Other languages can be used if model.onnx and tokens.txt are copied to
|
For onnx download I also tried the onnx from here, but it did not work. https://huggingface.co/rhasspy/piper-voices/tree/main/de/de_DE/thorsten/medium Do your onnx files differ from the "original" from piper-voices? |
yes, we add meta data to them. Make sure you do read our doc for how to add meta data to piper models. We have documented it clearly. |
Ok, no problem. I am using your models from Hugging Face. Just wanted to understand why the other models do not work. |
I think publishing on F-Droid will be hard. During the build process of libsherpa-onnx-jni.so a lot of stuff is downloaded In my code I removed libonnxruntime.so from jniLibs and included it from Maven instead via If this could also be achieved for libsherpa-onnx-jni.so we could easily publish it. But that is nothing I can do... |
We do provide Android maven package for sherpa-onnx. Please see.SherpaOnnxJavaDemo inside the android directory. |
Unfortunately it does not work if I add
and
I get this error: Read binary file: Load /storage/emulated/0/Android/data/org.woheller69.ttsengine/files/modelDir/model.onnx failed |
Unfortunately it does not work. If I remove the .so files and add
and
I get this error: Read binary file: Load /storage/emulated/0/Android/data/org.woheller69.ttsengine/files/modelDir/model.onnx failed |
is the library on Jitpack maybe compiled without TTS support? |
V1.1 now provides all Piper Voices for download: https://github.com/woheller69/ttsEngine/releases/tag/V1.1 So the only thing needed would be a library from Jitpack / Maven which works... |
For whatever reason it worked with implementation("com.github.k2-fsa:sherpa-onnx:v1.10.41") when I tried again. When I try to build a release I get:
It seems the library contains the classes defined in Tts.kt. If I remove Tts.kt the app does not work anymore |
can you share error logs? |
By the way, errors related to model.onnx have nothing to do with the provided maven package. Also, the package contains both shared libraries AND Kotlin files. You don't need to add Tts.kt. Note that we have already had a working example using the maven package. If you.have any errors about the usage, please first debug it by yourself. It is very likely that you make mistakes somewhere. |
Thanks for the hint. I had one hardcoded change in my Tts.kt to load the model from files instead of loading from assets.
Working now :-) |
Merge request created on F-Droid |
This issue can be closed. App is merged in F-Droid and will be available in a few days. |
Thanks! |
https://f-droid.org/contribute/
The text was updated successfully, but these errors were encountered: