| ▲ | Using the railway network as a flatbed scanner(philo.gay) | |||||||||||||||||||||||||||||||||||||||||||
| 317 points by otherayden 7 hours ago | 50 comments | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | msisk6 6 hours ago | parent | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Ward Cunningham and I did something similar back in 2008. We were both at a startup in Portland and our office was along the railroad tracks east of the Willamette. We were up on the 4th or 5th floor right above a lot of train traffic including Amtrak. I brought in some extra Mac gear I had including one of the early iSight cameras which back then was an external device you stuck on the top of your display and connected to the Mac via FireWire. We set it up and rolled the desk over to the window in the office and turned the camera around pointing down at the tracks and Ward got to work hacking something up to do a slit scan. It was a fun little project; the speed of the trains affected the horizontal compression of the images. We could tweak the software to expand or contract the size of the image by adjusting the number of slit scans per unit of time. Of course, that affected the exposure but I recall the camera having some automatic adjustments that gave us trouble. That's about all we did with it. Just a quick afternoon hacking project. Neither of us thought much about it at the time so we didn't save anything. | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | decae 6 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
I've posted this here before but I have been creating animations using a similar process with a regular camera and manually splicing the frames together. [1,2,3] The effect is quite interesting in how it forces focus on the subject reducing the background into an abstract pattern. Each 'line' is around 15px wide. I think I went through exactly the same thought process as the author, funny how ideas can come up independently like this. [1] https://youtube.com/shorts/VQuI1wW8hAw [2] https://youtube.com/shorts/vE6kLolf57w [3] https://youtube.com/shorts/QxvFyasQYAY I also shot a timelapse of the Tokyo skyline at sunset and applied a similar process [4], then motion tracked it so that time is traveling across the frame from left to right[5]. Each line here is 4 pixels wide and the original animation is in 8k. [4] https://youtu.be/wTma28gwSk0 [5] https://youtu.be/v5HLX5wFEGk | ||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | jonty 6 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
If you want to play around with slit scanning, I made this little toy a number of years ago and frequently find myself using it on trains: Press and hold your phone screen to switch between the front/back cameras, or hit "c" on a computer. Tapping the screen saves the image, as does "s". | ||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | Terr_ an hour ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Recycling comment from another submission 17 day ago: > Random thought: If you stick a very small adhesive mirror to the outside window before boarding, then footage "looking down" at the regularly-spaced railroad ties could contribute to information about the current speed and acceleration. > Well, on a straight section anyway, if you turn, the inner/outer edges will appear differently-spaced... > Wouldn't do anything positive in terms of suspicious staff though. They might think it's like some kind of heist-movie that will involve a specialized glass cutter making a circle on the window. | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | mhb 7 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | awwaiid 6 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
I love this sort of project and write-up. Inspiring to try something a bit different and dance on that line between practicality and artwork. The in-progress "scans" are themselves an interesting stretching of time and space, even if they aren't what the artist is ultimately going for. | ||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | dllu 2 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
As someone who also did some line scan photography, I also ran into a lot of similar challenges! > Displaying and sharing the pictures I've taken has been a pain throughout the project. Most software on my computer doesn't like how big they are, and the most reliable tool I've found for viewing them has been GNU IMP, which feels a bit overkill. I vibe-coded my own image viewer, sriv, to address this: https://github.com/dllu/sriv Also, I found that displaying the images with multiple rows instead of a single super wide image is a lot more ergonomic. > I correct for it for a given subject by shifting the red and blue channels to line up with the green channel. Since the lines are evenly spaced, I can shift by the same amount in opposite directions rather than having to measure separate offsets for each channel. In theory, I could decide how far to shift by correlating brightness shifts across channels, but at present, I do it manually. I implemented the correlation-based approach: https://daniel.lawrence.lu/blog/2025-09-21-line-scan-camera-... Recently, I also vibe-coded a tool for me to manually annotate constraints to fine-tune the distortion correction: https://daniel.lawrence.lu/blog/2026-08-02-line-scan-camera-... For a stationary camera imaging a train, you just need to estimate the train's speed. But for the inverse problem of imaging the landscape from a moving train, the speed varies due to parallax (near things move faster, far things move slower), so there's no way to fully eliminate the RGB fringing for all distances. > The biggest one is to make it not dependent on a laptop to capture images, which will make it less sketchy and easier to bring places. I did just that recently, by adding an NVIDIA Jetson Orin Nano and a 7" 2000 nit touchscreen as well as a custom-designed CNC aluminum case: https://daniel.lawrence.lu/blog/2026-06-12-standalone-cnc-li... | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | ggerules 4 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Taken to the extreme.... I gotta wonder. Owen from RanOutOnARail could make some incredible wide pictures from his journeys if he had this setup. Been watching his YouTube channel for years [0], [1]. He has a Patreon account with more videos [2]. He use to have a lot more videos on YouTube. It's illegal to ride trains the way he does, but his videos helped get me through the long time of the covid pandemic after I would stop work for the day. [0] https://youtube.com/@ranoutonarail?si=ElAeMpcrJASsE3Ov | ||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | Diti 2 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Is there something wrong with the pictures in the second half of the article? It seems like they are taking forever to load (about 30 seconds each), one at a time. I’m on mobile (iOS). | ||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | tvbusy 2 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
I wonder if having another normal camera capturing at the same time to assist with stitching images together will be easier than measuring acceleration? The normal camera doesn't need to have high resolution, just enough to align the images. | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | strohwueste 6 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Great writeup! Planned doing the same thing Herr in germany. Thought a Smartphone camera would be enough but there no way to access the camera2 api for those highspeed recordings. I took 1h long 240hz 4k vertikal videos (out of the Schwebebahn in Wuppertal) which could be displayed by MacOS preview. Right no im waiting for a good gaussian splatting tool to create the driving of the "Train” in Blender. The newest Lingbot-map is unfurtunatly not really trained for sideway movement. I always asked myself if the sideway movement and the Parallaxe would make way easier to infer the distance and the 3d scanning capabilities because the pixel only really move one as long you dont drive turns | ||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | waltbosz 5 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
The wobbly pictures brings me back to my experience as a kid with hand-held photo scanners https://oldcomputer.info/pc/apscan/index.htm . It was impossible (for me at least) to get a scan without shifting my hand position on the X-axis while also sliding the scanner down the picture. Also, I seem to recall the scanner I used was only capable of outputting 1-bit dithered black and white pictures. This was late 80s/early 90s tech. | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | apt-get 3 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Related - filming light at 2 billion fps with a somewhat similar setup in concept (at the single pixel scale): https://www.youtube.com/watch?v=o4TdHrMi6do | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | adamjb 6 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Not quite in the same spirit but I suppose one could talk of railway operators using the railway network as a flatbed scanner when they send maintenance vehicles out to scan the railbed for defects. For example: https://railgallery.wongm.com/ev120-inspection-vehicle/F144_... https://www.youtube.com/watch?v=5TKDw2E_PBQ | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | andrewla 5 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
This project is more deeply technical but one thing I find fun is to take a video from a moving train and create a video stereogram by having one eye lagging in time/distance behind the other eye, letting you create very long baseline stereograms. It's fun to be able to see the 3d effects on passing bridges, etc., and for large baselines on long straight stretches you can see the 3d structure of clouds in a fascinating way. | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | dllu 4 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Neat. It links to some of mine from an older HN comment but here's another one of some houses from Caltrain: https://i.dllu.net/2017-11-23-14-30-54_stack_cdb771693eea9fe... | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | grumbelbart2 6 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Railway operators do this to inspect tracks: Mount a line-scan camera that looks down, get an "infinite" image of the tracks, inspect for anything interesting. | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | cscheid 5 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
This is so cool. It's a much better version of what Bill Cheswick and I did almost 15 years ago with footage from a SFO->EWR flight: https://cscheid.net/static/windowseat/ | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | mofosyne 6 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Reminds me of when railways attempted to attach linear barcodes on their train and read it using a similar method | ||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | ano-ther 4 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Neat. Long Train photos from a still camera here: | ||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | dorfsmay 6 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Nice. It reminds me of a blog of a guy who had mounted a flatbed scanner on an electrical motor to make a digital photo before digital camera existed. He had added one of the resulting picture of his backyard. It was one of the most viral Slashdot post at the time. | ||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | wowczarek 2 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
In 2013-14 or so, one person, Adam Magyar, did a similar thing with a hand-built line scan / slit scan camera and made quite interesting portraits of NYC subway cars and passengers: https://medium.com/matter/einsteins-camera-88aa8a185898 [now paywalled, it wasn't when first published] | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | Tepix 6 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Has anyone done the same for other rides with wheels? I guess that would end up being NeRF (Neural Radiance Fields) & Gaussian splatting? | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | mhb 6 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
Lynx photo finish cameras. Same idea: | ||||||||||||||||||||||||||||||||||||||||||||
| ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | hn9zmdcaou 5 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
The honesty is what makes it good | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | 13hours 5 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
This is how satellites (mostly) take pictures. | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | demo780 2 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
sev | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | exe34 5 hours ago | parent | prev | next [-] | |||||||||||||||||||||||||||||||||||||||||||
That's clever! I had the idea to use video to remove things like fences by moving the recording device, but never got around to implementing it. | ||||||||||||||||||||||||||||||||||||||||||||
| ▲ | PunchyHamster 4 hours ago | parent | prev [-] | |||||||||||||||||||||||||||||||||||||||||||
> but I think the results speak for themselves. ... as in not very good compared to normal camera ? Acceleratometer-based correction can only do so much Normal camera allows you to get a snapshot of 2D area instead of 1D area so you can make any correction for movement afterwards. With linear one you just get artifacts like the introductionary pic being very wobbly up and down. | ||||||||||||||||||||||||||||||||||||||||||||