Skip to content

About

No description, website, or topics provided.

Resources

Stars

3 stars

Watchers

0 watching

Forks

Repository files navigation

PERT & Critical Path Analyzer

Desktop application for analyzing PERT/CPM network diagrams from images. The pipeline combines computer vision, OCR, graph reconstruction, human review, CPM/PERT calculation, visualization, and report export.

Features

  • Detect AON and AOA diagrams from PNG/JPEG images.
  • Detect activities, durations, arrows, and dependencies.
  • Use a review workflow when OCR or graph reconstruction is uncertain.
  • Calculate earliest/latest times, float, critical activities, and critical paths.
  • Export authoritative results to JSON, CSV, Excel, and PDF.
  • Run the analysis through a Qt desktop GUI or the CLI.

Requirements

  • Python 3.11 or newer.
  • Tesseract OCR executable available on PATH for OCR-enabled analysis.
  • Qt runtime is installed through the gui extra.

On Debian/Ubuntu:

sudo apt-get install tesseract-ocr tesseract-ocr-eng tesseract-ocr-ara

Installation

Create a virtual environment and install the complete feature set:

python -m venv .venv
.venv/bin/python -m pip install --upgrade pip
.venv/bin/pip install -e '.[all]'

Optional feature groups are available as gui, ocr, reports, and dev.

Run the application

Launch the GUI:

.venv/bin/pert-analyzer

Analyze one image through the CLI:

.venv/bin/pert-analyzer --cli --image path/to/diagram.png

The CLI reports the project duration, critical path, activity count, and critical activity count when the graph passes validation. Results that require review are intentionally blocked from producing misleading CPM output.

Run tests

For headless environments:

QT_QPA_PLATFORM=offscreen PYTHONPATH=. .venv/bin/python -m pytest

The test suite contains unit, integration, GUI, reference-acceptance, and benchmark tests.

Project layout

Directory Responsibility
pert_analyzer/cv Image preprocessing, shape/arrow detection, OCR, reconstruction, and validation
pert_analyzer/analysis CPM and PERT calculation
pert_analyzer/graph Graph construction and NetworkX adaptation
pert_analyzer/pipeline End-to-end orchestration and review workflow
pert_analyzer/gui Qt application, review screens, validation, results, and visualization
pert_analyzer/reporting Report model and JSON/CSV/Excel/PDF exporters
tests Unit, integration, GUI, reference, and benchmark coverage
docs Acceptance reports, benchmark results, and UI evidence

Important behavior

The application does not silently calculate CPM from an invalid or uncertain graph. It marks the session as requiring review and allows the user to correct activities, durations, or dependencies before continuing. This is deliberate: a visually plausible result is not necessarily a mathematically valid result.

Current limitations

Image analysis quality depends on diagram clarity, OCR quality, and the ability to distinguish graph geometry from text and decoration. Real-world diagrams may require human review, especially during dependency reconstruction. Performance also varies with image size and visual complexity.

License

MIT

About

No description, website, or topics provided.

Resources

Stars

3 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages