export hotstats to html

Everything about mods can be found here.

Moderator: Morax

export hotstats to html

Postby fffmmm » 15 Jan 2013, 18:51

Here's an example of what the result looks like.


download


Instructions on how to use it are in the archive along with the source.
To extract the stats, a modified version of Hotstats is used that dumps the stats to the logfile.
User avatar
fffmmm
Contributor
 
Posts: 8
Joined: 16 Jul 2012, 18:54
Has liked: 0 time
Been liked: 0 time
FAF User Name: fffmmm

Re: export hotstats to html

Postby Softly » 16 Jan 2013, 14:57

TA is going to propose to you btw
Softly
Supreme Commander
 
Posts: 1009
Joined: 26 Feb 2012, 15:23
Location: United Kingdom
Has liked: 150 times
Been liked: 251 times
FAF User Name: Softles

Re: export hotstats to html

Postby SeraphimLeftNut » 17 Jan 2013, 04:44

This works. I had in mind just a text file with the data. I guess the log file is exactly that, but I was hoping it was a little more easily organized. Your program does a good job understanding that log file and replotting the data in html. I would have liked just some column text files of time vs energy etc. instead of those graphics. I think I would be able to get to that point from the logfile, but it might take a little work for a noob like me.

This is really awesome. The plots show a bit more comparison than the plots at the end of hotstats.

You chose to plot the data in incriments of 10 seconds. Was this choice done during the reading of the log file and creation of the html? Or was this choice made during the creation of the logfile?

My favorite thing to do would be to get the highest time resolution tme vs resources data sets and play around with them, plotting them in different ways. Having the plots already made for you, kind of takes the fun out of it.(even though they are nice)

The html files have the data in nice columns, but the 10 second step hides a lot of things. Would be nice to get at least a 0.5 second increment version.
no ui lag: https://www.youtube.com/watch?v=3MdcVdL2kIY
I think this is going to be fun
User avatar
SeraphimLeftNut
Contributor
 
Posts: 975
Joined: 10 Jul 2012, 19:46
Has liked: 3 times
Been liked: 219 times
FAF User Name: TA4Life

Re: export hotstats to html

Postby fffmmm » 17 Jan 2013, 13:24

SeraphimLeftNut wrote:This works. I had in mind just a text file with the data. I guess the log file is exactly that, but I was hoping it was a little more easily organized. Your program does a good job understanding that log file and replotting the data in html. I would have liked just some column text files of time vs energy etc. instead of those graphics. I think I would be able to get to that point from the logfile, but it might take a little work for a noob like me.

This is really awesome. The plots show a bit more comparison than the plots at the end of hotstats.

You chose to plot the data in incriments of 10 seconds. Was this choice done during the reading of the log file and creation of the html? Or was this choice made during the creation of the logfile?

My favorite thing to do would be to get the highest time resolution tme vs resources data sets and play around with them, plotting them in different ways. Having the plots already made for you, kind of takes the fun out of it.(even though they are nice)

The html files have the data in nice columns, but the 10 second step hides a lot of things. Would be nice to get at least a 0.5 second increment version.

The 10 second steps are 'chosen' by hotstats (it takes a snapshot every 10 seconds/100sim cycles). This of course can be modified:
Code: Select all
in hotstats.zip\hook\lua\ui\game\scoreaccum.lua:
local scoreInterval = 10
this line means that every 10 seconds a snapshot will be taken.
in FAF-STATS\src\faf\stats\html\Generate.java
int SecondsPerTick = 10;
this is the constant that represents the one in the lua file



Keep in mind tho, that this already pushes the browser to it's limit with 10 second snapshots. With 1 second snapshots you have 10 times more data and thus additionaly stress the browser. It also means that the ram required by the game to store the score snapshots grows by factor 10. Since FA already uses quite some ram, it might impact the performance of the game for people with 4GB of ram or less.
User avatar
fffmmm
Contributor
 
Posts: 8
Joined: 16 Jul 2012, 18:54
Has liked: 0 time
Been liked: 0 time
FAF User Name: fffmmm

Re: export hotstats to html

Postby SeraphimLeftNut » 17 Jan 2013, 17:45

Now I can't wait to get home to play with this. Thank you so much for making this work. Do you know if the time spacing is limited by the 0.5 second interval that is used for different pc's to talk to eachother during multiplayer?
I would like to make this as small as possible, RAM is not a problem. I guess there is a simple way to find out...

Thank you once again.
no ui lag: https://www.youtube.com/watch?v=3MdcVdL2kIY
I think this is going to be fun
User avatar
SeraphimLeftNut
Contributor
 
Posts: 975
Joined: 10 Jul 2012, 19:46
Has liked: 3 times
Been liked: 219 times
FAF User Name: TA4Life

Re: export hotstats to html

Postby peanot » 17 Jan 2013, 19:59

I sent TA4Life a message on youtube offering to do something like this just a few days ago (since he pointed out the usefulness in several of his videos), but I guess I was too late.

Nice work on that!


However, as was mentioned, the utility of a website is somewhat limited, so I would still like to offer my services as a programmer to the community and write a tool, that loads one of these exported log files and then displays the data in all kinds of ways.

I would like to ask if people are actually interested in that.
If so, I also would like to know what kinds of representation of the data would be the most useful(anything I can imagine right now should be possible).

Oh and also, let me know if you mind that I am using your thread for this fffmmm, if so I will happily take this some place else. ;)
Also, if you yourself want to do something like that, we probably should communicate and not both do the same thing.
Though I guess competition can be a good thing? :D
peanot
 
Posts: 5
Joined: 17 Sep 2012, 18:38
Has liked: 0 time
Been liked: 0 time
FAF User Name: peanot

Re: export hotstats to html

Postby ZaphodX » 17 Jan 2013, 20:28

Speak to TA4life (SeraphimLeftNut), he will know all the features you should implement. Will probably also start using this in my casts - thanks to you both.
User avatar
ZaphodX
Contributor
 
Posts: 560
Joined: 02 Jan 2013, 01:55
Location: UK, GMT+0
Has liked: 0 time
Been liked: 0 time
FAF User Name: TAG_ZaphodX

Re: export hotstats to html

Postby Softly » 18 Jan 2013, 00:06

Programming? Sounds like you need to speak to Zep if you want a proper job :D
Softly
Supreme Commander
 
Posts: 1009
Joined: 26 Feb 2012, 15:23
Location: United Kingdom
Has liked: 150 times
Been liked: 251 times
FAF User Name: Softles

Re: export hotstats to html

Postby fffmmm » 18 Jan 2013, 00:28

peanot wrote:Oh and also, let me know if you mind that I am using your thread for this fffmmm, if so I will happily take this some place else. ;)
Also, if you yourself want to do something like that, we probably should communicate and not both do the same thing.
Though I guess competition can be a good thing? :D

You can of course use this thread in any way you want: I don't claim a monopoly on it :)
If you plan to do do your tool from scratch, use this modified version of hotstats: https://www.dropbox.com/s/7cmyot5l27i4bdu/hotstats.zip
It dumps the objects as JSON String/Object which should massively reduce the time neccessary to parse and arrange the data (usualy all it takes is a JSON.parse(string) - depends on the language you're gonna use) and it takes a snapshot every second instead of every 10 seconds.

PS: to get the correct mass/energy rate you will have to multiply the stored rates by 10
PS2: this one can't be parsed by the tool I originally posed as I dump it in some custom format (didn't quite think that one trough b4 I started it)

~fffmmm
User avatar
fffmmm
Contributor
 
Posts: 8
Joined: 16 Jul 2012, 18:54
Has liked: 0 time
Been liked: 0 time
FAF User Name: fffmmm

Re: export hotstats to html

Postby peanot » 18 Jan 2013, 00:44

Thanks for the pointers and for the hotstats modification!
I am very glad I do not have to figure out lua. That will probably save me many hours.

@DilliDalli:
I am afraid I do not have enough time for a(nother) "proper job". :D
Studying is KIND OF a fulltime job, and I have enough personal projects. ;)
(Though, if LOTS of money was involved... hehehe)

But yeah, I think I will see tomorrow or maybe over the weekend what I can figure out. If it is super easy to decode that JSON output into internal objects(and it should be), then I could be drawing the first graphs within a few hours.

Again, the question really is what kind of graphs or other features would be useful.
But yeah, not trying to pressure anyone here, I know I just asked a few hours ago. :D
peanot
 
Posts: 5
Joined: 17 Sep 2012, 18:38
Has liked: 0 time
Been liked: 0 time
FAF User Name: peanot

Next

Return to Mods & Tools

Who is online

Users browsing this forum: No registered users and 1 guest