Extracting data from server logs

classic Classic list List threaded Threaded
2 messages Options
Reply | Threaded
Open this post in threaded view
|

Extracting data from server logs

grampajohn
Administrator
Rodrigue asks:
Please can you tell me how to compare the energy imbalance of the broker agents using the available data?
All the data you need for this is in the state log generated by the server. Specifically, imbalance information is in the BalancingTransaction instances. Here are a few from game 9 in the September 2012 series:

189425:org.powertac.common.BalancingTransaction::3452::new::602::2009-01-03T03:00:00.000Z::-4244.335000000001::-289.60107137254624
189425:org.powertac.common.BalancingTransaction::3453::new::1::2009-01-03T03:00:00.000Z::26945.336430199997::1838.5443888570571
189425:org.powertac.common.BalancingTransaction::3454::new::601::2009-01-03T03:00:00.000Z::-271.35400000000004::-18.51512878253623
189425:org.powertac.common.BalancingTransaction::3455::new::605::2009-01-03T03:00:00.000Z::-48871.155999999995::-3334.595204387693
189425:org.powertac.common.BalancingTransaction::3456::new::603::2009-01-03T03:00:00.000Z::1406.25::95.95178199120548
189425:org.powertac.common.BalancingTransaction::3457::new::604::2009-01-03T03:00:00.000Z::-53.959::-3.681750900951791

The format of these entries is described in the participant's wiki; you are invited to contribute to the discussion there as you work with the data.

In this case, the BalancingTransaction classname is followed by fields objectId::new::brokerId::time::kwh::charge.

We have a tool that parses these logs and gives you the ability to extract the data you are interested in. Just pull down the powertac-tools repo and import the logtool into STS. One of the examples in that package extracts imbalance data and formats it as a simple matrix. Note that you need to have the 'logtool' branch of the common repo imported into STS for this to work. If you already have STS set up with the common module, just switch to the logtool branch before you try to build/run the logtool. It has a README file that should help you get started.

Cheers -

John
Reply | Threaded
Open this post in threaded view
|

Re: Extracting data from server logs

grampajohn
Administrator
Several folks have asked for more detail on the format of the state logs generated by the server and by the broker-core module. I've added a page with some additional detail and several examples. Please let me know if you need more.

Cheers -

John