cis3296f24 / Section4-ProjectPresentation

cis3296f24-classroom-project-presentation-ProjectsFeedbackBoard-template created by GitHub Classroom
0 stars 0 forks source link

Train Tracker: An intuitive tracker for national Amtrak rail services #16

Open ahgoldmeer opened 2 days ago

ahgoldmeer commented 2 days ago

Project Abstract

This project will leverage the Amtrak API to create an easy-to-use and read tracker for all Amtrak trains that are currently running. This will be done in the form of a web application that can be used on any internet-capable device. It will allow the lookup of any train by service or train number and will be able to show its current estimated arrival time, arrival location, and other essential information for tracking. It will also include a mapping feature separate from the search features.

Conceptual Design

This project will mainly be sourcing its data from a freely available modified version of the Amtrak API. Accessing this API can be done through a number of, and was done with Python for this proof of concept. The libraries ’request’ and ’flask’ were used, to make live API requests, and to host the application on a live flask server. HTML/CSS and Javascript were used to make the initial front end and would be required for expanding the functionality of this product. The front end could also be developed using a JS framework such as React, for a more streamlined development. Additionally, this product should include a live updating map (additional details on that exist further into this proposal), which could be done with the leaflet.js library, which is a JavaScript library for interactive maps.

Proof of Concept

https://github.com/ahgoldmeer/TrainSearch

Background

Amtrak runs a large variety of trains at any one time and needs a consistent way to allow train riders and their families to accurately track them. To that end, they do have a train tracker by Amtrak, which has a functioning map that is updated live, and a search function. However, this implementation can be hard to use, and harder to navigate. The entire page is encompassed by the map, making finding trains a good amount of guesswork. There is a search function, but it brings you back to the map, and getting all the details that Amtrak has on the train, including more detailed information about train timing is simply not made available

This project will be using a modified version of the Amtrak API. Amtrak has made their native API rather hard to navigate and encoded the data in ways that are hard to get around. To that end, this application will be using a 3rd party version, which created a wrapper around the original API, making it far easier to call and query. This API has information about every train that is currently running, including the train name, number, ID, every stop it will be making, the initial arrival times for all stops, estimated actual times for all stops, and notes about whether a train has arrived at that stop already or not. This application, unlike the Amtrak web page, will have a dedicated search function. Users will be able to search based on train name or ID, and all information regarding the relevant trains will be printed out for users.

Additionally, though not implemented in the P.O.C., I would like to implement a map function as well. Amtrak does not disclose how often the API information is updated, but it does include latitude/longitude information about every listed train. Therefore, on a timer, all trains could be queried, and the map updated. However, by not linking the entire search function to the map, it will make usage far easier for any who are choosing to use this application.

Resources

There are no extra resources that should be needed for this project. All information is freely available, from the modified Amtrak API (https://github.com/piemadd/amtrak?tab=readme-ov-file). Technical skills for this project will include Python, Flask, Javascript, HTML/CSS, and Leaflet.js. Some of the knowledge required to use these technical skills within the scope of this project may not be initially known to all or any members of the team, and would need to be researched in order to be used effectively.

https://docs.google.com/presentation/d/1g_uQSBBAUnm4L1wG5UI4OChWv8u6_T5drij80F_DOkc/edit?usp=sharing