Skip to content

📄🚀 – Modify handling of vehicle attributes and vehicles consists #269

Description

@jlstpaul

Describe the feature you want and how it meets your needs or solves a problem
This issue proposes to change the approach to how vehicle attributes and vehicle consists are represented in TIDES.

The current spec has the following issues

  • Vehicle attribute data is denormalized, so that fields such as capacity information, are repeated for all of the vehicles of the same type (e.g., a series of buses purchased together)
  • Vehicle attribute information is defined in both the vehicles table and the train_cars table. This means that both tables need to be modified when there is field change, and two different tables must be populated from agency fleet data
  • There is no way to indicate the direction that a consist is traveling in the operational data tables.

Describe the solution you'd like

The proposed changes are as follows

  • Create a new vehicle_groups table that details the shared attributes of all vehicles in agency-defined groups. A vehicle_group is a subset in which all vehicles share the same attribute values. A vehicle_group may refer to either individuals vehicles, e.g., specific type of bus, or to a planned consist type, e.g.,“Two car train of Type II vehicles”. See the list of proposed vehicle_group attributes below.

  • Modify the the vehicles table

    • Remove attributes related to capacity, amenities, etc. (These are shifted to vehicle_groups table
    • Add a vehicle_label field which is the public identifier of the vehicle if there is one.
    • Add a vehicle_group_id reference to a record in the vehicle_groups table
    • Add is_train_consist boolean field. When true, the vehicle record represents a consist and there should be one or more records for this vehicle_id in the vehicle_train_cars table. Note: This field is not strictly necessary. Open to discussion on whether it is needed.
  • Remove the train_cars table. Individual train cars should be represented in the vehicles table.

  • Modify the descriptions of fields in vehicle_train_cars table to clarify their use

    • vehicle_id is the identifier for the consist. It references a record in the vehicles table
    • train_car_id is the identifier of an individual train car within the consist. It also references a record in the vehicles table
  • Add a train_car_orientation to the vehicle_train_cars table to indicate which way the car is facing the consist.

  • Modify the following tables to add a vehicle_direction field associated with the existing vehicle_id field. If vehicle_direction is forward, then the lowest numbered train car is in the front.
    Vehicle_locations
    Passenger_events
    Fare_transactions
    Stops_visited
    Trips_performed

Describe alternatives you've considered

This issue grew out of several related proposals and discussions

The initial list of potential fields for the proposed vehicle_groups table is taken from the GTFS vehicles.txt proposal:

vehicle_group_id
vehicle_group_description
vehicle_class (text field)
vehicle_label
vehicle_label_high
agency_id
facility_name
vehicle_type
manufacturer
model_name
year_manufactured
fuel_type
length
articulated_sections
levels
cab
image_url
image_photographer
image_details
vehicle_notes
capacity_seated
capacity_full
capacity_wheelchairs
capacity_strollers
capacity_bikes
bike_notes
capacity_cars
luggage
luggage_notes
restrooms
accessible_restrooms
air_conditioning
ac_plugs
usba_plugs
usbc_plugs
wifi
wifi_notes
doors
boarding_type
boarding_steps
accessible_boarding
accessibility_note
stop_announcements
route_announcements
stop_displays
livery_color
livery
nickname
decoration

Metadata

Metadata

Assignees

No one assigned

    Labels

    📄 specPertains to the specification itself🚀 featureAdds a new feature - to spec or code

    Type

    No type

    Fields

    No fields configured for issues without a type.

    Projects

    No projects

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions