Skip to main content

TopoVision - 3D Topographic Analysis System for Calculus II

Project description

๐Ÿ›ฐ๏ธ TopoVision โ€” 3D Topographic Analysis System

A Python-based system for topographic data visualization, real-time analysis, and calculus-based gradient computation.

Python 3.11 License: Apache 2.0 PyPI version Build

๐Ÿ“ฆ Repository: https://github.com/JalaU-Capstones/topovision.git


๐Ÿงญ Overview

TopoVision is a collaborative academic project developed as part of the Calculus II course at Universidad Jala. The system combines Computer Vision, Numerical Methods, and Topographic Analysis to calculate and visualize slopes, gradients, and surface volumes in real time.

The main goal is to create a tool that connects mathematical theory with visual and spatial understanding โ€” transforming multivariable calculus into an interactive experience.


โœจ What's New in Version 0.2.1

This version introduces a complete unit conversion and perspective calibration system, making TopoVision a more accurate and user-friendly tool for real-world analysis.

  • Unit Conversion System: All calculations and measurements can now be displayed in various units (meters, feet, etc.).
  • Perspective Calibration: A new calibration tool allows you to correct for perspective distortion by defining a real-world rectangle, ensuring all measurements are dimensionally accurate.
  • Interactive Tutorials: A new event-driven tutorial system guides first-time users through the application's key features.
  • Improved UI: The user interface has been refactored for a more stable and responsive layout.
  • Enhanced Visualizations: The gradient heatmap and 3D plot now correctly handle perspective and aspect ratio, providing clearer and more accurate visualizations.

โš™๏ธ Key Features

  • ๐ŸŽฅ Real-time video capture using OpenCV
  • ๐Ÿ“ Unit Conversion: Display results in meters, feet, kilometers, etc.
  • ๐Ÿ“ Perspective Calibration: Correct for perspective distortion for accurate measurements.
  • ๐Ÿงฎ Numerical computation of partial derivatives, gradients, arc length, and volume.
  • โœจ Dynamic 3D Surface Plots: Interactive visualization of topographic data.
  • ๐Ÿ—บ๏ธ Gradient Heatmaps: Clear visualization of slope and steepness.
  • ๐Ÿ–ฑ๏ธ Interactive region selection on the GUI.
  • ๐Ÿง  Interactive Tutorials: Guides first-time users through the application.
  • ๐Ÿ“ฆ Easy installation via PyPI.

๐Ÿ–ผ๏ธ Visualizations

TopoVision offers rich and interactive 3D visualizations to help understand complex topographic data.

Dynamic 3D Surface Plots

Experience real-time rendering of surfaces, allowing you to observe changes in elevation and features interactively.

3D Surface Plot Screenshot


๐Ÿš€ Quick Start

Installation from PyPI

pip install topovision

Run the application

python -m topovision

Or simply:

topovision

You should see a GUI window with a welcome tutorial guiding you to press the "Open Camera" button.


๐Ÿ“‹ System Requirements

Required

  • Python 3.11 or higher
  • Tkinter (GUI toolkit)

Tkinter Installation

Tkinter comes pre-installed with Python on Windows and macOS.

On Linux, you may need to install it manually:

Ubuntu/Debian:

sudo apt-get update
sudo apt-get install python3-tk

Fedora/RHEL:

sudo dnf install python3-tkinter

Arch Linux:

sudo pacman -S tk

๐Ÿ› ๏ธ Installation Options

Standard Installation

Includes all features and GUI support:

pip install topovision

Development Installation

Includes testing, linting, and documentation tools:

pip install topovision[dev]

Lightweight Installation

Minimal dependencies without OpenCV GUI components:

pip install topovision[light]

Installation from Source

For developers who want to contribute or modify the code:

# Clone the repository
git clone https://github.com/JalaU-Capstones/topovision.git
cd topovision

# Create virtual environment
python3.11 -m venv .venv
source .venv/bin/activate      # macOS/Linux
# OR
.venv\Scripts\activate         # Windows

# Install in editable mode
pip install -e .

# Or install with dev dependencies
pip install -e .[dev]

๐Ÿงฉ Project Structure

