How mikehms/cm3070-final-year-project works
This repository implements optimisation-based neural style transfer (NST), exposed through a command-line image workflow and extended with video stylisation and experiment evaluation. The primary path loads content and style images, extracts VGG features, optimises a generated image against content/style/regularisation losses, then saves the image and evaluation outputs. Colour preservation and multi-style blending are supported inside the engine. The README documents the experiment runner and video capability; their internal wiring is not fully shown in the sampled source, so those links are marked unverified.
Main entry points: run_nst.py Image CLI · core.py Optimisation Engine · metrics.py Image Metrics · models.py VGG Features
Components 12
NST Engine
- Optimisation Engine
nst/core.py - VGG Features
nst/models.py - NST Losses
nst/losses.py - Colour Preservation
nst/colour.py
Evaluation
- Image Metrics
nst/metrics.py
Experiments
- Video NST
experiments/video_nst.py - Experiment Runner
experiments/run_experiments.py - Report Figures
experiments/make_figures.py
Other components
- User
- Image and Metrics
Connections 17
- User → Image CLI: configures
run_nst.py - Image CLI → Image I/O: loads inputs
run_nst.py - Image CLI → Optimisation Engine: runs stylisation
run_nst.py - Optimisation Engine → VGG Features: extracts features
nst/core.py - Optimisation Engine → NST Losses: computes losses
nst/core.py - Optimisation Engine → Colour Preservation: preserves colour
nst/core.py - VGG Features → Image I/O: loads calibration images
nst/models.py - Image CLI → Image I/O: saves output
run_nst.py - Image CLI → Image Metrics: evaluates result
run_nst.py - Image CLI → Image and Metrics: writes image and reports
run_nst.py - Video NST → Optimisation Engine: stylises frames
experiments/video_nst.py - Video NST → Image Metrics: scores frames
experiments/video_nst.py - Image Metrics → NST Losses: computes Gram matrices
nst/metrics.py - Image Metrics → VGG Features: uses evaluator network
nst/metrics.py - Experiment Runner → Optimisation Engine: runs experiments
README.md - Experiment Runner → Image Metrics: records metrics
README.md - Report Figures → Image Metrics: summarises evaluations
experiments/make_figures.py