Page 4 of 11

Re: Trans AI :: 09-06-19 ::

Posted: 20 Jun 2009 14:12
by davidx123
so it seems that I don't have much time to test you AI.
just got gta iv to my xbox 360 :mrgreen:
ill test it now.

Re: Trans AI :: 09-06-19 ::

Posted: 25 Jun 2009 04:48
by fanioz
Here what I 've got my self with my AI. It happened when Trans is trying to build rail station over an existing station, because AITile.IsBuildable() will return true if tile owner is him self. I hope I can fix this in the next release.

Re: Trans AI :: 09-06-19 ::

Posted: 30 Jun 2009 10:26
by Wold
Dundingworth Falls Transport, 3rd May 1967.png
(68.47 KiB) Downloaded 66 times
Why would the AI start so great with the trains and continue using road vehicles for a fraction of the income ?
Dundingworth Falls Transport, 29th Apr 1968.png
(85.51 KiB) Downloaded 66 times
That idea was rubbish. The AI even sold a train from the original line, which was at least 2 times longer than the "new one".

Re: Trans AI :: 09-06-19 ::

Posted: 01 Jul 2009 05:54
by fanioz
Wold wrote: Why would the AI start so great with the trains and continue using road vehicles for a fraction of the income ?
Well, its because Trans can't build a rail service at that time, so it would fall back to road vehicle service.
In the next version you can push Trans to only build rail (and vice-versa) :D
Wold wrote: That idea was rubbish. The AI even sold a train from the original line, which was at least 2 times longer than the "new one".
That was a bug, I never though, thanks to report. :D

Re: Trans AI :: 09-06-19 ::

Posted: 08 Jul 2009 14:13
by Wold
Minwood Transport, 30th Apr 1965.png
(43.57 KiB) Downloaded 39 times
Minwood Transport, 28th Apr 1965.png
(49.2 KiB) Downloaded 34 times
These trains have no way to go back :?:
Cathill Transport, 3rd Aug 1965.png
(97.56 KiB) Downloaded 37 times
It competes with another AI. The AI has built the line after the other company, still it made 3 trains which made a great income. It left them operating for a couple of years, when it decided to sell 2/3 and left the 3rd train in depot doing nothing.

Re: Trans AI :: 09-06-19 ::

Posted: 08 Jul 2009 14:25
by Zutty
Hi fanioz,

Just a quick note. Your AI is really cool and extremely fast, but I notice using a NewGRF engine set that it builds rather poor engines. I tried it with Pikkabird's UK Renewal set + the addons set, and it keeps building low power, low reliability tram engines or shunters of <1,000HP to haul coal trains.
transai-tramengine.png
transai-tramengine.png (90.58 KiB) Viewed 3190 times
As you can see, there are much better engines it could have used, and it does this every time. Maybe this is because the engines in UKRS cost more than the standard ones.

Re: Trans AI :: 09-06-19 ::

Posted: 09 Jul 2009 18:50
by Wold
Some things for you too :D
FanAI #1.png
(99.75 KiB) Downloaded 58 times
Well it speaks for itself :)
FanAI #2.png
(54.89 KiB) Downloaded 58 times
A rather unsuccessful route with no exception thrown
FanAI #3.png
(56.95 KiB) Downloaded 63 times
As seen on the left - originally 3 trains serving the gold station, it has build a 4th one and later sold the 2nd

Re: Trans AI :: 09-06-19 ::

Posted: 12 Jul 2009 03:20
by fanioz
hey.. I just comeback from my annual holiday and it seems much changes in this forum.
Wold wrote:Some things for you too :D
FanAI #1.png
Well it speaks for itself :)
FanAI #2.png
A rather unsuccessful route with no exception thrown
FanAI #3.png
As seen on the left - originally 3 trains serving the gold station, it has build a 4th one and later sold the 2nd
thanks, It would be fixed in the next version.
Zutty wrote:Hi fanioz,

Just a quick note. Your AI is really cool and extremely fast, but I notice using a NewGRF engine set that it builds rather poor engines. I tried it with Pikkabird's UK Renewal set + the addons set, and it keeps building low power, low reliability tram engines or shunters of <1,000HP to haul coal trains.
transai-tramengine.png
As you can see, there are much better engines it could have used, and it does this every time. Maybe this is because the engines in UKRS cost more than the standard ones.
hi zutty, I would like to try better engine selection then. thanks

Re: Trans AI :: 09-07-13 ::

Posted: 13 Jul 2009 13:02
by fanioz
Many people said that 13 is related to something ......bad luck, but here is TransAI 0907.....13
I don't expect to be unlucky today, but if you still find a crash... well I got my unlucky today.

Whats New ? Whats changed? Why 13?
I just press Ctrl-Alt-Del on my brain, and...
-I've got a small 1x3 rail station flying in front of my eyes. With this small station I can build much more station in the Drop Off target. Later if I've finished my RailPF modification to re-use existing track, I promise to build the better-realistic Drop off station. (oh my God, I don't want to promise thing :cry: )
-Try to use PBS signal and build them after building track immediatelly.
-Fixing the reported bugs related to vehicle.
-Configurable Trans AI behaviour (instead of hardcoded in 090619). And thanks to ....
--Build Sign (zuu)
--Allow build Bus (Admiral)
--Allow build Truck (Admiral)
--Allow build Train (Admiral)
--Percent of last month Transported cargo. (SirKoz) <--- if A town/industry last month transported cargo percent is above this value, Trans would skip it.
--Processing speed (it seems Pathzilla have this too., )


Codechange:
I've decide to fall back to libraries which is provided by bananas. (Ask me if you need a reason :lol: )
-FibbonaciHeap 2
-AyStar.6
-RailPF 1
-RoadPF 3
Add More Documentation.
Cleanup code, I can reduce Trans AI code from 300kb (3rd biggest after Admiral-380kb and NoCAB-330kb) to 240kb (below pathzilla-276kb)

As usual, download via Bananas or 2nd page.

And... Go!

Re: Trans AI :: 09-07-13 ::

Posted: 13 Jul 2009 13:47
by Dezmond_snz
Thanx, Fanioz, for update.
It's very nice to see that your AI become more familiar with trains.
Tested it a bit and found two issues.
1. Articulated vehicles again (see SH).
2. 2cc trainset: it builds monorail line between towns but ain't build trains, at deport i found only 2 wagons. (2cc don't provide mail wagons for monorails - is that reason?)

Also you can see at screenshot train station built at not ideal position - its better to check if we can build rails out of stations before build station. :)

Re: Trans AI :: 09-07-13 ::

Posted: 13 Jul 2009 19:11
by SirkoZ
Thank you Fanioz for this update - I'll gladly try it out. :D
By the way - one suggestion right away - based on above screenshot - perhaps build bridges over any existing line - be it rail or road so you can dramatically lower the number of folks that travel by road, being casual and wearing ties. :mrgreen:

By the way - second iteration - number 13? It's all good, although I really like Linux way of describing stable builds with even numbers and those other with odd. :wink:

Re: Trans AI :: 09-07-13 ::

Posted: 18 Jul 2009 18:27
by Brumi
Hi all,
As this is my first post to the forums, I'd like to congratulate to the OTTD developers, you made a great game even greater! :bow:
And for the AI developers, you also made a great work! I really like the whole NoAI thing.
I've been playing around with the different AIs for quite a long time, and I have a few minor suggestions. (sorry if they have been discussed earlier)
Here are my suggestions for Trans:
1) The new feature with the adjustable competition level (last_transport) is really great, but I think you swapped the easy_value and the hard_value. The description says that the AI won't compete above the given value. So let's say that I transport 50% of the cargo from a given industry. In easy mode last_transport = 60, so it will compete. Hard_value is 0, so it won't compete with me in hard mode. But this is just theory, I didn't test this thoroughly, so I may be wrong...
2) If I start a game in 1950 without NewGRF trainsets, Trans always chooses the Kirby Paul Tank engine. This may be OK with the realistic acceleration turned on, but without realsitic acceleration it is obviously a bad choice. The two differents acceleration models confuse AdmiralAI as well, because IMHO without NewGRFs and without realistic acceleration the best choice is always the fastest and/or strongest (of course if we can afford it).
3) You should include some sort of maximum distance check when building train lines, especially on maps bigger than 256x256. On larger maps, Trans wastes a lot of time on pathfinding (for example, across the diagonal on a 512x512 map), and those Kirby Paul Tanks just struggle with that distance.
And I think Trans is not as bad compared to other AIs as you say Fanioz, it can keep up with the others on the short term (I always test AIs on short term, so no information for me about long term performance).
Keep up the good work, Fanioz! :D
Best wishes,
Brumi

Re: Trans AI :: 09-07-13 ::

Posted: 18 Jul 2009 19:57
by derchesten
Yo men!

