Skip to content

Pre day Output Analysis

smart-fm edited this page Feb 7, 2019 · 3 revisions

Once the pre-day is run with "activity schedule" run-mode it will generate 'activity_schedule' file. Before processing it further (e.g. inserting into the Database and running within-day) it is always advisable to run the validation result to make sure the output is generated is correct.

There are two python scripts under /dev/tools/preday-output-analysis. These scripts require the matplotlib library to be installed for plotting. The instructions to install the library can be found here.

  1. getPredayStats.py: Run the following command

    python2.7 getStats.py activity_schedule_fileName > outputFile.csv
    (need to specify the location of the activity_schedule_fileName)

  2. das_analysis.py:

    python2.7 das_analysis.py > error.txt
    (need to specify the path of the activity_schedule file under inputFolder and dasFile variable in the 'das_analysis.py' file and outFolder variable in the 'plotsDas.py' file)

getPredayStats.py

This script will generate the mode share statistics in the outputFile.csv and the following graph images(for example)

Education_time_of_Day.png Education_time_of_Day.png

Home_time_of_Day.png
Home_time_of_Day.png Other_time_of_Day.png
Other_time_of_Day.png Shop_time_of_Day.png
Shop_time_of_Day.png Work_time_of_Day.png
Work_time_of_Day.png

das_analysis.py

This script will generate the following graph images in the output folder specified in the script

TodTrips_depTime_activity.pngTodTrips_depTime_activity.png

TodTrips_depTime_total.pngTodTrips_depTime_total.png

TourModeShares.pngTourModeShares.png

TripModeShares.png TripModeShares.png

TripStopShares.pngTripStopShares.png

TodTrips_depTime_mode.png TodTrips_depTime_mode.png

TourActivityShares.png TourActivityShares.png

Tournumdist.png Tournumdist.png

Tripnumdist.png Tripnumdist.png

Clone this wiki locally