Carcassonne Central

Carc Central Community => General => Topic started by: Decar on March 18, 2016, 06:58:47 AM

Title: What does a 10080 Tile Game Look Like?
Post by: Decar on March 18, 2016, 06:58:47 AM
Unless you've been living under a rock for the past few months - you're probably all aware of Paul's World Record Attempt that will be taking place in a little over a week (http://www.carcassonnecentral.com/community/index.php?topic=2382.0).

It's very difficult for even the regular Mega Carcassonne Player to appreciate the enormity (some would say insanity) of Paul's task.

I decided to put my programming skillz to the test and 'modify' JCloisterZone to support larger games.  Below is my result:

(http://www.tehill.net/carcassonne/fun/10k/PC_FIRE.jpg)

...

So how many boxes of Carcassonne is 10k tiles? - 138.8888 - Let's call it 140.  Some easy tinkering and the ultimate game of Adda vs Ellen (the JCZ AI was off).

I decided to leave my PC running an hour or so.  I came back to discover that both AI had trapped their meeple within the first 200 tiles.  The rest of the game was going to get pretty boring.

More tinkering was required.

How many meeple would the AI need to maintain continuous play?  71 tiles --> 7 meeple.   10k tiles ----> 1k of meeple.

I left it running again and came back in an hour, it was looking good....except each turn was taking ~2 minutes.  This will get exponentially worse as the game progressed.  Time to tinker with the AI.

I'm not an AI expert, I dodged that module at University - on the plus side I know I won't be causing the apocalypse.  Also be safe knowing that JCZ's AI won't be responsible for the end of the world either, specially not after my improvements.

Those wishing to retain the magic of JCZ's AI should probably avoid this paragraph.  The AI keeps a record of every possible tile location and works out the best possible score to determine strategy.  Here's the AI's problem with Carcassonne.  1 tile has 4 options.  2 tiles have 6 options.  3 tiles have 9 options ...you get the picture... 10k tiles has .... alot of options for tile placements.  Firstly JCZ has to check if a tile can be placed somewhere, and then it needs to run the rotations and assessments for score.  He's what I did.  Find all the possible locations.  Select 50 of them and random, don't look at any more.  The theory being that even if the AI misses the best move, random chance should mean it gets the tile it needs.

So Attempt 2 started.....

I came back 5 hours later...
(http://www.tehill.net/carcassonne/fun/10k/LOOP.jpg)

I determined I could save some time my stopping JCZ from rendering all the layers of tiles and meeple and rely on the Screenshot feature I wrote last year.  Wow lucky I wrote that!

Attempt 3 begins:

Saturday 8:30pm - 400tiles - Estimated Speed 1000 tiles per hour:
(http://www.tehill.net/carcassonne/fun/10k/Pic1.jpg)

Looking Good

Saturday 8:54pm - 1300 tiles - Estimated Speed 700 tiles per hour:
(http://www.tehill.net/carcassonne/fun/10k/Pic2.jpg)

Not bad

Saturday 9:43pm - 2000 tiles - Estimated Speed 500 tiles per hour:
(http://www.tehill.net/carcassonne/fun/10k/Pic3.jpg)

We're slowing down now...

Sunday: 3:10am - 3300 tiles - Estimatede Speed 100 tiles per hour:
(http://www.tehill.net/carcassonne/fun/10k/pic4.jpg)

Sunday: 8:20am - 3800 tiles - Estimated Speed 50 tiles per hour:
(http://www.tehill.net/carcassonne/fun/10k/pic5.jpg)

And we're crawling now....

Sunday: 9:58pm - 5400 tiles - Estimated Speed 10 tiles per hour:

(http://www.tehill.net/carcassonne/fun/10k/pic6.jpg)

Tuesday: 15:53pm - 6300 tiles - Estimated Speed Slow
(http://www.tehill.net/carcassonne/fun/10k/pic7.jpg)


Then the unthinkable happened....Actually I expected it from the start.  Those in the know about computer will have seen it coming.  PC's are limited by two factors....Time and Space.  We've already encountered the limitations of Time......

ScreenShot 8.....

Out of Memory Exception.....

Nooooo............


(http://www.tehill.net/carcassonne/fun/10k/MORERAM.jpg)

But I persevered... The game was still running, however I had no visuals.

Thankfully I was reminded to Save the game. The theory being I could reload the game near the end and take a screenshot.

All was not lost!

Wednesday came and went

Thursday started with 1500 tiles left to play

Friday 7am:  150 tiles left to play

Friday....today....1pm....8 tiles remain!!!

Here's the final screenshot:

(http://www.tehill.net/carcassonne/fun/10k/Orig10k%20End.png)

(http://www.tehill.net/carcassonne/fun/10k/pic8_end.jpg)

So now we know Adda is better at cities, Ellen is better at Roads and Cloisters,  neither player is good at farming.

My PC needs a well deserved rest now.

All I can say, is this screenshot shows the sheer craziness of completing such an endeavor. 

For those of you who think this is the largest game of Carcassonne every played:  No it isn't.  Playing two idiotic AI against each other, one of which was capable of trapping ~22 of it's own meeple into a city just to trap and cloister at the same time, isn't a game.  The sheer physical demand of playing continually-non-stop for this duration requires a stamina no PC could come close to.

Paul I wish you and your crew the vest best of luck!  Having set my PC to complete this task gives me a much better understanding of what you're trying to achieve.  Basically, my PC isn't up to the task, I hope you crew are and I hope you achieve your goals!
Title: Re: What does a 10080 Tile Game Look Like?
Post by: jungleboy on March 18, 2016, 07:09:48 AM
Epic post, game and project! Merit for you!

(P.S. They could have done with a few hundred abbeys to fill the gaps...)
Title: Re: What does a 10080 Tile Game Look Like?
Post by: dirk2112 on March 18, 2016, 07:33:26 AM
Awesome.  :(y)
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Decar on March 18, 2016, 07:39:06 AM
Thank you!  Only a few hundred Abbeys?  The orders of magnitude in this this are insane!
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Paul on March 18, 2016, 07:52:21 AM
Thank you for this.

I wasn't sure how I myself would be able to remotely put down an explanation as to how insane of a task we're up against!

What made me realize this, was when I took a measuring tape and outlined 4,5 x 4,5 meters which is the result of a 10k game should we fill in all the gaps.
  Our area (during the convention) is 6 x 8 meters so we're bound to a certain area which also include storage and display.

And then there's the factor of us being 3 people doing the 10k game with less than 3 days duration. Merit for your work!
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Decar on March 18, 2016, 07:58:35 AM
Thanks :) - I hope it's useful!

I roughly measured Tuesday's map and I estimated 4.5m^2 here too.  I think you'll be ok with 6x8, just about!

Can I suggest you use some of these postit-note holders to mark those difficult gaps which need 'rarer' tiles in order to complete.  Maybe you could print some large copies of certain tiles to put them in, so you don't forget where you need them?
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Paul on March 18, 2016, 08:03:00 AM
If I can get hold of these here. :)

But the idea itself is a great idea and there's plenty of other office supplies or hobby articles that can replace should I not find.
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Decar on March 18, 2016, 08:08:18 AM
I thought they'd standout on your enormous landscape and useful reminders.

New game to play here:  'Find the Farmer Competition' - Apparently 456 and 180 farmer points were scored!
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Paul on March 18, 2016, 08:11:16 AM
Had I had the space and time I'd play a 6 player game using more expansion rules over the course of a year or so. That would certainly be an interesting game to follow on the thread!
  Since I suck at this game in competive mode, I'd be happy to host it instead and can use my server to save on image space when the "board" gets huge. This would then be a virtual game instead.
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Valheru on March 18, 2016, 08:12:20 AM
This is beautiful and frightening at the same time. Merit to your pc (through you, good sir)
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Decar on March 18, 2016, 08:18:26 AM
This is beautiful and frightening at the same time. Merit to your pc (through you, good sir)

It's very grateful - who'd have thought a 7-year old laptop could manage such a task.  No doubt others will attempt more impressive feats, but it'll have been the first to blaze such a trail.

It's mainly frightening!
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Paul on March 18, 2016, 08:22:05 AM
The final image looks like a world map of some sort. :)
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Decar on March 18, 2016, 08:23:34 AM
So turns out, Earth was just an unfinished Carcassonne Game of the gods  :(y) :(y)

Edit:  It's like Monkey's with typewriters randomly writing Shakespeare.  How many games do you need to map the earth ;)
Title: Re: What does a 10080 Tile Game Look Like?
Post by: kettlefish on March 18, 2016, 08:27:58 AM
It is interesting, that the AI intellegence don't close the holes in the landscape if possible.
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Decar on March 18, 2016, 08:32:16 AM
Yes, it started off ok.  But around the 4000 tile mark, when the map starts going weird. The AI seized up completely.  Even simply scoring small cities didn't get completed.  Computationally, there's a LOT of positions to consider!
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Paul on March 18, 2016, 08:34:05 AM
A bit off topic, but if I've done the math correct, Sweden would need 2 209 555 555 tiles and 1 halfling tile to cover its area. Doesn't sound much.
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Decar on March 18, 2016, 08:37:16 AM
Almost as many tiles as in your collection!

Title: Re: What does a 10080 Tile Game Look Like?
Post by: Paul on March 18, 2016, 08:52:49 AM
Almost as many tiles as in your collection!

That would be something, wouldn't it. Probably an intervention on me before I get far enough. And then there is the 1500 Ark of the Covenant tiles that I have...
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Decar on March 18, 2016, 12:01:21 PM
I don't fancy modifying JCZ to know what that looks like... :-\
Title: Re: What does a 10080 Tile Game Look Like?
Post by: danisthirty on March 18, 2016, 01:19:17 PM
Thanks and well done Decar, that is quite a map! I've merited you for your l33t skillz in hax0ring JCZ to play itself in this manner. It kind of reminds me of the end of War Games where they get the computer to play itself at Noughts and Crosses in order to save the world (I'm sure this is the main reason that you did it).

Anyway, great stuff. Too immense for me to study in any detail but the mere thought of having 1000 meeples at my disposal is mind-blowing! :o
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Decar on March 18, 2016, 01:44:22 PM
I thought I'd share some Points of Interest from the Map:

(http://www.tehill.net/carcassonne/fun/10k/PoI/PoI_Cities.jpg)

A weird cluster of City Caps - plus one of the farmers!

(http://www.tehill.net/carcassonne/fun/10k/PoI/PoI_Cloisters.jpg)

A Heavy concentration of Cloisters!

(http://www.tehill.net/carcassonne/fun/10k/PoI/PoI_Cloisters2.jpg)

More Cloisters and City Caps

(http://www.tehill.net/carcassonne/fun/10k/PoI/PoI_LongCities.jpg)

This seems to be the AI's flaw, it liked lots City Caps, there are some unusual shapes being made here

(http://www.tehill.net/carcassonne/fun/10k/PoI/PoI_Mega_City.jpg)
A 91 point incomplete (obviously) City.  Blue went to town on this throwing in around 22 meeple; then decided trap it playing the city next to the cloister.

(http://www.tehill.net/carcassonne/fun/10k/PoI/PoI_Roads.jpg)
A concentration of roads and a large 31 point city.
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Paul on March 18, 2016, 02:05:53 PM
The highlights reminds me of my early 10k program draft. Same tiles would cluster together due to limited variation of using only the base game.

Even 2.0 could sometimes get a bit monotone.
Title: Re: What does a 10080 Tile Game Look Like?
Post by: SRBO on March 19, 2016, 01:38:30 AM
the movie "I Robot" tells the theory of how robots cluster together. That some kind of AI automatically does this..
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Paul on March 19, 2016, 02:56:40 AM
the movie "I Robot" tells the theory of how robots cluster together. That some kind of AI automatically does this..

Loved that movie. Even bought it on DVD. That scene where Will Smith goes "I told you so" (after the outbreak) is priceless. :)
Title: Re: What does a 10080 Tile Game Look Like?
Post by: AlbinoAsian on March 19, 2016, 05:55:56 AM
Might be time to start talks with the AlphaGo crew.
Title: Re: What does a 10080 Tile Game Look Like?
Post by: Decar on March 19, 2016, 09:41:48 AM
Might be time to start talks with the AlphaGo crew.

Thanks - I'll be handing over my résumé early next week ;)