Aircraft movement extraction — processing log

================================================================================
AIRCRAFT MOVEMENT EXTRACTION - PROCESSING LOG
East Midlands Airport (IATA: EMA / ICAO: EGNX), Castle Donington, Leicestershire
================================================================================
Processed: 2026-09-07
Operator of pipeline: autonomous video-processing assistant

--------------------------------------------------------------------------------
1. SOURCE VIDEO
--------------------------------------------------------------------------------
URL             https://www.youtube.com/watch?v=a7AGdvThYic
Video ID        a7AGdvThYic
Title           "20 + mins of awesome landings and takeoffs at East Midlands Airport"
Channel         EMAplanespotting
Upload date     2026-08-26
Description     "Filmed over the last week or so..."  (full description; no more text)
Chapters        none published
Subtitles       none (no manual and no automatic captions available)
Tags            none

Retrieved format 137 (H.264 1920x1080) + 251 (Opus audio), merged to MP4.
1080p is the highest resolution offered by the source; no 1440p/2160p exists.

ffprobe of the downloaded master:
  container      mov,mp4,m4a  -  388,906,926 bytes
  video          h264 (High), 1920x1080, yuv420p, 16:9, 30000/1001 fps (29.97), 41,149 frames
  audio          opus, 48000 Hz, 2 channels, ~114 kb/s
  duration       1373.00 s (00:22:53)
  overall bitrate ~2.27 Mb/s

Metadata useful for identification: none embedded. No creator timestamps, no chapter
markers, no on-screen date/time. The description states the footage was shot over
roughly a week before the 2026-08-26 upload, so individual clips cannot be tied to a
specific calendar date. This is the reason ADS-B / flight-tracking correlation was NOT
used (see section 6).

--------------------------------------------------------------------------------
2. TOOLS USED
--------------------------------------------------------------------------------
yt-dlp 2026.08.19        source retrieval + metadata/description/subtitle probing
ffmpeg / ffprobe         media inspection, frame extraction, scene analysis,
                         clip cutting, thumbnails, preview encoding, audio extraction
Python 3.12              orchestration, analysis, CSV/XLSX/webpage generation
NumPy                    frame-difference and audio-envelope signal analysis
Pillow (PIL)             contact sheets, zoom/crop/enhance panels for visual ID
Ultralytics YOLO11       aircraft detection (COCO class 4 "airplane")
                         - yolo11x @ 1536/1280 px trialled, then yolo11l @ 1536 px used
PyTorch 2.6 + Apple MPS  detector acceleration
openpyxl                 Excel workbook generation
Web search / web fetch   operator, fleet and livery verification (sources in section 7)