hey, that A.I. is kind'a stupid, i've been playing with it, and the way it makes the railways is very ineffective, that circular way is dummy.

and if you can fix the save function, every time i load a game, the A.I. shows an error (in the console) that the type is string, and it have to be integer, u must fix it, 'cause it get lag the game...

well that's my problem

if u fix it, i'll kiss your feet

Re: Trans AI :: 09-07-13 ::

Posted: 19 Jul 2009 16:23
by davidx123
never herd about being nice?
also,take notice to the fact that trans is just an effort for being a transporter,and it just a AI that is fun to play against.i won't play this with this AI if he gonna make the best,the ultimate railways.
this ai good because he just plain simple!

Re: Trans AI :: 09-07-13 ::

Posted: 19 Jul 2009 16:44
by Dustin
derchesten wrote:Yo men!

hey, that A.I. is kind'a stupid, i've been playing with it, and the way it makes the railways is very ineffective, that circular way is dummy.

and if you can fix the save function, every time i load a game, the A.I. shows an error (in the console) that the type is string, and it have to be integer, u must fix it, 'cause it get lag the game...

well that's my problem

if u fix it, i'll kiss your feet
Trans AI is GNU GENERAL PUBLIC LICENSE, Version 2, June 1991. Therefore, you don't like it, fork of your own version and fix it. Have you checked out the other AIs? Is there one you like? If not, you better design your own. :)

I admired all the other AI's. They are all cool in some way. So I was inspired to try my own. You should try it.

Re: Trans AI :: 09-07-13 ::

Posted: 20 Jul 2009 05:29
by fanioz
Brumi wrote:Hi all,
As this is my first post to the forums, I'd like to congratulate to the OTTD developers, you made a great game even greater! :bow:
And for the AI developers, you also made a great work! I really like the whole NoAI thing.
I've been playing around with the different AIs for quite a long time, and I have a few minor suggestions. (sorry if they have been discussed earlier)
Here are my suggestions for Trans:
1) The new feature with the adjustable competition level (last_transport) is really great, but I think you swapped the easy_value and the hard_value. The description says that the AI won't compete above the given value. So let's say that I transport 50% of the cargo from a given industry. In easy mode last_transport = 60, so it will compete. Hard_value is 0, so it won't compete with me in hard mode. But this is just theory, I didn't test this thoroughly, so I may be wrong...
Well, I got confused with the term I've been used for my self :oops: . What I want to do is not same with the description I've wrote. So you maybe right.
Brumi wrote: 2) If I start a game in 1950 without NewGRF trainsets, Trans always chooses the Kirby Paul Tank engine. This may be OK with the realistic acceleration turned on, but without realsitic acceleration it is obviously a bad choice. The two differents acceleration models confuse AdmiralAI as well, because IMHO without NewGRFs and without realistic acceleration the best choice is always the fastest and/or strongest (of course if we can afford it).
The version 90713 should detect realistic acceleration, both in rail pathfinder and vehicle selection. But it seems that it doesn't work for vehicle, I have to check it.
Brumi wrote: 3) You should include some sort of maximum distance check when building train lines, especially on maps bigger than 256x256. On larger maps, Trans wastes a lot of time on pathfinding (for example, across the diagonal on a 512x512 map), and those Kirby Paul Tanks just struggle with that distance.
Yes, I (hope) have done it. Trans would not have maximum distance, in the hope that it still can build later if he have enough money. However current sort algorithm need to improve.
Brumi wrote: And I think Trans is not as bad compared to other AIs as you say Fanioz, it can keep up with the others on the short term (I always test AIs on short term, so no information for me about long term performance).
Keep up the good work, Fanioz! :D
Best wishes,
Brumi
In long term, it still have problem with Autorenewal and upgrading railtypes.

Thanks, thank you very much for the suggestions. These would be added in my "TODO-list". :D

Re: Trans AI :: 09-07-13 ::

Posted: 20 Jul 2009 06:30
by fanioz
Dezmond_snz wrote:Thanx, Fanioz, for update.
It's very nice to see that your AI become more familiar with trains.
Tested it a bit and found two issues.
1. Articulated vehicles again (see SH).
2. 2cc trainset: it builds monorail line between towns but ain't build trains, at deport i found only 2 wagons. (2cc don't provide mail wagons for monorails - is that reason?)

Also you can see at screenshot train station built at not ideal position - its better to check if we can build rails out of stations before build station. :)
Thanks for testing, its something I did'nt expected. (I think I've checked it before build) :D
SirkoZ wrote:Thank you Fanioz for this update - I'll gladly try it out. :D
By the way ..... so you can dramatically lower the number of folks that travel by road, being casual and wearing ties. :mrgreen:
Agree SirkoZ :P thanks..

Re: Trans AI :: 09-07-13 ::

Posted: 20 Jul 2009 07:24
by fanioz
derchesten wrote:Yo men!

hey, that A.I. is kind'a stupid, i've been playing with it, and the way it makes the railways is very ineffective, that circular way is dummy.

and if you can fix the save function, every time i load a game, the A.I. shows an error (in the console) that the type is string, and it have to be integer, u must fix it, 'cause it get lag the game...

well that's my problem

if u fix it, i'll kiss your feet
Dustin wrote: Trans AI is GNU GENERAL PUBLIC LICENSE, Version 2, June 1991. Therefore, you don't like it, fork of your own version and fix it. Have you checked out the other AIs? Is there one you like? If not, you better design your own. :)

I admired all the other AI's. They are all cool in some way. So I was inspired to try my own. You should try it.
derchesten, Dustin is just right. You can make it better, or make your own AI.

FYI, I'm not a programmer nor developer. I only OpenTTD fans that would like to try to make something. I started my AI from zero knowledge, and made a step by step progress. I do all I can to fix the bug reported or something weird that was build by this AI. It's not a big problem for me if I got blamed. Although I would feel ashamed. :oops:

Re: Trans AI :: 09-07-13 ::

Posted: 21 Jul 2009 04:29
by Dustin
fanioz wrote:
derchesten wrote:Yo men!

hey, that A.I. is kind'a stupid, i've been playing with it, and the way it makes the railways is very ineffective, that circular way is dummy.

and if you can fix the save function, every time i load a game, the A.I. shows an error (in the console) that the type is string, and it have to be integer, u must fix it, 'cause it get lag the game...

well that's my problem

if u fix it, i'll kiss your feet
Dustin wrote: Trans AI is GNU GENERAL PUBLIC LICENSE, Version 2, June 1991. Therefore, you don't like it, fork of your own version and fix it. Have you checked out the other AIs? Is there one you like? If not, you better design your own. :)

I admired all the other AI's. They are all cool in some way. So I was inspired to try my own. You should try it.
derchesten, Dustin is just right. You can make it better, or make your own AI.

FYI, I'm not a programmer nor developer. I only OpenTTD fans that would like to try to make something. I started my AI from zero knowledge, and made a step by step progress. I do all I can to fix the bug reported or something weird that was build by this AI. It's not a big problem for me if I got blamed. Although I would feel ashamed. :oops:

Fanioz,

I am trying your AI out against mine. In 3 of 4 trials your AI got off to a slow start and went bankrupt (at which time I stopped). However, when yours got a good start, mine can't keep up. My passing lane builder is just too slow. (I have some ideas to fix that.) Your system (however it works) works nicely and you build routes much faster than my AI. Well done sir!

I like your network. Your stations with the depot and PBS signal works really well.

I would suggest you should limit your starting route distance. If your first route is short (50-200 tiles) then your AI gets a good start and runs well. Otherwise it's very nice. I really like your debug output. Very friendly. -> Good Job :-D

I would like to see derchesten try to do better. Yours is a nice AI and I am impressed by it. Moreso that you aren't a programmer. Squirrel isn't the easiest scripting language! (But I like it well for this.)

Re: Trans AI :: 09-07-13 ::

Posted: 21 Jul 2009 13:45
by fanioz
Dustin wrote: Fanioz,

I am trying your AI out against mine. In 3 of 4 trials your AI got off to a slow start and went bankrupt (at which time I stopped). However, when yours got a good start, mine can't keep up. My passing lane builder is just too slow. (I have some ideas to fix that.) Your system (however it works) works nicely and you build routes much faster than my AI. Well done sir!

I like your network. Your stations with the depot and PBS signal works really well.

I would suggest you should limit your starting route distance. If your first route is short (50-200 tiles) then your AI gets a good start and runs well. Otherwise it's very nice. I really like your debug output. Very friendly. -> Good Job :-D

I would like to see derchesten try to do better. Yours is a nice AI and I am impressed by it. Moreso that you aren't a programmer. Squirrel isn't the easiest scripting language! (But I like it well for this.)
Thanks Dustin. :D. I would like to take an other approach to solve the pathfinding waste time.
Thanks for testing. :D