DS Polarium finished very fast. It's a pity it's just vault material.
About the game: You do see a field with black and white tiles, surrounded by gray tiles. Your task is to draw a path (the yellow thing). If your path hits a black or white tile, this tile is flipped. If this causes all tiles in the row to become black, or all tiles become white, then this row is deleted. The gray tiles always stay gray, they don't matter for that. Sometimes, it's necessary to use those gray tiles too. Your task is to draw a path so that all lines get deleted at once.
There were two difficult problems to solve: How the input for the puzzles can be done in the fastest way, and which solution takes the lowest amount of frames.
At first we thought: You need to touch every tile where a turn appears for 3 frames, and afterwards one frame pause. I've got a Lua script working which just tried every single possible path. It was too slow, so it got tweaked more and more. ais523 made another solver with a different model, and it worked a lot faster. Some puzzles with a lot of possible paths could still not be computed in a reasonable amount of time, for example stage 21. As I heard about solvers for SAT problems, I converted the "problem" into a set of thousands of boolean variables, and let a SAT solver (minisat) solve the problem. But: A SAT solver only tries to find ONE solution, it doesn't search for the best one. Therefore, the solver has to run multiple times, each time with another "score" limit.
Then there was a "glitch", at least we thought that: Sometimes, the frame with no input could be left out. As I played around a bit, I found out that you can move a lot faster: Up to two tiles per frame. Luckily it was not that hard to adjust the solver for that. A bit later, I found out that the movement can be done with 40 pixels per frame, which equals 2.5 tiles per frame in a straight line. It was somewhat tricky to think about a method which allows the 3-2-3-2-... input, but it worked out to be quite easy. Finally, this piece of software was used to find the solutions. More precisely: It creates a description of the "problem" in the so-called conjunctive normal form, and then minisat generates one solution if there is any, and then the solution (which is just a set of thousands of boolean variables) is converted back to a human-readable format.
I recommend you to read through all pages of the Polarium thread to see how the solvers evolved.
Aims for fastest real time to the credits screen.
Does not aim on shortest input: The last few frames of the movie can be cut out, and you would still see the credits. However, it would look realĺy inconsistent to cut them out. If you want to beat this movie just aiming at shortest input, make sure to be faster than this movie which doesn't double-draw the path for stage 100
The rerecord count only covers the rerecords done before the first puzzle. The rest was botted, more precisely: this script was used to generate the final movie. The solver itself is massively complex.
Enjoy!

feos: Accepting for Vault. Movie length to game completion ratio is up to the author.
partyboy1a: As both versions are good, I'd go with the submitted version.
Spikestuff: On it...


