PowerLine Vision — Automated Detection of Overhead Conductors from Aerial Imagery
Overview
This project develops an end-to-end deep learning pipeline for the automatic detection of overhead power lines and transmission towers from aerial imagery. The system addresses a core challenge in electricity distribution asset management: identifying and mapping low-voltage conductors at scale, including those that are partially obscured or difficult to locate manually.
The pipeline combines YOLOv8 object detection with classical computer vision preprocessing (OpenCV) and produces confidence-scored bounding box detections suitable for downstream GIS integration and asset mapping workflows.
Live Demo: https://karanm5-powerline-vision.hf.space
Motivation
Electricity distribution networks span thousands of kilometres. Manual inspection and mapping of overhead conductors is time-intensive, expensive, and prone to gaps in coverage. Automated detection from aerial and UAV imagery offers a scalable alternative — enabling utilities to maintain accurate, up-to-date asset records and identify infrastructure that may be hidden by vegetation or environmental occlusion.
This project is directly motivated by real-world infrastructure intelligence challenges in the UK electricity distribution sector.
Dataset
This project uses the TTPLA Dataset (Transmission Towers and Power Lines from Aerial imagery), a publicly available annotated dataset containing aerial images of overhead power line infrastructure.
- Source: TTPLA Dataset — GitHub
- Classes: Power lines, Transmission towers
- Format: COCO-style annotations, converted to YOLO format for training
- Split: 70% train / 15% validation / 15% test
To download and prepare the dataset:
python data/download_data.py
Project Structure
powerline-vision/
├── README.md
├── requirements.txt
├── configs/
│ └── config.yaml # Training and model hyperparameters
├── data/
│ ├── download_data.py # Dataset download and preparation script
│ └── processed/ # YOLO-format annotations after conversion
├── notebooks/
│ ├── 01_data_exploration.ipynb # Dataset statistics and visualisation
│ └── 02_results_analysis.ipynb # Post-training evaluation and analysis
├── src/
│ ├── dataset.py # Dataset loading, conversion, augmentation
│ ├── train.py # Training pipeline
│ ├── evaluate.py # Evaluation: mAP, precision-recall, F1
│ └── utils.py # Shared utilities and visualisation helpers
├── scripts/
│ └── inference.py # Run detection on new images or video
├── results/
│ └── plots/ # Training curves, detection visualisations
└── tests/
└── test_dataset.py # Unit tests for data pipeline
Model Architecture
The detection backbone is YOLOv8n/s (Ultralytics), fine-tuned from COCO pretrained weights on the TTPLA dataset. YOLOv8 was selected for:
- State-of-the-art real-time detection performance
- Strong transfer learning capability from diverse pretraining
- Native support for custom dataset fine-tuning
- Efficient inference suitable for edge deployment scenarios
Preprocessing uses OpenCV for image normalisation, contrast enhancement (CLAHE), and augmentation (horizontal/vertical flip, mosaic, HSV jitter).
Results
| Metric | Value |
|---|---|
| mAP@0.5 | 0.688 |
| mAP@0.5:0.95 | 0.561 |
| Precision | 0.758 |
| Recall | 0.647 |
| Inference speed (GPU) | 4.9ms per image (Tesla T4) |
| Validation images | 359 |
| Instances evaluated | 2,738 |
Trained for 50 epochs on YOLOv8s fine-tuned from COCO weights. Dataset: aerial power line imagery (cable detection). Hardware: Tesla T4 GPU.
Quickstart
1. Install dependencies
pip install -r requirements.txt
2. Download and prepare data
python data/download_data.py
3. Train
python src/train.py --config configs/config.yaml
4. Evaluate
python src/evaluate.py --weights results/best.pt --data configs/config.yaml
5. Run inference on a new image
python scripts/inference.py --source path/to/image.jpg --weights results/best.pt
Training Results
Training curves and detection visualisations from the completed run:
Sample detections on validation images:
Limitations and Future Work
- Detection performance degrades under heavy occlusion from tree canopy — a known challenge in UK distribution networks
- LiDAR point cloud fusion is identified as a key extension to improve detection of hidden conductors; this is a planned next phase of development
- GIS export of detected conductor coordinates is in scope for a future release
Author
Karan | MSc Data Analytics (Distinction), Aston University
LinkedIn | GitHub
Acknowledgements
- TTPLA dataset authors for making aerial power line imagery publicly available
- Ultralytics for the YOLOv8 framework
Metadata
Release files for powerline-vision 1.0.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | Provenance | Actions |
|---|---|---|---|---|
| powerline_vision-1.0.0.tar.gz | 13.7 kB | Without provenance | Details for powerline_vision-1.0.0.tar.gz |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Actions Reset |
|---|---|---|---|---|
| powerline_vision-1.0.0-py3-none-any.whl | Python 3 | none | any | Details for powerline_vision-1.0.0-py3-none-any.whl |
Total release size: 28.0 kB
Release files / powerline_vision-1.0.0.tar.gz
| Download URL | powerline_vision-1.0.0.tar.gz |
|---|---|
| Size | 13.7 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
a15257c94fd29054b103f5243d945a7571276be6540aa790724b9fe61f03a278
|
|
BLAKE2b-256 checksum How to use checksums |
4e4b14d884768bc8c3b60b003f489e557970ecb91cd55db16d23dad80a1528fb
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.13
|
Release files / powerline_vision-1.0.0-py3-none-any.whl
| Download URL | powerline_vision-1.0.0-py3-none-any.whl |
|---|---|
| Size | 14.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
f6653a193af6f1744ea754859374716689714adc331bb54a03a237adb09921e1
|
|
BLAKE2b-256 checksum How to use checksums |
94e4c3003468998d07b36c5cc9eb5cc173534c9beefbb638dad8ada2040a7673
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/6.2.0 CPython/3.12.13
|
Security for powerline-vision 1.0.0
Provenance
Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.
No provenance found
None of the files in this release were uploaded with provenance metadata.
A note on package security
PyPI is a repository for distributing packages, not a service for auditing them. While third-party security researchers and our staff do their best to detect and remove malicious packages, PyPI cannot guarantee the quality, security or suitability of any given package.
To learn more about protecting yourself from malicious actors, visit our package security documentation.