FireSense
FireSense is a video feed analyzer that detects fires, powered by the Gemma 3N vision model.
Pipeline
Quick Start
Installation
# Install pypi package
pip install firesense
or
# Install from source code:
uv pip install -e .
Command Line Usage
# Analyze a YouTube video
firesense analyze <youtube_video_id>
# Launch demo with local server
firesense demo <youtube_video_id> --local
https://github.com/user-attachments/assets/b8fdba5b-bd2d-44c6-be4e-8fb6499b62a8
Ngrok Integration
# setup ngrok
ngrok config add-authtoken <your_ngrok_auth_key>
# Launch demo with local server and ngrok tunnel
firesense demo <youtube_video_id> --local --ngrok
Python Usage
from firesense import setup_model, infer
# Setup model
model, tokenizer = setup_model()
# Run inference
inference_result = infer(model, tokenizer, system_prompt, user_prompt, image_path)
Features
- 🚀 Fast Development: Leverages uv for 10-100x faster dependency installation
- 📦 Modern Packaging: PEP 621 compliant with pyproject.toml
- 🔍 Type Safety: Full mypy strict mode support (uv run mypy src)
- ✅ Testing: Comprehensive pytest setup with coverage
Contributing
- Fork the repository
- Create a feature branch (
git checkout -b feature/amazing-feature) - Make your changes
- Run tests and checks (
make check) - Commit your changes (
git commit -m 'Add amazing feature') - Push to the branch (
git push origin feature/amazing-feature) - Open a Pull Request
Testing
# Install the project with development dependencies using:
uv pip install -e ".[dev]"
# Run the tests with:
uv run pytest
Type Safety
# Full mypy strict mode support
uv run mypy src
Releasing
New releases are manually pushed to pypi:
make publish
License
This project is licensed under the MIT License - see the LICENSE file for details.
Metadata
Release files for firesense 0.10.2
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| firesense-0.10.2.tar.gz | 1.1 MB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| firesense-0.10.2-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 1.2 MB
Release files / firesense-0.10.2.tar.gz
| Download URL | firesense-0.10.2.tar.gz |
|---|---|
| Size | 1.1 MB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
f60d378e65bd77a4eaff2a02f04a934ac5e01bf0682638e3d0e52850982a2cbc
|
|
BLAKE2b-256 checksum How to use checksums |
e40a099a7868cf4bb446a35081798e2c3d051b80a507e69bc34d931028e6bd93
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.8
|
Release files / firesense-0.10.2-py3-none-any.whl
| Download URL | firesense-0.10.2-py3-none-any.whl |
|---|---|
| Size | 75.4 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
00e789bd3018655edfe79cea3608a14e386e60fe2cc43148edb45da41318947f
|
|
BLAKE2b-256 checksum How to use checksums |
c207aa4f391d528739112725411aa5f719e314959166f2a6f4bc6e6e968059e4
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.1.0 CPython/3.11.8
|