Skip to main content

Termux-Vision

PyPI Python npm npm downloads License

디바이스 리소스를 활용한 안드로이드 Termux 제로 디펜던시 온디바이스 컴퓨터 비전 & VLM 멀티모달 추론 엔진
Zero-Dependency On-Device Computer Vision & Multimodal VLM Inference Engine Utilizing Device Resources for Android Termux


📌 Architecture & Overview

순수 ARM64 NEON 커널과 4단계 화질 프리셋(fast, optimal, high, original), 디바이스 리소스 최적화 연산을 결합하여 메모리 격리 환경에서 엣지 검출과 VLM 멀티모달 시각 추론을 실현합니다.

Eliminates heavy C++ dependencies by integrating SIMD NEON spatial image transforms with on-device VLM (Qwen2-VL, SmolVLM) multi-tier resolution presets (fast, optimal, high, original) utilizing device resources under strict memory isolation.


🚀 Installation & Quickstart

Python (PyPI)

pip install termux-vision
import termux_vision as tv

# 1. Zero-Dependency Spatial Filtering (0.01s ultra-fast)
img = tv.io.load_image("photo.jpg")
edges = tv.cv.canny(tv.transforms.to_grayscale(img), 40, 120)

# 2. On-Device VLM Multimodal Inference with 4-Tier Quality Presets
with tv.vlm.load("qwen2-vl-2b-q4", quality="optimal") as engine:
    res = engine.describe("photo.jpg", prompt="Describe this scene in detail.", quality="optimal")
    print(f"Generated ({res.metrics.tokens_per_second:.1f} t/s): {res.text}")

Node.js / TypeScript (npm)

npm install termux-vision
import tv from 'termux-vision';

// 1. Diagnostics & Hardware Probe
const doc = tv.doctor(true);
console.log(`Vulkan GPU: ${doc.vulkan.status} | RAM: ${doc.hardware.availableRamMb} MB`);

// 2. Multimodal VLM Inference with Quality Preset
const engine = await tv.load({ modelId: 'qwen2-vl-2b-q4', contextLimit: 4096 });
const result = await engine.describe('photo.jpg', { quality: 'optimal', maxTokens: 300 });
console.log(`[${result.metrics.backend.toUpperCase()}] ${result.text}`);
engine.close();

📖 Official Documentation & Benchmarks


📄 License

Licensed under the Apache-2.0 License. Copyright (c) 2026 Eunho Kim (@uno-km).

Metadata

Release files for termux-vision 1.2.0

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for termux-vision 1.2.0
File Size Uploaded
termux_vision-1.2.0.tar.gz 84.6 kB Details

Built distribution (wheel)

Table of built distributions (wheels) for termux-vision 1.2.0
File Interpreter ABI Platform
termux_vision-1.2.0-py3-none-any.whl Python 3 none any Details

Total release size: 173.1 kB

Release files / termux_vision-1.2.0.tar.gz

Download URL termux_vision-1.2.0.tar.gz
Size 84.6 kB
Tags Source
SHA-256 checksum
How to use checksums
4d632bfcb6264a711f5bb51db8682bf88cfa388355265c18de2f539ce5111569
BLAKE2b-256 checksum
How to use checksums
17a2196df2f3caa3014112ffdd0d9e51aa3da6da5c7c11eadfb868d7a7176033
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.0

Release files / termux_vision-1.2.0-py3-none-any.whl

Download URL termux_vision-1.2.0-py3-none-any.whl
Size 88.4 kB
Tags Python 3
SHA-256 checksum
How to use checksums
03980dfcb1bb6ecd28fad7ba0157673fc78bf624f1c889df51b80e09d5b6eef6
BLAKE2b-256 checksum
How to use checksums
98caadc63eb293c919a5e2b7a081b225a442dd3349b6b8b077644f7a30060f1c
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
No
Uploaded via twine/7.0.0 CPython/3.12.0

Release history Release notifications | RSS feed

1.7.0

2 release files

1.6.0

2 release files

1.5.0

2 release files

1.4.6

2 release files

1.4.5

2 release files

1.4.4

2 release files

1.4.3

2 release files

1.4.2

2 release files

1.4.1

2 release files

1.4.0

2 release files

1.3.1

2 release files

1.3.0

2 release files

This release

1.2.0 This release

2 release files

1.1.4

2 release files

1.1.2

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.0

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page