Request: provide Android wheels for the Python package (`ctranslate2`)
I maintainer di solito rispondono entro 1 giorno
Nessuno ha ancora preso questa issue.
Valutazione
- Difficoltà
- 5/5
- Tempo stimato
- Più di una settimana
- Idoneità per principianti
- 35/100
- Tipo di issue
- Funzionalità
- Chiarezza
- Abbastanza chiara
- Stato di attività
- Attiva
- Ambito
- build-system, mobile, release
Direzione di ricerca
Start by reviewing the Termux ctranslate2 package and the project's CMake, Android NDK, and PyPI packaging workflow. Define how to build and publish prebuilt wheels for aarch64-linux-android/arm64-v8a, then verify that pip install ctranslate2 works inside an Android venv.
Scritto dal modello di indicizzazione a partire dal testo della issue.
Descrizione
Hi,
I would like to request the addition of prebuilt Android wheels for ctranslate2 on PyPI.
Context and the Problem
Android devices are an excellent target for CTranslate2, allowing for efficient, offline, on-device inference. However, installing and managing the Python package on Android is currently very problematic for standard Python workflows.
At the moment, the main way Android users (e.g., using Termux) can get CTranslate2 is through the official Termux APT repository:
https://github.com/termux/termux-packages/tree/master/packages/ctranslate2
While we appreciate the Termux maintainers packaging it, this system-level installation installs the Python bindings globally. Because of this, support for standard Python virtual environments (venv) is severely limited. Users cannot simply run pip install ctranslate2 inside an isolated virtual environment. The package is tied to the global system Python, forcing users to rely on hacky workarounds to access it within a venv or abandon virtual environments entirely.
Why building from source is not a viable alternative
Building ctranslate2 from source directly on an Android device (like inside a Termux terminal) or cross-compiling for it is extremely difficult. It requires setting up a full C++ toolchain, CMake, the Android NDK, and managing various dependencies. This is highly impractical for most Python developers and completely breaks the standard Python packaging workflow.
The Request
Providing prebuilt Android wheels on PyPI (specifically targeting aarch64-linux-android / arm64-v8a, which covers the vast majority of modern Android devices and the Termux environment) would completely solve this issue.
If Android wheels were available on PyPI:
- Users could simply run
pip install ctranslate2inside theirvenvs. - Project dependencies would remain perfectly isolated, following Python best practices.
- Users would no longer need to depend on system-wide packages that conflict with virtual environments or attempt painful local compilation.
Thank you for considering this request and for your great work on CTranslate2!
- Lingua principale
- C++
- Stelle
- 4.8k
- Fork
- 557
- Merge medio
- 1g 6h
- PR unite (30g)
- 24
Preparare l'ambiente
- Nessun Dockerfile né file Docker Compose
- Nessun modello di pull request
- Leggi la guida per i contributori
Come iniziare
- Leggi tutta la issue e poi la guida ai contributi del progetto.
- Commenta sulla issue per dire che te ne occupi tu — evita che due persone facciano lo stesso lavoro.
- Fai un fork del repository e lavora su un branch.
- Apri una pull request che faccia riferimento al numero della issue.
Altre issue di OpenNMT/CTranslate2
-
MPS: GPT-2 produces NaN logits and invalid token IDsForse già presa @TBO22 l’ha presa oggi. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 70/100
OpenNMT/CTranslate2#2154 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Allow no-timestamp Whisper decoding beyond 224 tokensForse già presa @Emre-Akgul l’ha presa 127 giorni fa. Aperta
Difficoltà 2/5 1-3 ore Idoneità per principianti 72/100
OpenNMT/CTranslate2#2074 ·
I maintainer di solito rispondono entro 1 giorno
-
T5Gemma fails on MPS: incorrect beam expansion with padded batchesForse già presa @TBO22 l’ha presa oggi. Aperta
Difficoltà 4/5 3-5 giorni Idoneità per principianti 30/100
OpenNMT/CTranslate2#2153 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 5/5 Più di una settimana Idoneità per principianti 8/100
OpenNMT/CTranslate2#2152 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 3/5 1-2 giorni Idoneità per principianti 55/100
OpenNMT/CTranslate2#2149 ·
I maintainer di solito rispondono entro 1 giorno
Tutte le issue di OpenNMT/CTranslate2
Issue simili
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 65/100
grizzlypeak3d/DJV#962 ·
-
cognizant-backlog
Difficoltà 2/5 1-3 ore Idoneità per principianti 61/100
KhronosGroup/OpenCL-CTS#2882 · 1 commento ·
I maintainer di solito rispondono entro 1 giorno
-
Documentation: Fix parameter markup, legacy branch link, and phrasing in Detachable Joints and Model Command tutorialsForse già presa @patelshivani2283-lab l’ha presa oggi. Aperta
Difficoltà 1/5 1-3 ore Idoneità per principianti 88/100
I maintainer di solito rispondono entro 1 giorno
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 73/100
LunarG/gfxreconstruct#3440 ·
I maintainer di solito rispondono entro 2 giorni
-
Difficoltà 2/5 1-3 ore Idoneità per principianti 68/100
I maintainer di solito rispondono entro 1 giorno