Hacker News new | past | comments | ask | show | jobs | submit login
Live Map of Swiss Trains (vasile.ch)
155 points by ano-ther 9 months ago | hide | past | favorite | 84 comments



It's hard for foreigners to grasp that our comprehensive public transport network connects even the most remote areas of Switzerland. My parents are living on a farm in the countryside and still I can get there easily by train and bus. If I need some more flexibility (moving stuff, skiing, ...), there are electric car rentals available at any major train stations. It's my ideal version of mobility.

PS: The Swiss federal railways also have a large set of open data to enable such cool projects: https://data.sbb.ch/pages/home/


Compare me visiting my parents who live in a "remote" town of in BC about 200km from Vancouver. After a ferry and a bus I found myself outside a grocery store asking strangers for a ride north (no taxi service). A kind soul drove me to the highway turnoff. I walked the last five miles. That's what most of North America is like once you step slightly outside of the major cities: No car, no get there.


Is that surprising given that you could fit over 200 Switzerlands into Canada and another 200 into the US? BC alone is over 20 times the size of Switzerland. Cars are the best possible option in that case surely?


Talking about the overall size of Canada is dodging the issue. The scale of the country does provide a justification for not being able to access any arbitrary spot across Canada (or the US) using public transport, but the previous commenter is talking about accessing a town a mere 200 km away from British Columbia's largest city and urban agglomeration — 3rd largest in Canada as a whole.

How many Switzerlands can you fit within a 200 km drive from Vancouver [0]? My eyeball guess is that the area is half the area of Switzerland, maybe less than a third if we exclude US territory covered in the map. And what's the population density of that area? Again, ignoring the US, just counting Vancouver's [1] and Victoria's [2] metropolitan areas alone adds up to 3,000,000 inhabitants (more than a third of the population of the whole of Switzerland), so this area's population density is very likely to be similar or even greater than that of Switzerland as a whole.

[0] https://www.smappen.com/app/map/802yt

[1] https://en.wikipedia.org/wiki/Vancouver

[2] https://en.wikipedia.org/wiki/Victoria,_British_Columbia


That is correct. Cars are certainly the best option in many circumstances, even from an environmental standpoint. The reason I couldn't get even a taxi was that the taxi company didn't want to drive 30miles just to pick me up, then drive maybe 60miles back after dropping me off. When a small population is spread over a large area, personal vehicles become the most efficient means. That is a large part of why Alaska has the highest rate of private aircraft ownership on the planet. BC rides the literally middle ground between Alaska and the densely populated southern states.


Comparing all of the U.S. or Canada is meaningless, but when you look at regions with similar population densities, then yes, it is surprising. Switzerland only has about half the density of the U.S. East Coast, for example.


And in addition Switzerland has challenging terrain with hills and mountains all over, making train service complicated and even busses non-trivial sometimes


Pn the other hand, the geography forces people to live in valleys. so population is effectively distributed along corridors —- very conducive to being served by rail and bus lines.


The size in itself of is a meaningless metric. I'm baffled that comment like this still get made even on HN. I guess this must be that American just have such a fundamentally distorted view of public transport.

The area of Greater Toronto Area has far denser population then Switzerland with far worse public transport. So by any rational metric it should dominate Switzerland in public transport modal shares and convenience. But it doesn't. So when looking for explanations, we need to look deeper.

Looking at BC, Vancouver is a city of 675,218 people. The Metro area is 2.463 million. Calgary metro is 1.4 million. Edmonton is another metro area of 1.3 million. And the distance between Edmonton and Calgary isn't even very far. Those are 3 cities that are bigger or comparable to Zürich.

I'm not suggesting the population of 'Liard River' of 100 people in the north of BC should have a high speed train to Vancouver. Of course BC as a whole will never have Swiss like public Transit. But if you actually look at where people live, take into account the particular details of the location, you can design a public transport system that is useful for people.

But the comment said '200km' from Vancouver. And he also said there was highway 5 miles from the parents house. So somehow they seemed to think it was reasonable to able to build a highway. Highways are expensive infrastructure, and usually you don't built them the middle of nowhere. So it seems from the comment we are not talking about some place that is at least between two places the somebody connected with a highway. If you have enough money for a highway, you can finance a bus route along it. Most people do live reasonable close together and not just a single house in the wilderness.

