Skip to content

Latest commit

 

History

History
31 lines (22 loc) · 1.26 KB

README.md

File metadata and controls

31 lines (22 loc) · 1.26 KB

There are two parsers implemented in Avicena

  • CSV
  • LogistiCare

All parser modules must implement to the following function header:

parse_trips_to_df(path_to_trips_file: str, merge_details: Dict[str:MergeAddress], revenue_table: Dict[str:List[RevenueRate]], output_directory: str) -> Pandas.DataFrame

The resulting Pandas DataFrame must have the following columns:

{'trip_id', 'trip_pickup_address', 'trip_pickup_time', 'trip_pickup_lat', 'trip_pickup_lon', 'trip_dropoff_address', 'trip_dropoff_time', 'trip_dropoff_lat', 'trip_dropoff_lon', 'trip_los', 'trip_miles', 'merge_flag', 'trip_revenue'}

Every patient must have the same trip_id except for the final character. The final character of the string must indicate the relative order in which the trips must be completed. The final character of the trip_id must be either 'A' , 'B' , or 'C'

CSV

The CSV Parser takes a CSV of input trips with the following header: date,trip_id,customer_name,trip_pickup_time,trip_pickup_name,trip_pickup_address,trip_dropoff_time,trip_dropoff_name,trip_dropoff_address,trip_los,trip_miles to produce the trip assignments.

LogistiCare

This is a parser used to parse the PDFs from LogistiCare with its proprietary formatting.