TASVideoAgent
They/Them
Moderator
Joined: 8/3/2004
Posts: 15537
Location: 127.0.0.1
This topic is for the purpose of discussing #4066: partyboy1a's DS Polarium "puzzle mode" in 06:57.68
Editor, Player (44)
Joined: 7/11/2010
Posts: 1029
Waiting for temp encode. (Also I remember helping out with earlier versions of the script, but I don't think any of my input is involved in this run. So I'm a bit more involved with this than most people.) I feel that challenge mode would make a better TAS, but puzzle mode is easier to script, at least. Also, this has a fairly good chance of being optimal, unless a faster way to input the puzzles or to do menuing is discovered.
Spikestuff
They/Them
Editor, Publisher, Expert player (2630)
Joined: 10/12/2011
Posts: 6435
Location: The land down under.
Did someone say Temp Encode?: Link to video Most likely will upload a nico version too. Cannot create Nico version. Also voted Yes.
WebNations/Sabih wrote:
+fsvgm777 never censoring anything.
Disables Comments and Ratings for the YouTube account. Something better for yourself and also others.
Editor, Skilled player (1534)
Joined: 7/9/2010
Posts: 1319
That's something for the vault.
Favorite animal: STOCK Gt(ROSA)26Sortm1.1(rtTA,EGFP)Nagy Grm7Tg(SMN2)89Ahmb Smn1tm1Msd Tg(SMN2*delta7)4299Ahmb Tg(tetO-SMN2,-luc)#aAhmb/J YouTube Twitch
Site Admin, Skilled player (1250)
Joined: 4/17/2010
Posts: 11469
Location: Lake Char­gogg­a­gogg­man­chaugg­a­gogg­chau­bun­a­gung­a­maugg
Didn't understand a thing, voted No.
Warning: When making decisions, I try to collect as much data as possible before actually deciding. I try to abstract away and see the principles behind real world events and people's opinions. I try to generalize them and turn into something clear and reusable. I hate depending on unpredictable and having to make lottery guesses. Any problem can be solved by systems thinking and acting.
Player (137)
Joined: 9/18/2007
Posts: 389
At first, my solver used a start point and went on step by step on the path. The solver from ais523 used a different design: It mainly held some data which tiles are connected. That was a huge speedup for the final solver that was used. The most interesting part of this is how the fastest solution was found: The "problem" was converted into a set of boolean variables (more than 10000 for each puzzle and each solving attempt!), and a lot of clauses in the so-called conjunctive normal form. Then another computer program was used to find one out of the potentially 2^10000 combinations of the boolean variables. Such solvers are extremely well programmed pieces of software, they can find one solution in a reasonable amount of time. Writing a specialized program to brute-force all paths would take extremely long, especially if there are many different paths to try (as it is the case for stage 21 for example). As long as you don't find any method for faster input, you shouldn't be able to find a faster path. Challenge mode should be more interesting, it's a bit more like Tetris.
feos wrote:
Didn't understand a thing, voted No.
Oh, I should have included a few words about the concept of this game: You do see a field with black and white tiles, surrounded by gray tiles. Your task is to draw a path (the yellow thing). If your path hits a black or white tile, this tile is flipped. If this causes all tiles in the row to become black, or all tiles become white, then this row is deleted. The gray tiles always stay gray, they don't matter for that. Sometimes, it's necessary to use those gray tiles too. Your task is to draw a path so that all lines get deleted at once. The movie itself is still not very exciting to watch. It was an interesting project nevertheless.
Lil_Gecko
He/Him
Player (97)
Joined: 4/7/2011
Posts: 520
Didn't understand either. What are you supposed to do ?
Player (137)
Joined: 9/18/2007
Posts: 389
OK, I updated the submission text to explain the basic idea of the game.
Patashu
He/Him
Joined: 10/2/2005
Posts: 4042
Rules for puzzle mode: -You can only make one 'stroke' that can't overlap itself -Every horizontal line must be made entirely black or entirely white If you think the TAS is boring, try to solve each puzzle before playing the solution. It gets hard in the 30s etc :)
My Chiptune music, made in Famitracker: http://soundcloud.com/patashu My twitch. I stream mostly shmups & rhythm games http://twitch.tv/patashu My youtube, again shmups and rhythm games and misc stuff: http://youtube.com/user/patashu
Player (80)
Joined: 8/5/2007
Posts: 865
Easily worthy of publication to the Vault. With that said, I'd like to know two things: 1) What is the basic idea behind the bot? Surely there are some basic concepts in there. What was your strategy in writing it? (Also, are these puzzles NP-complete, as I suspect?) 2) Why does it look like you trace twice over every path? I realize this may be an automatic process by the game, but I found it kind of distracting. What's going on here?
Editor, Expert player (2071)
Joined: 6/15/2005
Posts: 3282
The TAS seems rather long for its kind (compare [1414] GB Minesweeper by Ryuto in 00:29.65; the predecessor video chose to skip to Level 7 for a reason). Puzzle-done-fast TASes are OK, but only if they are very short.
Editor, Player (44)
Joined: 7/11/2010
Posts: 1029
My own explanation of how the game works: you have to draw a single continuous line that can't cross itself, can only move through the edges of squares (no crossing corners), and for each horizontal row, it either has to go through all the white squares, or all the black squares. (Typically, there are multiple solutions, especially for the exact route of the path, but often also as to which rows you go through the black squares, and which rows you go through the white squares.) You have a one-square-wide border at the side of the screen that has no restrictions on whether you use it or not (but your line still can't cross itself); this gives you some more options, and is often necessary. I do think the way that this TAS was created is interesting (it's entirely done by a script that solves the puzzles), but sadly, that doesn't really show when watching it. As such, I guess this is destined for the Vault.
Joined: 2/27/2011
Posts: 69
Location: Calgary, Alberta
I think the game choice is lousy, but the bot design is fascinating. It was really neat seeing how simple some of the solutions turned out to be.. It wasn't neat seeing how obvious some of the solutions turned out to be :P Very well done so I voted yes. Was neat to see the game slapped around a bit
Joined: 9/22/2011
Posts: 42
Of course, the main interest of this TAS was the bot used to make it, and the various redesigns it went through. Perhaps you should talk more about that in the description, or at least link to the topic in which it was talked about, to give viewers more of an understanding of what went into this movie. I found watching it entertaining, having played the game before (and never beaten the puzzle mode) and also being really into computer science and programming. But, the current description page doesn't really do justice to the very interesting and unique work that went into the creation of this movie!
Designer of Copy Kitty, a game about giant robots and explosions
Sir_VG
He/Him
Player (40)
Joined: 10/9/2004
Posts: 1913
Location: Floating Tower
Runs like this are the reason for the vault. Well done, interesting, though not entertaining. But would still be a great addition to the site. Yes for Vault.
Taking over the world, one game at a time. Currently TASing: Nothing
Player (137)
Joined: 9/18/2007
Posts: 389
AzureLazuline wrote:
Of course, the main interest of this TAS was the bot used to make it, and the various redesigns it went through. Perhaps you should talk more about that in the description
That was a good advice, I updated the description once more. Thanks for the votes
Player (137)
Joined: 9/18/2007
Posts: 389
Bobo the King wrote:
Easily worthy of publication to the Vault. With that said, I'd like to know two things: 1) What is the basic idea behind the bot? Surely there are some basic concepts in there. What was your strategy in writing it? (Also, are these puzzles NP-complete, as I suspect?) 2) Why does it look like you trace twice over every path? I realize this may be an automatic process by the game, but I found it kind of distracting. What's going on here?
1) I think the problem "is the puzzle solvable?" is NP-complete. Well, the bot isn't easy to explain, you'll need to read the source code. I'm sorry, I don't have that much time right now to explain it. 2) I let the solver draw every path twice because otherwise you wouldn't have any time to see the solution that was used. I also do that after puzzle 100 for consistency. Not doing that would save 45 frames of input, but the ending wouldn't appear faster.
Experienced player (658)
Joined: 5/16/2009
Posts: 235
Yes for Vault because of Technical Quality and optimization.
Site Admin, Skilled player (1250)
Joined: 4/17/2010
Posts: 11469
Location: Lake Char­gogg­a­gogg­man­chaugg­a­gogg­chau­bun­a­gung­a­maugg
Please upload the trimmed movie as well.
Warning: When making decisions, I try to collect as much data as possible before actually deciding. I try to abstract away and see the principles behind real world events and people's opinions. I try to generalize them and turn into something clear and reusable. I hate depending on unpredictable and having to make lottery guesses. Any problem can be solved by systems thinking and acting.
Player (137)
Joined: 9/18/2007
Posts: 389
OK, I uploaded the shorter version to my user files, here: http://tasvideos.org/userfiles/info/9019948908770913. It reaches the end after the same amount of time. Feel free to use this one if you dislike the somewhat complicated original goal. This would just be shortest input until ending is reached without further input.
Joined: 3/14/2008
Posts: 152
Location: United Kingdom
Well done on actually getting it finished and submitted, something I probably wouldn't have gotten round to doing myself for a few months at least. Voted yes. I also highly recommend reading the linked topic, since if you watch some of the earlier videos you can see how much faster the TAS is now with all the advanced solvers, than if I had finished a puzzle mode TAS with the old solver, (probably about 50% faster over the whole movie). Especially this post to see the solver running in real time.
Spikestuff
They/Them
Editor, Publisher, Expert player (2630)
Joined: 10/12/2011
Posts: 6435
Location: The land down under.
partyboy which one are you wanting to use?
WebNations/Sabih wrote:
+fsvgm777 never censoring anything.
Disables Comments and Ratings for the YouTube account. Something better for yourself and also others.
Site Admin, Skilled player (1250)
Joined: 4/17/2010
Posts: 11469
Location: Lake Char­gogg­a­gogg­man­chaugg­a­gogg­chau­bun­a­gung­a­maugg
I didn't mention which one is accepted since he said he really prefers the full version, the one he submitted. I think you can use it with no fear.
Warning: When making decisions, I try to collect as much data as possible before actually deciding. I try to abstract away and see the principles behind real world events and people's opinions. I try to generalize them and turn into something clear and reusable. I hate depending on unpredictable and having to make lottery guesses. Any problem can be solved by systems thinking and acting.
Player (137)
Joined: 9/18/2007
Posts: 389
As both versions are good, I'd go with the submitted version. (It may also save some encoding work.) Then this movie would be beatable by one that shows the "CLEAR" message after all puzzles are done on an earlier frame than my movie does. If one just goes for shortest input time, he or she would have to beat the shorter version. It won't be easy to beat this one though.
Post subject: Movie published
TASVideoAgent
They/Them
Moderator
Joined: 8/3/2004
Posts: 15537
Location: 127.0.0.1
This movie has been published. The posts before this message apply to the submission, and posts after this message apply to the published movie. ---- [2454] DS Polarium "puzzle mode" by partyboy1a in 06:57.68