If we look at the density map:

https://www12.statcan.gc.ca/census-recensement/2006/as-sa/97...

It seems to me that Vancouver is perfectly placed to have an amazing transport system connecting its city to its metro and its metro to the more outlining towns and villages. There is no reason the great Vancouver area couldn't have Swiss like public transport very every village

Then you have a higher speed train connecting Vancouver to Calgary to Edmonton and all the larger towns in between. Then have regional trains or buses going out from that trunk connecting smaller towns and villages. I suspect these town were all originally built because there was railroad there.

So yes, BC as a whole is big and densely populated. But that metric alone is meaningless when designing a public transport system that can meaningfully serve the population. Even if you think 'cars are the best option', that's no reason not have have decent public transport. Switzerland, has lots of people in cars and its a very viable option. But despite that, it also has other good types of transport. Sometimes its nice not to have only one option, specially for people who for many reasons can't simply drive.

This reoccurring attitude of well its a big country so why even try is so damaging. As if Canada being big had anything to do with why Toronto street cars are a abomination of planning and operations. You have a bit more of a point in regards to BC but even then its wrong for the majority of people.


The cost of building a highway compared to the cost of running even a "once daily" bus service may not be exactly the ratio you think it is, especially if the bus would normally run empty.

A highway is a one-time cost, amortized over many uses, a bus is an ongoing cost.

It would be much easier to "stick a seat" on some government vehicle that already does the trip regularly, allowing a passenger or two to ride along with the mail truck.


a lot of the more remote Swiss bus services are "PostAuto" and got started exactly like this -- giving passengers a ride on existing mail carriages. Now they run actual buses along the same routes (which are still bright yellow like the mail trucks).


This is the way to do it - solve the problem, even if “inefficient/complex” and then as things grow, adapt.

Regular rural route busses used to be common in the US before everyone got rich enough to own a car.


And if you can't afford a car, can't drive, got your drivers licence revoked, aren't old enough to drive. fuck you.


> A highway is a one-time cost

Not really, especially in places that regularly experience freezing and snow.


Highways require significant ongoing maintenance - I wouldn’t be surprised to find that the cost of maintenance over the lifetime of the road exceeds the cost to build it in the first place. Particularly if the country in question relies heavily on road freight.


Depends on how you define “lifetime” - roads last a long time (and if it’s heavily used, it’s clearly worthwhile).


If this highway is so 'heavily used' then there is clearly enough population around that asking for a bus isn't that big of a deal. You act like I asked for high speed rail connections ever 15min to some remote village northern BC.

We are talking about 200km distance from Vancouver, the major city in Western Canada.


Highways are more important to business than passengers. That government bus isn't going to be hauling the logs, gravel, and any other resources that are the lifeblood of BCs economy.


> especially if the bus would normally run empty

In Switzerland we often have bus service to tiny mountain villages where the bus has to drive incredibly complex snake roads up a mountain. These buses are often not all that full. And somehow we have not gone bankrupt as a country in the 100 years this has been going on.

> A highway is a one-time cost

That is just totally false.

> a bus is an ongoing cost

Bus has an Initial acquisition cost and an ongoing maintenance, literally exactly like a highway.

The difference is that you have to pay a bus driver.

> It would be much easier to "stick a seat" on some government vehicle that already does the trip regularly, allowing a passenger or two to ride along with the mail truck.

Yes. And that exactly how it started in Switzerland. The Mail company operates the buses. But that doesn't change the fact that they are proper buses with reliable schedules.

Today these buses don't usually deliver the mail anymore anyway. The waste majority are just normal bus routes, just painted in a cool color.

See the Old-School bus: https://artifiche.com/artifiche-images/posters_extralarge/24...

Here you see a modern Post Bus station that is above the local railway station. There are 10+ Post platforms, going into all the surrounding vallies and then to all the different mountain villages. They are all synchronized and scheduled with train arrival times.

See: https://www.bus-bild.de/bild/Schweiz~Betriebe~Postauto/13802...

The city where this bus station is located has only 35k people, it the capital of that whole mountain region. The next large town has 10k people. Many of the villages in the valley, often with population with 1000-2000 are of course connected by rail. Its only once you have to go up that you need the buses. And this city is 100km away from Zürich, a much smaller city then Vancouver.

That is much smaller then even many of the small cities in the greater area we are talking about. There are many cities of 100k+ around, and many other small cities of 10k-50k range.

So I really can't see how connecting any of village in that area can be such a hard burden.

We are talking about a pretty populated region with lots of population. And we are not in the 1920 anymore. Just do fucking run real bus service.


Usually locations for skiing are very well connected. Trains that go to popular skiing locations of have places to store your equipment. There are also bikes available at most stations.

> It's my ideal version of mobility.

It can decently be a lot better in a lot of ways. But we have to not just complain but try to objectively criticizes so we can continue to improve.

I would like to actually do high-speed rail. Switzerland did really well improving on InterCity trains and got more people to use them. But that became almost a mantra of 'speed doesn't matter'. The actual mantra is 'not as fast as possible, but as fast as required'.

This was correct and with the Rail2035 plan, we are going further in that direction. Many InterCity trains go from every 30 min to every 15 min. Basically turning most of the country into an S-Bahn like system.

See here if you are interested: https://sbb-step2035.ch/de/personenverkehr/

But I think beyond that we should seriously consider a totally new high-speed line, right across the major population centers. That would not just make rail competitive with driving, but beat driving with a big stick. Also this would free up a huge amount of capacity from the existing lines and allow things like 15min regional and inter-regional travel. Plus it would increase cargo capacity.

Sadly its currently not in the Rail2050 plan, but there are people pushing for it.

Further, I think we can do a lot, a lot better in terms of biking. Compared to the Dutch we are utterly primitive in integrating biking in the larger transport network. In the Netherlands they have figured out that bikes are the optimal feeder system into the rail network and have taken huge advantage of that. Switzerland needs to do so much better in that.

Frankly, I think its really useful. I was able to perfectly travel around on Christmas. Getting to family in different parts of the country, no problem.


> That would not just make rail competitive with driving, but beat driving with a big stick.

Between major population centers, I believe it already beats driving by a long shot... I personally don't think it has to be faster: as long as I can work in the train, it's fine if it takes 90min instead of 75.

> Further, I think we can do a lot, a lot better in terms of biking.

Yes!


The main point is that a new main line would revolutionize local and regional transport as well. So even if you don't build a high speed one, you get a lot of benefit. But once you are building new lines, might as well make it a high-speed line.

And we also should consider longer distances. Sure if you are going from Bern to Zürich 5-10min difference isn't gone be that big of a deal (well arguably if you have millions of people doing it, it does start to matter at least a little).

But even if you look at Genf-Zürich, a new main line could cut that time by 40%-50%, from almost 3h to more like 1.5h.

But what if you want to go from Southern France to Stuttgart or Münich. From Marseille to Zürich.

We have major population density in a straight line from Genf to St.Gallen. Having a modern high speed rail connection across that population just makes sense.


> Having a modern high speed rail connection across that population just makes sense.

I guess I don't really understand the need for high speed. I can do Genf-St.Gallen without a problem. I can't do this as a daily commute, but that's fine. Maybe it's even a feature.

I don't need high speed, I just need it to be better than using the car for long distance. Though I already prefer the train for stuff like Southern France - Stuttgart.

To be frank, instead of high speed for long distance, I would rather have more night trains. And then it starts competing with planes (3/4 flights are for leisure, we need to do something about it).


And the best part is how reliable and timely the trains and buses are. As a foreigner living there I commuted by bus into Geneva from a suburb. I don't think my bus was ever more than 1 minute late - and this was in the middle of its run. I hate to compare that to my wife's commute here in Boston....


Replace "foreigners" with "Americans". Functional public transport is not that special; most countries have it. The main difference in Switzerland is the hostility of the terrain to building infrastructure.

If your parents lived on a farm in rural China, you would say the same thing.


Swiss public transport is IMHO special in three respects: a) density of the network, b) frequency (even remote areas get a bus an hour), c) punctuality.

I'm not saying no other country can match this (I haven't been everywhere), but at least Germany or Italy can't.


It is bloody pricey though. Especially for those without a Swisspass.


Cheap if you can not have a car instead.

Plus if you vacation here you can get 5 day tickets for example, and explore the whole country, it covers various ships, cable cars and so on. It can be a pretty damn good deal if you take advantage of it.

For people living here that don't need a full GA (Swisspass is a car that has lots of functions). There is also Halb-Tax to reduce your price significantly, and if you use it frequently you can get even better deal with Halb-Tax Plus.

I think its quite reasonably priced for what you get. But if you are a tourist coming in just buying 1 regular ticket it can be expensive. That said lots of local transport is often included with the hotel.


Thanks for the link, author of the website here. For this particular #swisstrains project I was using derived GTFS dataset form this one https://opentransportdata.swiss/en/dataset/timetable-54-2024... - this portal contains public transport data from all swiss transport operators (not only SBB)


One of my favorite YouTubers, not just bikes, did a video last year that highlighted this: https://www.youtube.com/watch?v=muPcHs-E4qc


Does this have real-time positions, or only scheduled positions?

Personally I prefer TRAVIC, which has nearly 100% real-time coverage for Switzerland and also includes busses and trams:

https://travic.app/?z=9&x=921422.5&y=5949724.5


It says it is "an animation based on the official timetables of the Swiss Federal Railways(SBB) network". To my understanding its only scheduled positions.


When I was there in 2001, an announcement apologized for a train being 30 seconds late. Scheduled and actual were shockingly close.


To counterpoint: in the height of summer tourist season 2023, I spent a week in Switzerland taking trains and booked several supersaver tickets in advance with 15-30 minute connections. I was told stories of the efficiency of Swiss trains, and that I could book 5-10 min connections with no problems, but chose to be safe and do 15-30 mins. Well, I missed 3 of these connections due to delays on the incoming train. I had to queue at the ticket booth to get it endorsed for the next train.


There's no need for anecdotes as the data is published. Only ~1% of connections are missed: https://reporting.sbb.ch/punctuality?=&years=1,4,5,6,7&scrol...

~93% of trains are punctual with a VERY strict definition for punctual: within 3 minutes of the scheduled time.

If you experienced worse, you were in an unlucky minority of people.


What your link shows is that train punctuality in 2022 was 92.5 %. That is shocking bad. Back in 2018 at least 10 countries were doing better than Switzerland.

https://www.statista.com/statistics/1255048/punctuality-regi...


Here is a recent perspective.

[1] "Why Swiss trains are less punctual — and what is being done about it" - https://www.thelocal.ch/20220110/why-swiss-trains-are-less-p...

Once more a variation on how to lie with statistics... It does not matter if the overall statistics show a somewhat high value, mostly driven by predicable and frequent travels between Cantons in the mountains, where there is maybe just one track. What matters is the experience of the majority of commuters on urban centers. From [1] in 2022, the year of most recent statistics.

"The punctuality values in the last three months on some major intercity routes are below the threshold:

Zurich HB - Bern: 73.5 percent of on-time arrivals and departures

Lausanne - Geneva: 71.5 percent

Basel - Zurich: 67.5 percent

Zug - Zurich HB: 76.1 percent

Olten - Lucerne: 66.7 percent "


But you are doing the same thing. Switzerland has a high standard of 3min is late. What actually important if you make your connections. In Switerland you make your connection like 98ish% of the time.

This article picks out some of the worst lines over a very short time period. You can do that in most networks. Some German ICE lines have 23% on time.

I ride some of those city to city pairs and those numbers don't line up with my experiance over the last couple years.


I'm not sure how Statista got their info, but most other countries define "late" as being more than 5 minutes behind schedule. In Switzeland that limit is lower with only 3 minutes not counting as late.


Can’t tell from that link but historically the Swiss punctuality standard is three minutes where other countries use five or more, Japan being the notable exception.


If your train is not too late, the connection will wait for you. If it can't wait, they will tell you about the alternative.

