Removing moving straight trails before stacking

Before stacking, the tool compares neighbouring photographs, checks each proposed line on the full-resolution original, repairs it with sky observed in the neighbouring frames, and then builds the stack once. A straight line alone cannot honestly tell an aircraft from a satellite or a meteor, so the receipt reports the measured track instead of guessing what made it.

On this page
The finished star trail from the video guide, one night with a Sony A7C 4:38 Video · from 2:56 Watch Review in action (from 2:56) On one real Sony A7C night the run found 780 straight tracks. The video opens Review, inspects one candidate’s source frame, overrules its decision, restacks and compares the same crop before and after. Play →

Chapters that open at each step, and the night’s facts: video guides.

What it looks like on a real frame

These three panels are one exposure from a public observatory sequence, put through this tool's own engine. Nothing is illustrated or redrawn: the outline is where the detector said the track was, and the third panel is the difference between the frame as recorded and the frame after repair.

The exposure as recorded, with the aircraft trail present. The same exposure after the trail was repaired from a neighbouring frame.

Drag, or use the arrow keys. The two frames differ by 667 samples out of 129,600 in this crop, so the wipe is a fair test of how little a single frame changes — and the panels below are where that half per cent is visible.

An all-sky exposure at night: stars, the observatory dome lit red, and a faint dashed line crossing the frame.
As recorded. The dashed line running down the middle is an aircraft, broken into dashes by its own anti-collision strobe.
The same exposure with an orange outline drawn around the aircraft trail the detector located.
What it found. The outline is the track the matched filter reported: 66 px long, 6.8 px wide, 57.4°. This is the hard part, and it is invisible in a before/after.
A near-black frame with one short blue-white segment: the light that was removed.
What came out. The difference between the two stacks — 667 samples, all of them inside the mask. That is the whole visible change, and it is half a per cent of this crop.

Frames from the Yebes Observatory All Sky Gallery, 13 May 2021 — image property of Yebes Observatory, used with credit. The original sequence is public, so every number below can be reproduced against it.

Why the honest picture is undramatic

A before/after of a single frame barely moves, and it would be easy to pick a more flattering example or to brighten the difference until it looked impressive. Here is the real figure instead: on this endpoint the repair changed 667 of 3,273 masked samples. One frame carries one dash of a dashed trail; the rest of that aeroplane is in the frames either side.

The number worth having is a different one. Of the 3,273 samples the mask covered, 3,273 — every single one — matched an observed donor exactly: not an interpolation, not a blur, but the sky as another frame of the same night actually recorded it. Zero samples came out above the donor and zero below it.

What that costs, and what the usual method costs instead

The ordinary approach is sigma rejection: compare each pixel across the sequence and discard the outliers. It works, and it removes every transient in the night with the same stroke — the meteor you waited four hours for, the Iridium flare, the satellite pass you wanted. There is no setting that keeps one and not the other, because to the arithmetic they are the same event.

Finding the track before the stack means the decision is about this measured line: whether it is present in the target exposure and absent from the neighbouring view of the same sky, and whether the original pixels confirm its width and continuity. That evidence can remove aircraft, satellites and meteors alike; it does not pretend a straight track reveals which object made it.

No trained model is used

The trained model that was once offered as a second opinion failed validation on 6 September 2026: its weights match an untrained export, so the earlier model comparison figures did not establish the quality of the file delivered by this site. We withdrew those claims and removed the model and its inference runtime from the app; nothing is downloaded for it.

The ordinary sequence-based line detector remains available. Review its proposed changes and check the finished picture for residual tracks; an absence of proposals does not prove an absence of aircraft or satellites.

If a line is left on the finished picture

When the run is done, the picture comes first, with the Lines tool in the rail beside it. Open Lines, press Mark a missed line and drag along the line with a finger, a pen or the mouse. The page looks for the line your stroke meant and asks which photos it came from, using the stack's record of which photo made each pixel. When it finds one, it draws it dashed and says, for example, Is this the line? It is drawn dashed. It stands out in 3 photos. — the number is photos, not pixels or detections. Press Remove this line, or Not this to draw again. An aircraft blinking across several photos leaves several lines a few pixels apart, and each photo is marked on its own one.

Each marked line is listed with how many photos it is in (Line 1 — in 3 photos) and its own Undo. Nothing changes in the picture until you press Apply changes; several lines, and Undos of lines already removed, are applied together. When the previous run was kept for it, the picture is updated without running the night again. Otherwise the night runs again with those photos repaired from their neighbours, as for a line the detector found, and the tool says why, in one sentence such as The previous run was not kept for a quick update. or The settings have changed since this picture was made. When it has finished it says Line removed. The updated picture is ready in Export. The marks are remembered for that night in your browser, so the next run of the same photos removes the line again. A line that is in every photo — a wire, a road, a lit edge — belongs to the scene, and nothing is marked.

When it says no, and what to do

These are the tool's own words, as the stacker shows them, and what each one means.

Line search: Could not run: no timing
Your photos record no exposure or interval, so the automatic search cannot size a line. The processing notes say where the fix is: open Advanced options, tick Use timing I enter for this sequence, type the exposure and the start-to-start interval, and stack again. Before Start, the plan card says Trail cleaning: timing needed for the same reason.
Gap filling: Not applied: these photos record no exposure or interval — enter the timing to fill gaps
The same missing timing, seen by gap filling: enter it as above. Not applied: the gaps between photos could not be measured in these files means the timing was there but the gaps still could not be measured; Not needed: gaps under 1 px means there was nothing to fill.
Line search: Off for this run
Moving-line removal was switched off for that run: no search ran and no line was masked. Tick Remove aircraft and satellites again and stack again, or use Lines › Mark a missed line on the picture.
Line search: 120 of 140 frames searched
The search ran on part of the night; the other frames could not be assessed. Inspect the picture for remaining tracks and use Lines › Mark a missed line on any you find.
Nothing stands out along this stroke in any photo, so there is nothing to remove. Draw exactly over the line.
The stroke missed the line. Zoom in and drag exactly along it, from one end to the other.
No photo stands out along this line, so it looks like part of the scene — a wire, a road, a lit edge — rather than something that passed. There is nothing to remove.
The line is in every photo, so it is part of what you photographed, not a passing aircraft or satellite.
That was too short to be a line. Drag from one end of it to the other. and No clear line there. Zoom in — with two fingers, or the browser's zoom — and drag along the whole line.
The stroke was too short to follow. Zoom in and draw the whole line.
The photos behind this line could not be looked up. Try again after the next run.
The record of which photo made each pixel is not available for this picture. Run the night again, then mark the line.
Removed from 3 photos. Part of the line is still visible — draw over the rest.
After the update the stroke still finds part of the line. Draw over the part that is left and apply changes again.
Update stopped before every photo was stacked. Your marks are kept; apply changes again for the whole night.
The night was stopped while it ran again. Nothing is lost: press Apply changes again.
How the detector actually works, and what it refuses to do

A threshold cannot see a faint trail. Summing along a line can.

The first version of this thresholded the residual at 4σ and labelled connected components. That fails twice over, and both were measured on real frames rather than argued. A connected component breaks at a gap: an aircraft's strobe flashes 40–100 times a minute, so in a 30-second exposure the light is a row of dashes, and labelling turns one aeroplane into forty specks that each fail the length test. And a threshold-then-label detector cannot see anything below its threshold — so a faint trail is invisible however long it is.

Summing along a line recovers √L. A 1.4σ-per-pixel streak over 80 px is a 12σ event once you add it up, and a 4σ threshold never sees a pixel of it. So the search is a matched filter along straight segments — a windowed Radon transform — and the interesting work is in the verifier, because everything a matched filter finds that is bright is also a star.

It will not remove what it cannot repair

A mask is only applied where a neighbouring frame can supply the sky underneath. If no donor exists the candidate is reported and left alone, with the reason given, rather than being cut out and filled with a guess. And if the detector believes a large part of the frame is aircraft, it concludes that the detector is wrong about that frame and removes nothing.

What it has never been able to tell you

Whether a track was an aeroplane or a satellite. Two attempts failed on the same obstacle: the labels available were morphology — somebody looked at a track and decided what it was — and rate, uniformity and gap did not separate them. Aircraft navigation lights are the first signal that ever pointed the right way, and two of two is a direction, not a rate.

The route out is not a better feature but better truth: for a frame whose time and place are known, which satellites were above the horizon and how fast each was crossing is computable from published orbital elements. That work is under way, and this page will carry the number when there is one worth carrying.

Which cameras and file types any of this has actually been measured on is a separate question, and it has its own page: what it can read, and what has been through it.

Try it on your own night

Open Star trails in the stacker Your photos are not uploaded and nothing is installed; the frames are read in your browser.

Generated test frame with one accepted moving line, the exact count of masked pixels and a reduced picture of the mask.
A generated test frame: the detector’s mask over one track, with the number of pixels it covers.