--------------------------------------------------------------------------------
3. MOVEMENT DETECTION - WHAT WORKED AND WHAT DID NOT
--------------------------------------------------------------------------------
Attempt 1 - ffmpeg scene detection (`select='gt(scene,0.25)')`.
  RESULT: FAILED. Zero cuts detected across the whole video; the maximum scene score
  anywhere was 0.238. Cause: the compilation is shot largely from fixed vantage points
  around the same airfield, so a cut from one recording to the next produces almost
  identical colour histograms (sky over grass over runway). Histogram-based scene
  detection is blind to these cuts.

Attempt 2 - raw frame-difference (mean absolute difference at 96x54 grey, all 41,149
  frames), plus a "peak sharpness ratio" (instantaneous difference divided by the local
  median difference) designed to separate instantaneous cuts from sustained panning.
  RESULT: PARTIAL. It found a handful of genuine cuts (05:31, 08:00, 14:06, 20:03) but
  was dominated by false positives from (a) the camera panning to track aircraft and
  (b) regularly spaced (~1.23 s) anti-collision beacon flashes at 12:02-12:15 and
  15:51-15:59, which produce large brightness deltas that mimic cuts.

Attempt 3 - audio discontinuity (log-RMS envelope at 0.1 s resolution).
  RESULT: WEAK. The soundtrack is dominated by wind and near-continuous engine noise
  and appears loudness-normalised, so the envelope sits at 6-8/8 almost throughout and
  discriminates poorly. It did reliably mark a few hard cuts by near-silence
  (00:08-00:13, 08:08, 12:56, and the 22:46 outro).

Attempt 4 - aircraft-presence timeline from object detection.
  1,373 frames sampled at 1 fps were run through YOLO11; an aircraft was detected in
  1,232 of 1,373 frames (89.7%). Because aircraft are visible for nearly the whole
  video, presence alone produced only 11 blocks, the largest spanning 6m48s and
  containing many separate events. Insufficient on its own.

METHOD ACTUALLY ADOPTED - systematic visual review.
  The full video was rendered as 20 labelled contact sheets (one frame every 2 s,
  timestamp burned in), and every ambiguous region was re-rendered at 1-second
  resolution. Movement boundaries, landing-versus-takeoff calls and aircraft
  identification were then made by direct inspection, using the detector only to
  locate the aircraft within each frame for automatic high-resolution zoom crops.
  This was slower than an automatic cut list but is the only approach that produced
  reliable boundaries on this material.

--------------------------------------------------------------------------------
4. WHAT THE VIDEO ACTUALLY CONTAINS
--------------------------------------------------------------------------------
The source is not a continuous run of movements. It is a mixture of:
  - genuine landings and takeoffs                    -> 13 clips produced
  - long taxi-only sequences with no rotation or
    touchdown anywhere in the shot                   -> excluded, listed in section 5
  - a branded intro and an outro card                -> excluded
  - "waiting" footage of empty runway / empty field  -> excluded

13 aircraft movements were detected, cut and catalogued:
  clip  source timecode        aircraft                 operator          movement
  0001  00:00:16 - 00:01:33    Airbus A321neo           Jet2              Takeoff
  0002  00:01:34 - 00:02:39    ATR 72-600               Loganair          Takeoff
  0003  00:07:20 - 00:08:06    Boeing 777F (D-AALG)     AeroLogic         Takeoff
  0004  00:08:11 - 00:08:39    Boeing 777F              AeroLogic         Landing
  0005  00:08:40 - 00:09:20    Boeing 747-400F          One Air           Landing
  0006  00:12:27 - 00:12:54    Boeing 747-400F          One Air           Takeoff
  0007  00:15:04 - 00:15:31    Boeing 777F (B-2082)     Central Airlines  Takeoff
  0008  00:15:33 - 00:16:04    Unknown (twin jet)       DHL               Takeoff
  0009  00:16:05 - 00:17:02    Boeing 777F              One Air           Landing
  0010  00:18:29 - 00:19:06    Airbus A300-600F         DHL               Landing
  0011  00:19:20 - 00:19:28    Unknown turboprop        Unknown           Landing
  0012  00:20:27 - 00:21:28    Airbus A330 MRTT         Royal Air Force   Landing
  0013  00:21:59 - 00:22:45    Boeing 777F              DHL               Landing

No duplicate clips were produced. Clips 0003/0004 are the same operator and type but
are demonstrably separate events (different weather, light and camera position), and
clips 0005/0006 are two different 747-400Fs (different liveries).

--------------------------------------------------------------------------------
5. SECTIONS OF THE SOURCE DELIBERATELY NOT TURNED INTO MOVEMENT CLIPS
--------------------------------------------------------------------------------
Step 13 of the specification states that ordinary taxi footage must not be classified
as a separate aircraft movement unless it is clearly associated with the beginning or
end of a landing or takeoff, and the `movement` field admits only "Landing" or
"Takeoff". The sequences below show an aircraft taxiing only: no take-off roll, no
rotation, no touchdown, no deceleration, and (checked frame by frame at high zoom) no
deployed spoilers and no thrust reversers. They therefore cannot be assigned a movement
value on the available evidence and were excluded rather than guessed at.

They are recorded here in full so that nothing in the source is silently lost:

  00:00:00 - 00:00:15  Channel intro / title sequence. Contains a One Air Boeing 777F
                       on final approach (gear down) with the channel name overlaid,
                       plus ~4 s of an unidentified narrow-body climbing away. Excluded
                       as branding; it also risks being re-used footage of the same One
                       Air 777F arrival that appears in full as clip 0009.
  00:02:40 - 00:07:24  AeroLogic Boeing 777F D-AALG, continuous taxi to the runway.
                       This IS associated with clip 0003 (its takeoff) but is 4m45s of
                       taxi, so it was trimmed out to avoid excessive dead footage.
  00:08:04 - 00:08:11  Dassault Falcon business jet, static on stand. No movement.
  00:09:20 - 00:10:33  DHL Boeing 767 freighter, taxi with lights on. No movement.
  00:10:34 - 00:11:29  Star Air (Maersk) Boeing 767 freighter, taxi. No movement.
  00:11:30 - 00:12:26  DHL freighter, dusk taxi. No movement.
  00:12:54 - 00:13:50  Central Airlines 777F B-2082 parked/loading on stand, camera
                       panning. Belongs to clip 0007 but contains no movement.
  00:13:51 - 00:15:03  Empty field / distant holding aircraft while the videographer
                       repositions to the departure end. Dead footage.
  00:17:02 - 00:18:28  TUI Boeing 737-800, long taxi. No movement.
  00:19:06 - 00:19:19  TUI Boeing 737-800, taxi. No movement.
  00:19:29 - 00:20:26  Jet2 Boeing 737-800 / A321, taxi. No movement.
  00:21:28 - 00:21:58  Ryanair Boeing 737, taxi. No movement.
  00:22:46 - 00:22:53  Outro card ("THANKS FOR WATCHING") over a still DHL 767 image.

--------------------------------------------------------------------------------
6. IDENTIFICATION METHODOLOGY, AMBIGUITIES AND FAILURES
--------------------------------------------------------------------------------
For every movement the aircraft was located with the detector, cropped from the
1080p master at its largest on-screen size, upscaled (Lanczos) and contrast/sharpness
enhanced. Identification then combined: airframe geometry (engine count and position,
wing and winglet form, tail shape, fuselage proportions, upper-deck hump), livery,
readable titles, readable registration, and published fleet/route information for
East Midlands Airport operators.

REGISTRATIONS READ DIRECTLY FROM THE FOOTAGE (High confidence):
  D-AALG   AeroLogic Boeing 777F        - read on the rear fuselage at 07:12
  B-2082   Central Airlines Boeing 777F - read on the forward fuselage at 15:18-15:20

REGISTRATION ATTEMPTS THAT FAILED (recorded as "Unknown", not guessed):
  - One Air / AeroTransCargo 747-400F (clip 0005): a Moldovan ER- registration is
    present on the rear fuselage but is below the resolution limit even at 5x upscale.
  - Loganair ATR 72-600 (clip 0002): a wing registration is visible but illegible; it
    is consistent with Loganair's G-LMT- series but was NOT recorded, to avoid
    inventing data.
  - Jet2 A321neo (clip 0001), TUI, Ryanair and all DHL airframes: not legible.

AMBIGUOUS IDENTIFICATIONS (reflected in confidence values and in the CSV notes):
  - Clip 0001, Jet2: the airframe is unambiguously an Airbus A320-family narrow-body
    (sharklet wingtips, large circular LEAP-type nacelles, Airbus fin and tailplane).
    "A321neo" is inferred from the fact that the A321neo is Jet2's only Airbus type;
    the variant itself was not measured. Confidence: Medium.
  - Clip 0002, Loganair: high-wing twin turboprop with a T-tail is certainly an ATR.
    "ATR 72-600" comes from Loganair's current turboprop fleet; ATR 42 could not be
    fully excluded from the overhead angle. Confidence: Medium.
  - Clip 0005, One Air 747-400F: carries the red AeroTransCargo "atc" tail with
    "AIRONE" fuselage titles, because One Air leases its 747-400F/747-400ERF fleet
    from AeroTransCargo. The airline is recorded as the visible operator brand,
    "One Air". -400F vs -400ERF was not determinable. Confidence: Medium.
  - Clip 0008, DHL night departure: the DHL identity is certain (yellow fin, red DHL
    logo, confirmed on a bright frame at 15:51.8). The aircraft type is NOT. It is a
    twin-engine jet freighter, but darkness prevents deciding between the Boeing
    757-200F and 767-300F that DHL operates at EMA, so aircraft_model and
    aircraft_type are both recorded as "Unknown". Small operator titles are visible on
    the forward fuselage; several enhancement passes could not resolve them.
    Confidence: Low.
  - Clip 0010, DHL A300: identified as an Airbus A300-600F on planform, fuselage
    length and fin/tailcone shape. Confidence: Medium.
  - Clip 0011: a very brief, strongly backlit silhouette of a twin turboprop on
    approach; the shot cuts before touchdown. Only "Turboprop" and "Landing" are
    supportable. Model, operator and operation type are all "Unknown".
    Confidence: Low. Retained rather than discarded, per the specification.

EXTERNAL DATA THAT WAS NOT AVAILABLE / NOT USED:
  - ADS-B and flight-tracking correlation was NOT attempted. The creator states only
    that filming took place "over the last week or so"; there is no on-screen date or
    time and no metadata timestamp, so no clip can be tied to a specific date/time
    window. Matching against historical ADS-B without a date would have amounted to
    guessing, and historical ADS-B archives are in any case paywalled.
  - No airline schedule cross-check was used to assign identities for the same reason.
  - External sources were used only to confirm what was already visible (operator
    fleet types, livery ownership, EMA route presence), never to force a match.

--------------------------------------------------------------------------------
7. EXTERNAL SOURCES CONSULTED
--------------------------------------------------------------------------------
  East Midlands Airport / MAG cargo pages and Wikipedia - EMA as a DHL, UPS, FedEx
    and Royal Mail hub; DHL Air UK is based at EMA (confirms the DHL 757/767/777
    presence and the A300-600F operated for DHL by European Air Transport Leipzig).
  FlightGlobal / oneair.aero / Air Cargo News - One Air is a UK cargo carrier based at
    East Midlands operating new-build Boeing 777 freighters (first aircraft G-ONEG)
    and Boeing 747-400F/747-400ERF aircraft leased from AeroTransCargo FZE. This
    explains the "atc" tail with "AIRONE" titles seen in clip 0005.
  Air Cargo News / Cargo Facts / JetPhotos - Central Airlines operates Boeing 777Fs
    into EMA for YunExpress (Tianjin-EMA, EMA-Xiamen); B-2082 is a Central Airlines
    Boeing 777-F6N in the YunExpress livery. This corroborates the registration read
    directly from the footage in clip 0007.
  Flightradar24 fleet pages / airline fleet references - Jet2 operates Boeing 737-800
    and Airbus A321neo; TUI operates 737-800 and 737 MAX 8; Ryanair operates 737-800
    and 737 MAX 8200.

--------------------------------------------------------------------------------
8. CLIP, THUMBNAIL AND PREVIEW GENERATION
--------------------------------------------------------------------------------
Clips     H.264 CRF 21, preset medium, yuv420p, AAC 128 kb/s audio, +faststart,
          original 1920x1080 resolution and 29.97 fps retained.
          Boundaries were chosen so that each clip contains exactly one movement, opens
          with a few seconds of run-in, and does not bleed into the adjacent shot. No
          two clips overlap (verified programmatically).
Thumbnails 1280 px wide JPEG (q3), taken at the frame where the detector reports the
          largest aircraft bounding box inside the clip, i.e. the aircraft at its
          clearest, clamped to stay at least 1 s inside the clip.
Previews  ~5 s, 640 px wide, 24 fps, H.264 CRF 30, no audio, +faststart, centred on the
          same informative moment and clamped to the clip boundaries. Small enough for
          instant hover playback from local disk.

--------------------------------------------------------------------------------
9. ERRORS ENCOUNTERED AND RECOVERY
--------------------------------------------------------------------------------
  - yt-dlp warned "No supported JavaScript runtime could be found"; some formats may be
    hidden as a result. 1080p H.264 was still offered and retrieved, which is the
    maximum resolution the video has, so this had no practical effect.
  - A first `--list-subs` invocation exited before writing the info JSON; rerun without
    that flag. No data lost.
  - The first detection run (yolo11x at 1536/1280 px on MPS) ran at ~2.3 s/frame and was
    projected at ~52 minutes with no progress visibility. It was terminated, four
    detector/size/device configurations were benchmarked, and yolo11l at 1536 px on MPS
    was adopted; it completed 1,373 frames in 480 s with comparable detections.
  - Several registration-reading attempts produced unusable crops (wrong region after
    the aircraft moved between sampled frames). Fixed by cropping from the detector's
    bounding box instead of fixed image fractions. Two registrations were recovered
    this way; the rest genuinely exceed the resolution of the source and are recorded
    as "Unknown".
  - No clip, thumbnail or preview failed to encode. No section of the video was
    unreadable or unprocessable.

--------------------------------------------------------------------------------
10. ASSUMPTIONS MADE
--------------------------------------------------------------------------------
  - All footage is from East Midlands Airport (EMA / EGNX), as stated in the task and
    corroborated by the visible control tower, terminal, DHL and UPS cargo aprons and
    the Rolls-Royce site adjacent to the airfield. airport_iata / airport_icao are set
    to EMA / EGNX for every row.
  - The video is a multi-day compilation (explicit in the description and confirmed by
    large changes in weather, light and camera position between adjacent shots), so
    each shot is treated as an independent event.
  - Where an aircraft appears both taxiing and then departing (AeroLogic D-AALG,
    Central Airlines B-2082) this is treated as ONE movement, not two.
  - "Cargo status is represented separately from the physical aircraft category", per
    the specification: e.g. clip 0013 is Wide-body + Cargo, not "Cargo Aircraft".
  - The RAF Voyager is recorded with aircraft_type "Wide-body" and operation_type
    "Military", following the same principle.

--------------------------------------------------------------------------------
11. KNOWN LIMITATIONS OF THE GENERATED OUTPUT
--------------------------------------------------------------------------------
  - openpyxl cannot author native Excel PivotTable objects from scratch. The workbook
    therefore ships five formatted, filterable Excel Tables with frozen headers plus a
    live formula-driven cross-tab ("Pivot Aircraft x Movement") that recalculates like
    a pivot. A user can insert a native PivotTable over the "All Clips" table in one
    step if required.
  - 11 registrations out of 13 movements are "Unknown". This is a limit of a 1080p,
    ~2.3 Mb/s source, not of the process.

--------------------------------------------------------------------------------
12. ATTRIBUTION AND WEBPAGE PRESENTATION
--------------------------------------------------------------------------------
All footage in output/clips/, output/thumbnails/ and output/previews/ consists of
excerpts from a single video created by the YouTube channel EMAplanespotting:

  Channel  https://www.youtube.com/@EMAplanespotting
  Video    "20 + mins of awesome landings and takeoffs at East Midlands Airport"
           https://www.youtube.com/watch?v=a7AGdvThYic

Copyright in the footage remains with the channel. The webpage credits the channel
in three places - the header, the footer, and the metadata panel of every clip - and
each clip carries a deep link back to the exact moment in the original video
(https://www.youtube.com/watch?v=a7AGdvThYic&t=<start>s), so a viewer can always reach
the source. Anyone republishing these clips should seek the creator's permission.

The webpage is styled to match noregretlearning.com, reusing that site's design tokens
(--ink #0b1a1f, --accent #2f74ff, --accent-dark #1d4ed8, --teal #1b5fbf, the
145deg #e8f1ff/#9ebdff/#79adff page gradient and the 130deg #ffffffcc/#f0f6f3cc card
material) and its Space Grotesk / Playfair Display / IBM Plex Mono type system. The
webfonts are loaded from Google Fonts with system fallbacks (system-ui / Georgia /
ui-monospace), so the page still renders correctly with no network connection.

Embedding: opening the page with ?embed=1 removes the page background and the tall
hero block so the catalogue sits directly on a host page inside an iframe, while
keeping the channel credit and the summary statistics. The page also posts its height
to the parent window as {type:"ema-catalogue-height", height:<px>} on load, resize and
after every filter change, so the host can size the iframe and avoid a nested
scrollbar. Example:

  <iframe id="ema" src="output/webpage/index.html?embed=1"
          style="width:100%;border:0" height="900" scrolling="no"></iframe>
  <script>
    addEventListener('message', function (e) {
      if (e.data && e.data.type === 'ema-catalogue-height')
        document.getElementById('ema').height = e.data.height;
    });
  </script>