My experience in Germany is that the connection does not wait, and you just end up having to find your way yourself. It's a bit weird when not used to it, and it seems to mean that you can basically take whatever train you want that you believe goes towards your goal.


> you can basically take whatever train you want that you believe goes towards your goal.

That's a big difference between Germany and Switzerland. Full fare tickets let you take any route, but reasonably priced tickets are specific to a schedule of trains. If there is a delay causing a misconnect, you have to queue at the ticket window to get it endorsed for a later specific train. And my ticket inspectors on the train seriously inspected the endorsement each time.


The Swiss don't use those super saver tickets, or at least I don't think so: they either have GA or Halbtax to start with, and apps like Fairtiq mean that they get the best price for the route(s) they take automatically, as calculated by the end of each day (this makes it possible to get switched to a daily ticket on the fly if you travel so much that it would cost you less in the end).

I know it's unfair towards tourists, but Switzerland is a very expensive country - if you need a "super-saver" ticket you'd probably be better off visiting any of the neighbouring countries anyway.


If the incoming train was first going through Italy or Germany the punctuality statistics are much much worse. I regularly book 5-8 minute overlaps and I don't remember the last time I missed a connection, but this is Zürich into the mountains mostly.


Summer 2023 was a particularly bad time for SBB. Summer in general is the worst time of the year for traffic (both car and public transport) anyway.


Maybe in 2001...Nowadays 3min delays are still considered as on time as per SBB : "A train is considered on time if it reaches its destination with less than three minutes’ delay."


When working with the data they generally only provide live data for trips that are off schedule (a deff feed) as the scheduled data might as well be live.


Nice story but that has never happened. Delays are announced when >=3min are expected.


Timetable interpolation it seems: https://github.com/vasile/transit-map

Thanks for the Travic link.


Thanks for featuring, author here. This is the first version of the #swisstrains webmap which I've made 17yrs ago, it still runs for historical reasons, it used to fetch also live delays but the position of the trains were still interpolated, using the average speed between the two timetable stops.

The other clones are more or less using same technique, swiss transport agencies are not (yet) offering live position of the trains / vehicles, only the actual delays measured at stations.


>> Does this have real-time positions, or only scheduled positions?

Such an important question! One of my pet peeves with the NYC Metro Timings app is that it sneakily presents scheduled arrivals as real-time. The best example of this is which it shows trainings happily running/arriving on lines that are actually shut down for construction!


I don't know about NYC, but in my territory the public transit authority shares live and real-time data with Google. It's exposed in Maps with a very nice interface, such that I don't even need to install the buggy, bespoke app provided by the transit service.

They also have an SMS query service which seemed to always be inaccurate or lying. I stopped using it, it was so unreliable. But Google Maps can tell me exactly where the next bus/train is, how much delayed, how crowded it is, whether security is on board or not, because Google polls actual passengers about these parameters.


I was just on a train from Paris to Genève and was looking for a map just like this!


There's one for The Netherlands as well -> https://en.treinposities.nl/. Relies on an open API so there's bound to be others. This one is good because it has some live webcam links on the map as well. At least one of the live cams use YouTube as a streaming platform and have active rail nerd communities chatting and answering questions, like https://www.youtube.com/watch?v=1UfHjV-oUmE


Does seem to have some latency, as I just saw two trains crossing on

https://bouw.live/puls-amsterdam/

with no corresponding trains on the map.


If the timestamp in the top right corner is correct, then the livestream lags ~1/2 hour behind.


You are correct, its 30 min behind. A live camera that is not live. Makes total sense :-)


Thanks for featuring, author of the website here. This is the same version as the one I've first made back in 2006, the main dataset is a derived GTFS dataset from swiss raw timetables (HRDF) [1].

The position of the trains are interpolated, based on the departure / arrival times of stop times and is using the average speed. I've used to have also an hourly updater for the delays using the GTFS-RT dataset [2] but is gone due to lack of time. ATM there is no official dataset to give the live position of the vehicles, all the other websites are just interpolating positions based on the time delays.

The website still runs as hobby project, is not meant to be taken as source of truth for actual position of the trains, though I get many requests from trainspotters and photographers asking me for such feature :)

