I let an AI design my couch | Useless Game Dev

Sdílet
Vložit
  • čas přidán 6. 09. 2022
  • I’m moving into a new flat. I need a new couch. The couch needs to fit into my apartment. Maybe asking a computer to design the shape of the couch was a bad idea.
    More reading/watching on this subject:
    - Dan Romik, leading sofa expert www.math.ucdavis.edu/~romik/m...
    - Numberphile video on the matter (with Dans Romik) • The Moving Sofa Proble...
    - Good ol’ Wikipedia en.wikipedia.org/wiki/Moving_...
    Awesome 3D Sofa models by Manon - www.artstation.com/manon_bout...
    Music:
    - Couch Potato - Wow Sounds
    - Wisps of Whorls Kevin MacLeod (incompetech.com)
    Licensed under Creative Commons: By Attribution 3.0 License
    creativecommons.org/licenses/b...
    Support the channel on Patreon to get extra content, and access to the source code of all projects!
    / uselessgamedev
    Follow me on Twitter, not that I tweet that often: / uselessgamedev
    Kappa Avatar art by Boskoop www.artstation.com/boskoop
    And as always, have a good one!
    #Unity #GameDev #IndieDev #geneticalgorithm #devlog
  • Věda a technologie

Komentáře • 110

  • @uselessgamedev
    @uselessgamedev  Před rokem +3

    Hey y'all, I now have a Patreon where I share the source code for every project, as well as bonus video content!
    Check it out if you want here: www.patreon.com/UselessGameDev

  • @storingjazzinmycheeksforth5319

    love that the ai got to the same solution mathematicians did just by bashing its head against a wall 2000 times

    • @salvadorsanchez5057
      @salvadorsanchez5057 Před rokem +24

      the mathematicians also got it empirically so they probably used a similar algorithm

  • @FokoPoko991
    @FokoPoko991 Před rokem +150

    watching people overengineering a problem for the hell of it never gets old :)

  • @liambenson5339
    @liambenson5339 Před rokem +96

    Buy those couches that come in parts. Bring the parts into the room. Put them together

    • @uselessgamedev
      @uselessgamedev  Před rokem +79

      Where's the fun in that haha.
      Last time I actually moved, the couch actually went in through the window

    • @rumble1925
      @rumble1925 Před rokem +13

      Lol, the difference between wisdom and intelligence. One will require creating a genetic algorithm, the other requires a screwdriver and some extra trips up and down the stairs :D

  • @JRHainsworth
    @JRHainsworth Před rokem +24

    As someone who already knew the solution to this problem, it was interesting watching the AI actually approach the correct shape.

  • @thecasualshow5244
    @thecasualshow5244 Před rokem +51

    everything from the quality of little animations and bits to the actual concept and execution of your videos, man your about to blow up

    • @uselessgamedev
      @uselessgamedev  Před rokem +7

      Thank you!

    • @mistaxe
      @mistaxe Před rokem +2

      @@uselessgamedev So true. You remind me of Code Bullet, but are unique - you have charisma, your visuals have their own style and are not overly complicated, and most importantly, you communicate concepts effectively and clearly without being boring and one-dimensional. Great work!

  • @asyncawait2839
    @asyncawait2839 Před rokem +27

    Just take first variant and rotate it halfway around the horizontal axis. The strong friend is necessary.

    • @leleogere
      @leleogere Před rokem +1

      As the walls are very close to the couch I don't think you can actually rotate it around the horizontal axis because of its height

  • @Mark240
    @Mark240 Před rokem +4

    I used to deliver furniture that 3rd dimension really helps

  • @DUHRIZEO
    @DUHRIZEO Před rokem +23

    Breed a new generation of couches 😂 I love it haha what a fun idea! Awesome video.

  • @borincod
    @borincod Před rokem +6

    you can fit almost any sofa, which length is less than ceiling height. Just let the longest side of your sofa to be vertical to the floor, while moving your new piece of furniture around. This is how sofas / tables are usually squeezed through very narrow turns / corridors / niches. Larger sofas can be usually disassembled to smaller pieces.
    This comment is for those readers who took the video too seriously.

    • @uselessgamedev
      @uselessgamedev  Před rokem +3

      In my actual apartment the couch didn't fit through the door and ended up coming in through the window.
      There's a whole other level of simulation that awaits!

  • @pauldaulby260
    @pauldaulby260 Před rokem +6

    Nice video, I recently saw the numberphile video on this. Cool to see a generic algorithm come to the same conclusion

  • @gamedev_byhobby8872
    @gamedev_byhobby8872 Před rokem +5

    A rectangular couch would work regarsless if you put it on its side. Just make sure its cross section is not larger than 1m2

    • @gamedev_byhobby8872
      @gamedev_byhobby8872 Před rokem

      Lmao but the final version is much better. I definitely don't see any resemblance to any other object

  • @edenrom2349
    @edenrom2349 Před rokem +3

    okay but consider this: when in the corridor after the first turn, do a barrel roll (any damage to your back is a worthy sacrifice for science)

    • @uselessgamedev
      @uselessgamedev  Před rokem +1

      What if the ceiling is so low the couch barely slides under it

    • @edenrom2349
      @edenrom2349 Před rokem +2

      @@uselessgamedev this would imply either your couch is taller than you or you must crawl into your appartment

  • @mateuszpatua3016
    @mateuszpatua3016 Před rokem +2

    I'm bingewatching your channel, so much fun

  • @ianh3385
    @ianh3385 Před 6 měsíci +1

    It generated the perfect shape for a stool

  • @nunosantiago6720
    @nunosantiago6720 Před rokem +4

    Leonard, absolutely brilliant. Very entertaining. An algorythms, coding, biology and social science all in one lesson. 😲uau I just love it.

  • @therustybiscuit6482
    @therustybiscuit6482 Před rokem

    Just wanted to say that I'm loving your channel. Niche computer science problems brought to you in a concisely and knowledgeable way are my jam.

    • @uselessgamedev
      @uselessgamedev  Před rokem +1

      Thank you for your comment I'm glad you like the videos. More jam coming soon :)

  • @mauricestardddude8317
    @mauricestardddude8317 Před rokem +8

    You could actually just have flipped the coutch upside down for the second L

    • @uselessgamedev
      @uselessgamedev  Před rokem +3

      Yes. All of this is assuming a 2D-only space, or a very very low ceiling :)

    • @charlesbarrow803
      @charlesbarrow803 Před rokem +2

      @@uselessgamedev I'd love to see the 3d version, though the extra dimensions means path might need to evolve with the sofa, and you would need to force the sofas to have a sitting section, maybe a boolean where a sitting area is subtracted from the 3d shape?

    • @mixer0014
      @mixer0014 Před rokem +1

      @@charlesbarrow803Or it could evolve a shape that marks the maximum bounds of of the sofa, and later manually design something that fits inside that shape.

  • @farfuraaa
    @farfuraaa Před rokem +4

    This video is what youtube is all about for me, great video!!.
    Hope to more

    • @uselessgamedev
      @uselessgamedev  Před rokem +2

      Thank you! This is indeed the kind of goofy-ish topics I hope to make more of

  • @saile515
    @saile515 Před rokem

    Now you just have to simulate this problem in 3D, since that would allow a larger couch.

  • @BlunderMunchkin
    @BlunderMunchkin Před rokem +2

    You stand your couch on its end when moving it around sharp corners.

  • @skougi
    @skougi Před rokem

    nice. excellent couch. thanks for posting. always a good experience watching your content.

  • @BakeBakePi
    @BakeBakePi Před rokem +1

    Great video! That was really interesting to watch!

  • @ayushwardhan7663
    @ayushwardhan7663 Před rokem

    I love this soft computing problem 😌this is a very useful, smart channel

  • @pafnutiytheartist
    @pafnutiytheartist Před rokem +2

    Interestingly, generated couch shapes were pretty close to the proposed human solutiuons.

    • @uselessgamedev
      @uselessgamedev  Před rokem +2

      Yes it was the reason I made this, to see if a genetic approach would come up with the same result. I intended to do a comparative analysis of my results and the ones on wikipedia but it didn't make it into the final cut

  • @MrZhootSe
    @MrZhootSe Před rokem +4

    Now the question is... Will it fit through the door? XD

  • @emilsitell5484
    @emilsitell5484 Před rokem

    Super interesting video and good explanations!

  • @felixkuper1344
    @felixkuper1344 Před rokem

    What a great video, love the idea!

  • @WhiteThumbs
    @WhiteThumbs Před rokem

    This was very cool, you are a champion.

  • @cliptracer8980
    @cliptracer8980 Před rokem

    I of course have my couch vertical on its side and so it can fit through most places. Even though is huge.

  • @oliverdowning1543
    @oliverdowning1543 Před rokem

    I mean they basically got to the same place we did so that's good.

  • @legotechnic27
    @legotechnic27 Před rokem +1

    Very cool concept! Would've been nice to see what would happen in a variety of different terrain constraints though

    • @uselessgamedev
      @uselessgamedev  Před rokem +2

      Do you have some in mind? I thought about trying a curved path, and other stuff but I figured the shape would simply end up being a circle

    • @legotechnic27
      @legotechnic27 Před rokem +1

      @@uselessgamedev That's fair... I did not think things through too much haha. I was thinking maybe just something designed as a room with other interior, and seeing it maneuver around that.

    • @uselessgamedev
      @uselessgamedev  Před rokem +3

      @@legotechnic27 hmm interesting. Like with obstacles and stuff. Thanks I'll think about it. Might revisit this topic on day

  • @BarcelonaMove
    @BarcelonaMove Před rokem

    Hi Leonard, I hope you have got your sofa inside and the algorithm blesses you with good engagement.

  • @dumbidiot1119
    @dumbidiot1119 Před rokem +4

    Found my new favorite channel! This is the kind of stuff I find super interesting

    • @uselessgamedev
      @uselessgamedev  Před rokem +2

      I'm glad you like it, it's maybe my favorite video of the channel

  • @Staoy
    @Staoy Před 6 měsíci

    Wow, I think if we extend the same question into three-dimensional space, the largest single body that can pass through an actual continuous reverse 90-degree angle pipe is, well, a monomer similar to a peanut or gourd.

    • @uselessgamedev
      @uselessgamedev  Před 6 měsíci

      Interesting, for a pipe the gourd hypothesis is probably the right guess, but for a truly 3D setup I guess it's not even a pipe it's more like a... the corner of a small cube hovering inside a larger cube. And since there's one more way of turning the object it probably yields very different objects.
      Ugh this is too much 3D visualization for my small brain cells :O

    • @Staoy
      @Staoy Před 5 měsíci

      yeh, really interesting and I feel it be more difficult after seeing your reply haha.@@uselessgamedev

  • @legendaryspud3462
    @legendaryspud3462 Před rokem +3

    Turn the couch sideways.

  • @jweare333
    @jweare333 Před 2 měsíci

    Great video!

  • @ganugget6834
    @ganugget6834 Před 10 měsíci

    Hold on, the second turn could be fixed by just flipping the couch over and carrying it through

  • @paraxion
    @paraxion Před rokem

    I feel like it would've been interesting to boost the final score based on things like symmetry and number of straight lines - although I guess maximizing area does the same trick?

    • @uselessgamedev
      @uselessgamedev  Před rokem +1

      Interesting suggestion. I was going for a more "free reigns" approach letting the algorithm do its thing and see what it comes up with (which is pretty close to the current conjecture on wikipedia) but I guess I could add more constraints to it. I doubt it would change the final result much but it would certainly improve the time it takes to converge to the solution

  • @bastienpabiot3678
    @bastienpabiot3678 Před rokem

    A lot of couches will fit about any corner if you move them standing up
    You just need strong friends

  • @theworm7156
    @theworm7156 Před rokem

    6:47 it also makes more sense as a couch

  • @JanTuts
    @JanTuts Před rokem

    7:10 "the best couch of each generation sofa(r)"

  • @JanTuts
    @JanTuts Před rokem

    0:38 "Pivot! Pivot!"

  • @FlowerBot
    @FlowerBot Před 5 měsíci

    stand it up, that way the couch can be as long as the corridor is tall

  • @Shayzis
    @Shayzis Před rokem +1

    Turn the sofa on its side, boom, problem solved

  • @zagmodell
    @zagmodell Před rokem +1

    this is genious

  • @aiayou
    @aiayou Před rokem

    Now do it in 3D! Should be easy to adapt, right? Right?

  • @wadecodez
    @wadecodez Před rokem +1

    slight problem my apartment has stairs which are smaller than the doorway

    • @uselessgamedev
      @uselessgamedev  Před rokem

      I feel you, in my actual apartment the couch ended up getting in through the window haha

  • @alirezafarzaneh2539
    @alirezafarzaneh2539 Před rokem

    Clever! :)

  • @RubenGoMoRadioboyPlus
    @RubenGoMoRadioboyPlus Před rokem +2

    I love it

  • @NocturnalWisp
    @NocturnalWisp Před rokem +1

    Yo! Nice idea for a video. I think it looks like a brush lol. btw do you have a way to contact you directly?

    • @uselessgamedev
      @uselessgamedev  Před rokem +3

      Thanks! The goal was to make the second one as ugly as it is impractical. The 3D artist was thrilled.
      To contact me you can write at theuselessgamedev and then @ and then gmail.com (don't forget the "the")

    • @NocturnalWisp
      @NocturnalWisp Před rokem

      @@uselessgamedev lol I'm sure they were.

  • @lennarth.6214
    @lennarth.6214 Před rokem

    Hey, I really liked the video and wrote something similar in python. How did you do the movement of the sofa? I can't pay for the source code on your patreon so I'm asking just for a general idea on how to do it.

    • @uselessgamedev
      @uselessgamedev  Před rokem

      It relies on the physics engine of Unity, I just apply a downward and rightward force, as well as a clockwise torque, and Unity does all the work. If you don't have access to a physics engine in Python you might need to make a basic one

    • @lennarth.6214
      @lennarth.6214 Před rokem

      @@uselessgamedev Thanks for the quick response. Isn't it possible for good shapes to get stuck when going back would be necessary?

    • @uselessgamedev
      @uselessgamedev  Před rokem

      Game physics engine are by design flawed, and tons of good shapes get stuck when they reach a tight fit, which ended up lowering the score of the best shape. I guess that's the limitations of this approach. A method that would yield better results would be to check every vertex of the mesh against each walls using a raycast. More compute intensive, less fun to watch in a video.
      Someone on Twitter names @PassionProgr had another different approach that you might want to check out

    • @lennarth.6214
      @lennarth.6214 Před rokem

      @@uselessgamedev Ok, maybe later I will try to write an AI with tensorflow to steer the bots. But till then I am also just applying simple rightward force.

  • @matthewp3497
    @matthewp3497 Před rokem

    or flip the couch upside down in the middle hallway

  • @imagery5425
    @imagery5425 Před rokem

    Have you tried dropping it into your apartment?

  • @rrggss5057
    @rrggss5057 Před rokem +1

    Pivot, pivot!

    • @uselessgamedev
      @uselessgamedev  Před rokem +2

      👆 Me at 3am when watching the first generations of couches

  • @cliptracer8980
    @cliptracer8980 Před rokem

    I predicted that shape though

  • @Hyperboid
    @Hyperboid Před rokem

    never thought i'd hear the phrase "breed the next generation of couches"

    • @uselessgamedev
      @uselessgamedev  Před rokem

      Yeah I love these algorithms that are modeled on something (genetics, quantum physics) but are applied to a completely different field, it gives funny sentences

  • @theworm7156
    @theworm7156 Před rokem

    0:40 PIVOT

  • @arrangemonk
    @arrangemonk Před 6 měsíci

    if its shorter than the corridors heigt it should tir throu no matter the shape

  • @dyscotopia
    @dyscotopia Před rokem

    Couldn't you flip the first couch over to get around the second turn?

  • @maxximumb
    @maxximumb Před rokem

    I have 2 comments. What about the Z axis? And secondly, PIVOT!

  • @ormenachem341
    @ormenachem341 Před rokem

    I think the solution is to get it from ikea

  • @jnbsp3512
    @jnbsp3512 Před rokem

    I know you said couch 9000 times but at 3:03 the only thing my braincell thinks of is US State Shaped Cuttingboards! This shape parameterisation is something I'll rember when generating made up geogpraphy

  • @veradistheeggcat229
    @veradistheeggcat229 Před rokem

    Ikea, mate.

  • @lululegende
    @lululegende Před 11 měsíci

    i really love these kind of vids, also 100th comment lol

    • @uselessgamedev
      @uselessgamedev  Před 11 měsíci

      The 1000th comment wins a mathematically optimized couch

  • @moortezaa3397
    @moortezaa3397 Před rokem

    bruh its a 3d space, just rotate the couch.

  • @zORg_alex
    @zORg_alex Před rokem

    Unsolved? Disassemble the ffffing couch! And put it back together at place. It's not a rocket science.

    • @BryanLu0
      @BryanLu0 Před rokem

      It's unsolved if you aren't allowed to disassemble the couch. Ofc the solution if you are allowed to disassemble the couch is that you can transport ♾️ area