Skip to content

Inference Engine Debugging

Michael Frumin edited this page Jul 17, 2013 · 7 revisions

Setup

The local-ie-testing profile exists on the onebusaway-nyc-vehicle-tracking-webapp for debugging purposes, it allows a local bundle to be loaded and run through a debugger. Note that bundles may require large amounts of RAM to load properly, which may in-turn require a 64-bit O/S to address.

The best examples of debugging exist in the integration tests, and the bundles and traces provided by the integration tests. Complete information on how to create a trace for debugging and testing the Inference Engine can be found on the [Inference Engine Traces](Inference Engine Traces) page.

Configuring Inference Engine

  1. Get a fresh copy of onebusaway-nyc
    user@ubuntu:~src$ git clone git@github:camsys/onebusaway-nyc.git
  2. From Package Explorer, right-click, choose Import -> Maven -> Existing project and choose ~/src/onebusaway-nyc
  3. After the import and initial build complete, right-click on onebusaway-nyc-integration-tests, choose Run As, Run Configuration, double click Maven Build, set base directory to be ~/src/onebusaway-nyc/onebusaway-nyc-integration-tests, and Goals: "pre-integration-test", and select run
  4. The console should indicate bundles are building. This will take some time
  5. Copy the built bundles to the location the vehicle-tracking-webapp expects them:
    sudo mkdir -r /var/lib/obanyc/oba-bundle && sudo chown dev:dev /var/lib/obanyc/oba-bundle && cp -r ~/src/onebusaway-nyc/onebusaway-nyc-integration-tests/target/transit-data-bundle/* /var/lib/obanyc/oba-bundle/
  6. Right-click on onebusaway-nyc-vehicle-tracking-webapp, select Maven, and add the profile "local-ie-testing", click apply
  7. Right-click on onebusaway-nyc-vehicle-tracking-webapp, select Run-as, Run On Server (assuming you have tomcat installed, and configured with the proper memory args)

Loading a Trace

  1. A browser should popup. If not, browse to http://localhost:8080/onebusway-nyc-vehicle-tracking-webapp
  2. Click Bundle Status
  3. Select 2012September_Bronx_r10_b03 from the bundle drop down list and click "Change Bundle..."
  4. Browse back to http://localhost:8080/onebusway-nyc-vehicle-tracking-webapp
  5. Select Vehicle Simulator
  6. Select Browse and choose ~/src/onebusaway-nyc/onebusaway-nyc-integration-tests/src/integration-test/resources/traces/324-deadhead-labeled.csv
  7. Click submit
  8. Click map to view the trace. Click refresh if trace is not complete

Map Legend

Symbol Meaning
Green peg In Progress
Red peg Deadhead
Blue peg Layover
Grey with orange dot In service DSC but inference not in progress
## Using Vehicle Simulator 1. Click Back... 1. Click records 1. Select a record, then select a logP link. This contains the internal state for the highest probabililty particle. Most tweaks to the inference engine go off this page versus the values of the competing particles.
Clone this wiki locally