And for some routes you can sit and enjoy watching the route displaying actual train units [3] more a simcity-like feature :)

[1] https://opentransportdata.swiss/en/dataset/timetable-54-2024...

[2] https://opentransportdata.swiss/en/cookbook/gtfs-rt/

[3] https://maps.vasile.ch/transit-sbb/?hms=10:00:00&vehicle_nam...


Something seems inaccurate here, perhaps data corruption? There’s no way so many trains could be in such a small space.

Signed,

An American


http://tracker.geops.ch/ shows way more connections such as busses, trains or international traffic.



https://rasp.yandex.ru/map/trains/#center=37.63999999999997%... for the coverage further East. It may be partially relying on timetables and not live data, though.


Here's most of Europe, but mostly based on interpolated schedule data:

https://travic.app/?z=6&x=1652866.9&y=6336146.8&l=osm_standa...

It's also great to see the utter mess that DB organization is. I found their live tracking on [1], but it can only be ordered as a product to embed somewhere, they don't show it on their site. Then there is the random https://www.bahnhof.de/, which seems to collect information about train stations. But if you want to schedule your trip or buy a ticket, you'd better get the DB Navigator app, which is not available as a web version. FML.

[1] https://www.dbinfrago.com/web


'Live' implies realtime data, this is based on schedules.


"they are the same picture"


I was surprised how good the Amtrak one is: https://www.amtrak.com/track-your-train.html


That is cool but the number of trains is so depressing.


Just watched a train leave and another arrive at Untervaz Bahnhof: https://www.rhb.ch/en/interactive/rhb-livestream. The live map showed it leaving before it did on the cam, and has a timestamp that is closer to my computer than the live map. They are maybe 30-45 seconds apart.

That stream page randomly shows different stations and ads, so you have to time it right!


Live map of Tokyo trains: https://minitokyo3d.com/


Dutch trains live: https://treinposities.nl/



Looking at this from a swiss train. It seems to be 10-15 minutes out of date compared to GPS.


Switzerland had a similar open source solution a few years ago. Unfortunately, the train operator forced it to shutdown as it was scraping the data from the timetables. Not sure how the new solution works but I hope it sticks around.


I used to work at https://www.local.ch/en and know Vasile, the guy that built this map.

The situation with trains (and data) in Switzerland is complicated as each Kanton has it's own rail network. In 2016 the SBB _finally_ started making it's train timetable officially available (some info on that here - https://www.itmagazine.ch/artikel/64746/Open-Data-Plattform_... ) which is I believe what this map uses, after shutting down people scraping the data.

That said, what has always irked me is they gave the data to Google as far back as 2007, while refusing to make anything available for sites like local.ch and map.search.ch (who's map was partly basis for the original Google maps). Refusing may be a leading term but certainly there was no help given to local Swiss companies, while Google already had the train times in maps.


This doesn’t match my experience. Google requires feeds to be in a specific format [1] but the feed is push from the agency. When I was intimate with the details, agencies were strongly encouraged to publish these feeds at a public url. There were all kinds of things about the format itself that might not have worked for the good folks at local.ch but access to the data is not likely to have been a problem.

[1] https://developers.google.com/transit/gtfs


As usual, I am still forever confused by whatever the hell Lörrach is.

German? Technically yes. Swiss? Technically no.

Does it constantly play different cards depending on infrastructure projects within the county? Oh you bet.


It’s definitely German.

But we also have a German train station in Switzerland, so there’s that ;)

https://en.m.wikipedia.org/wiki/Basel_Badischer_Bahnhof


That's neat it shows some gondola/cable cars too.


Switch to satellite view, zoom into some red train dot and you can actually see the train there, running on the tracks. Pretty neat trick!


I love that you can see the cars when zoomed, wasn't expecting that


They even show the marker when it passes by within Google street view !!


I couldn't see the train cars for most of them just a few of the red 'IC' ones. I wonder what the criteria is to show cars.


There are a number of tunnels, though the dim red track lines didn't always show up when i was zoomed


The animations are nice.




Guidelines | FAQ | Lists | API | Security | Legal | Apply to YC | Contact

Search: