100 years solo AIs openttd.exe CPU time benchmark

Discuss the new AI features ("NoAI") introduced into OpenTTD 0.7, allowing you to implement custom AIs, and the new Game Scripts available in OpenTTD 1.2 and higher.

Moderator: OpenTTD Developers

Samu
Traffic Manager
Traffic Manager
Posts: 236
Joined: 17 Apr 2007 14:28

Re: 100 years solo AIs openttd.exe CPU time benchmark

Post by Samu »

I will do the others whenever I can.
Samu
Traffic Manager
Traffic Manager
Posts: 236
Joined: 17 Apr 2007 14:28

Re: 100 years solo AIs openttd.exe CPU time benchmark

Post by Samu »

Should I test these:

- rocketAI 1
- StreetTraffic 1
- TownCars 4

They seem to be for testing, hmm... your thoughts?

I did 2 others:

MogulAI 5877 - 04-02-1971
RoadRunner 3 - 13-03-1970
Samu
Traffic Manager
Traffic Manager
Posts: 236
Joined: 17 Apr 2007 14:28

Re: 100 years solo AIs openttd.exe CPU time benchmark

Post by Samu »

Hi, I just finished for most. Only those 3 I mentioned before weren't tested. I also did RoadRunner version 3, the one that takes 330 kb in size and the recent version of Mogul on the Banana server.

Code: Select all

AI Name             Version Start end d/m/y   t/r/s/a vehicles   Company Value

WrightAI                  3  1950  30-06-2035   0t/  0r/  0s/ 27a  £37,462,288
Chopper                   7  1975  15-11-2022   0t/  0r/  0s/ 46a  £13,396,129
Rondje                  313  1950  08-11-1997   0t/  0r/  0s/  0a  £         1
Trans                100307  1951  05-04-1990   0t/110r/  0s/ 47a  £48,582,902
Denver & Rio Grande       1  1951  25-02-1990  34t/  0r/  0s/  0a  £ 2,519,597
trAIns                    2  1951  09-01-1985  82t/  0r/  0s/  0a  £64,675,068
OtviAI                  312  1951  30-06-1979   0t/223r/  0s/  0a  £ 5,599,564
SimpleAI                  4  1950  21-09-1975  63t/360r/  0s/  0a  £23,341,795
PathZilla                 6  1951  09-08-1975   0t/398r/  0s/  0a  £ 5,210,364
PAXLink                  14  1957  24-02-1975   0t/ 15r/  0s/  2a  £         1
Convoy                   11  1950  19-11-1973   0t/500r/  0s/  0a  £12,018,953
AdmiralAI                22  1951  06-11-1973  72t/345r/  0s/ 23a  £31,798,352
MogulAI                5877  1950  04-02-1971   0t/500r/  0s/  0a  £ 2,041,324
NoCAB                   495  1951  16-03-1970  95t/480r/  0s/ 26a  £21,511,823
RoadRunner                3  1950  13-03-1970   0t/500r/  0s/  0a  £ 9,779,201
CluelessPlus             21  1951  30-11-1968   0t/500r/  0s/  0a  £10,859,010
ChooChoo                361  1951  18-06-1966  12t/  7r/  0s/  0a  £ 1,726,378
AIAI                     15  1951  29-04-1961   0t/500r/  0s/ 64a  £ 5,460,366

I arranged this table by how further ingame the AIs went to, so it's ranked from the least cpu intensive to the most cpu intensive. AIAI is the most cpu intensive, while WrightAI is the least cpu intensive. Hope the table shows up fine over here, I edited it with notepad.

I was surprised by some AIs, mostly Rondje. I was expecting lots of cpu usage, to be one of the slowest, but it didn't build anything! Still, with 0 vehicles, it didn't manage to be ranked first. Was a bit surprised by how slow ChooChoo is. I thought it was one of the fastest train builders. Well, it might be if counting real-time, but cpu-time usage, it's the slowest for trains. I wasn't all that surprised with NoCAB being slow, but AIAI? I expected it to be lighter, it's quite huge that difference to reach next AI, ChooChoo. But AIAI is quite a beast, 500 road vehicles PLUS 64 aircrafts in 10 years!~

EDIT: This table has corrected info, I confirmed, ignore the previous data. I'm deleting those posts. Nevermind, I can't delete, I don't understand this forum.
Kogut
Tycoon
Tycoon
Posts: 2493
Joined: 26 Aug 2009 06:33
Location: Poland

Re: 100 years solo AIs openttd.exe CPU time benchmark

Post by Kogut »

Yes 500 RV are able to kill the game (but think about 500 ships :lol: ).
The next version should be more effective (trains) but it is not coming in short time.
Correct me If I am wrong - PM me if my English is bad
AIAI - AI for OpenTTD
User avatar
Zuu
OpenTTD Developer
OpenTTD Developer
Posts: 4553
Joined: 09 Jun 2003 18:21
Location: /home/sweden

Re: 100 years solo AIs openttd.exe CPU time benchmark

Post by Zuu »

Interesting test, and a nice summary that you have made.

Did you do all the work manually or did you develop something to run the tests? I'm interested in how you did to pause OpenTTD after a given CPU usage. I guess you could write a wrapper-script around a dedicated server that run the tests as long as you have a way of determining the total cpu usage of the OpenTTD process.
My OpenTTD contributions (AIs, Game Scripts, patches, OpenTTD Auto Updater, and some sprites)
Junctioneer (a traffic intersection simulator)
Samu
Traffic Manager
Traffic Manager
Posts: 236
Joined: 17 Apr 2007 14:28

Re: 100 years solo AIs openttd.exe CPU time benchmark

Post by Samu »

Zuu wrote:Interesting test, and a nice summary that you have made.

Did you do all the work manually or did you develop something to run the tests? I'm interested in how you did to pause OpenTTD after a given CPU usage. I guess you could write a wrapper-script around a dedicated server that run the tests as long as you have a way of determining the total cpu usage of the OpenTTD process.
It was manual. I ctrl-alt-del to bring up task manager, then I watched the cpu time usage for openttd.exe, and paused the game after a given time.
User avatar
fanioz
Transport Coordinator
Transport Coordinator
Posts: 320
Joined: 19 Dec 2008 05:03
Location: Indonesia
Contact:

Re: 100 years solo AIs openttd.exe CPU time benchmark

Post by fanioz »

Yeah, good benchmark. Although the table was sorted by "how far" the game end, but it did tell how many vehicle build by those AI.
Good Job :lol:
Correct me If I am wrong - PM me if my English was bad :D

**[OpenTTD AI]** Image
***[NewGRF] *** Image
User avatar
Michiel
Transport Coordinator
Transport Coordinator
Posts: 339
Joined: 13 Jul 2008 00:57
Contact:

Re: 100 years solo AIs openttd.exe CPU time benchmark

Post by Michiel »

Samu wrote:I was surprised by some AIs, mostly Rondje. I was expecting lots of cpu usage, to be one of the slowest, but it didn't build anything! Still, with 0 vehicles, it didn't manage to be ranked first.
Was this a game with just one AI being tested? Then I'm not suprised :)
Rondje only leeches, it doesn't build anything of its own if another company hasn't connected it with stations and roads first. So if it's alone, it just sits there scanning the map. Since it starts by counting stations and finds zero, this is very quick.
Samu wrote:Was a bit surprised by how slow ChooChoo is. I thought it was one of the fastest train builders. Well, it might be if counting real-time, but cpu-time usage, it's the slowest for trains.
I guess that is the tradeoff: to build quickly in real time (clock on the wall) and game time (in game date), you'll have to burn as much CPU time as you can get (or work more efficiently, but that's silly talk ;-)).
Samu wrote:I'm deleting those posts. Nevermind, I can't delete, I don't understand this forum.
It's the little X next to the report button (red !), above the edit and quote buttons. Note that it only shows up on your own posts.
User avatar
Lord Aro
Tycoon
Tycoon
Posts: 2369
Joined: 25 Jun 2009 16:42
Location: Location, Location
Contact:

Re: 100 years solo AIs openttd.exe CPU time benchmark

Post by Lord Aro »

actually you can only delete your own posts if there haven't been any replies (otherwise things stop making sense) you can edit your posts so they just show a '.' or something
AroAI - A really feeble attempt at an AI

It is practically impossible to teach good programming to students that have had a prior exposure to BASIC: as potential programmers they are mentally mutilated beyond hope of regeneration. --Edsger Dijkstra
Brumi
President
President
Posts: 920
Joined: 18 Jul 2009 17:54

Re: 100 years solo AIs openttd.exe CPU time benchmark

Post by Brumi »

Thank you for the tests, it's nice to see you again, Samu!
As for my AI, it has done quite as I expected. 8) But I'm really surprised by AIAI, in my tests it wasn't that CPU intensive. Well, it was definitely the fastest to reach 500 road vehicles...
Post Reply

Return to “OpenTTD AIs and Game Scripts”

Who is online

Users browsing this forum: Google Adsense [Bot] and 42 guests