topovision/
โ”œโ”€โ”€ src/
โ”‚   โ””โ”€โ”€ topovision/
โ”‚       โ”œโ”€โ”€ __init__.py
โ”‚       โ”œโ”€โ”€ __main__.py
โ”‚       โ”œโ”€โ”€ app.py
โ”‚       โ”œโ”€โ”€ core/
โ”‚       โ”‚   โ”œโ”€โ”€ interfaces.py
โ”‚       โ”‚   โ””โ”€โ”€ models.py
โ”‚       โ”œโ”€โ”€ capture/
โ”‚       โ”‚   โ””โ”€โ”€ ...
โ”‚       โ”œโ”€โ”€ calculus/
โ”‚       โ”‚   โ”œโ”€โ”€ calculus_module.py
โ”‚       โ”‚   โ””โ”€โ”€ strategies.py
โ”‚       โ”œโ”€โ”€ visualization/
โ”‚       โ”‚   โ”œโ”€โ”€ visualizers.py
โ”‚       โ”‚   โ””โ”€โ”€ plot3d.py
โ”‚       โ”œโ”€โ”€ gui/
โ”‚       โ”‚   โ”œโ”€โ”€ gui_module.py
โ”‚       โ”‚   โ”œโ”€โ”€ analysis_panel.py
โ”‚       โ”‚   โ””โ”€โ”€ ...
โ”‚       โ”œโ”€โ”€ services/
โ”‚       โ”‚   โ””โ”€โ”€ task_queue.py
โ”‚       โ”œโ”€โ”€ utils/
โ”‚       โ”‚   โ”œโ”€โ”€ math.py
โ”‚       โ”‚   โ”œโ”€โ”€ units.py
โ”‚       โ”‚   โ””โ”€โ”€ perspective.py
โ”‚       โ””โ”€โ”€ tests/
โ”‚           โ””โ”€โ”€ ...
โ”œโ”€โ”€ docs/
โ”‚   โ”œโ”€โ”€ architecture.md
โ”‚   โ”œโ”€โ”€ user-guide.md
โ”‚   โ””โ”€โ”€ ...
โ”œโ”€โ”€ pyproject.toml
โ”œโ”€โ”€ README.md
โ””โ”€โ”€ ...

๐Ÿงฐ Tech Stack

Layer Technology
Language Python 3.11
GUI Tkinter
Computer Vision OpenCV
Numerical Analysis NumPy
Visualization Matplotlib
Documentation Markdown
Testing Pytest
Linting / Formatting Flake8, Black, Mypy
Version Control GitHub (GitHub Flow)
Distribution PyPI

๐ŸŽฏ Usage Examples

Basic Usage

# After installation, simply run:
python -m topovision

# Or use the command directly:
topovision

๐Ÿงฎ Core Functionalities (Mathematical Overview)

Feature Description Method
Partial Derivatives Calculated using finite difference methods Central Difference Scheme
Gradient Vector Visualized as a heatmap Sobel Operator
Volume Calculation Computed with discrete Riemann sums Trapezoidal Rule
Arc Length Calculation Calculated as the sum of Euclidean distances Vectorized NumPy operations
3D Surface Visualization Dynamic and interactive 3D plots of topographic surfaces Matplotlib + NumPy
Perspective Correction Uses a 4-point homography to correct for perspective OpenCV getPerspectiveTransform

๐Ÿงฉ Development Workflow โ€” GitHub Flow

๐ŸŒฟ Main Branches

Branch Purpose
main Stable release branch
develop Integration branch
feature/* Individual development tasks
hotfix/* Urgent fixes
docs/* Documentation-only updates

๐Ÿ’ฌ Commit Convention

Follow Conventional Commits format:

<type>(<scope>): <description>

๐Ÿงช Testing

Run the test suite:

# Install with dev dependencies
pip install topovision[dev]

# Run tests
pytest

# Run with coverage
pytest --cov=topovision

๐Ÿ‘ฅ Team Members

Name Role
Alejandro Botina Herrera Technical Lead & System Architect
Andreina Olivares Cabrera Interface Developer & Documentation
Jonathan Joel Ruviรฑo Testing & Numerical Computation
Kiara Vanessa Muรฑoz Bayter Environment Setup & Visualization
Vรญctor Manuel Barrero Acosta Capture Systems & Demonstrations

๐Ÿงพ License

This project is licensed under the Apache License 2.0. See the LICENSE file for more details.


๐Ÿ”— Links


๐ŸŽฏ TopoVision โ€” bridging the gap between Calculus and reality, one frame at a time.


Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

topovision-0.2.1.tar.gz (53.4 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

topovision-0.2.1-py3-none-any.whl (61.2 kB view details)

Uploaded Python 3

File details

Details for the file topovision-0.2.1.tar.gz.

File metadata

  • Download URL: topovision-0.2.1.tar.gz
  • Upload date:
  • Size: 53.4 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for topovision-0.2.1.tar.gz
Algorithm Hash digest
SHA256 7409f933fb8edbbb76eeb7df0704c2a1602c39763b71ddbb59ba6ea93ae71903
MD5 7688119afceb6d97313a989a14ea4921
BLAKE2b-256 16bcc500633dcf4f3cd9025b4298c4749e7dc6f509a8870ad0bd5eef98c698a7

See more details on using hashes here.

File details

Details for the file topovision-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: topovision-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 61.2 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.14.0

File hashes

Hashes for topovision-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 762d0b04a7f48358d42eab785c1aeaa2c1ff34e64cfb2d43c3f8c8a49d56f576
MD5 fed90b3c5abc8ca1f688bf585c080d2a
BLAKE2b-256 5aafdf40059c4f473d5913a4b57b6e43ba2ce3db41630bca07e82dd10670a38f

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page