Procedural Modeling Using Graph Grammars

Поделиться
HTML-код
  • Опубликовано: 18 ноя 2024

Комментарии • 67

  • @shiftedclock
    @shiftedclock Год назад +33

    "Babe wake up, new Paul Merrell procedural generation video just dropped."

  • @SergeyLergDev
    @SergeyLergDev 10 месяцев назад +1

    Nice to finally meet you! Great research, thank you.

  • @QanicsP
    @QanicsP 11 месяцев назад +3

    your work is amazing , your results are impressive

  • @HybridLizard_com
    @HybridLizard_com Год назад +1

    Impressive work!

  • @chopsueysensei
    @chopsueysensei Год назад +1

    really inspring stuff!

  • @michaelsipos7448
    @michaelsipos7448 11 месяцев назад +6

    Your method is very ingenious and it definitely seems like it worked out most of the positive/generative part. All that really remains is figuring out how to model the constraints/rules that steer/converge the generative part into something desirable. Keep up the good work! You're definitely on the right track to something incredibly useful!
    In Control Theory there are the dual concepts of Positive and Negative Feedback, all you need is the negative/regulating part.

  • @simulacrumgames
    @simulacrumgames 5 месяцев назад +2

    Insta-sub, thanks for your great work!

  • @htspencer9084
    @htspencer9084 3 месяца назад

    I love that you're using differential geometry to determine which primitives are valid candidates for each other. Takes me back to the turning a sphere inside out days!

    • @PaulMerrellResearch
      @PaulMerrellResearch  3 месяца назад

      Nice, now I'm curious what you mean by turning a sphere inside out?

  • @danieljleslie
    @danieljleslie Год назад +4

    Just remember to use your powers for good instead of evil.

  • @conradsoon7522
    @conradsoon7522 Год назад

    very cool!

  • @marshallross3373
    @marshallross3373 Год назад +2

    This is great stuff. It reminds me loosely of a class I took at UC Berkeley's School of Environmental Design back in the late 1980's taught by Horst Rittel. It was more of a seminar on Design Theory, actually, but not what I was expecting when I signed up. I expected the material to cover famous Architects and their philosophies/theories of designing buildings and so forth. After all, you generally look to the range of historical precedents for inspiration. But, Rittel had a completely unconventional approach (at the time). He described a method for solving design problems through using a "morphological box" that would essentially list all of the various possible design elements in an array of rows stacked vertically. So, one row would list possible floor plans, another would list window styles, another would list roof profiles, etc. Then, the designer would essentially run through and evaluate all possible combinations, discarding the ones that were non-sensical, and grading the ones that could work. Presumably, since all possibilities would be considered, the best options would percolate to the top. At the time, as a student of design, I had a real problem with this approach, not only because it seemed incredibly tedious for all but the simplest of design problems, but also because it ignored artistic inspiration and individual creativity. But, in retrospect, I think Rittel was simply decades ahead of his time. With the power of modern computers, and clever algorithms such as yours, I suspect approaching design in such a way is more practical than ever, even for complicated scenarios. I think the type of automation you are investigating is going to be a game changer in a variety of design fields very soon. Providing mechanisms for a designer to influence the automation, directing it in some manner, seems to be a key element that could make this kind of thing very useful. I'll be honest, I thought Rittel was kind of out of his mind. His approach would be so burdensome to implement on paper for a real-world situation, that I felt a little hostile toward it; I mean, it was almost absurd. Nobody in Architecture would actually work that way. But, now, with the computer at hand to do the heavy lifting sorting through the variations, it makes a lot more sense.

    • @PaulMerrellResearch
      @PaulMerrellResearch  Год назад

      It's interesting to look back at the history of this and see that a lot of important theoretical work was done before it was practical to actually use it. I have another paper that focus specifically on residential architecture and on optimizing those designs: paulmerrell.org/wp-content/uploads/2021/06/floorplan-final.pdf. Certainly, you can see in my work that I agree with the basic philosophy of trying out a huge number of possible combinations. However, I will quibble with the idea of trying "all possible combinations". Even today, this is still impractical for all for most problems. There is a combinatorial explosion in the number of possible combinations for many small problems.

    • @marshallross3373
      @marshallross3373 Год назад

      @@PaulMerrellResearch Awesome. This paper looks really interesting, and certainly useful for the applicability of it for real estate developers and architects, and game developers/film makers, too. You are right about the combinatorial explosion, and of course, one of the reasons one might hire a particular architect is that they have their experience, insights, and taste that cuts through and avoids all the options that aren't "right", and ideally they produce masterpieces with their signature vibe. I remember reading where Frank Lloyd Wright hurriedly sketched out Falling Water in a couple of hours because the client was suddenly in town and wanted to drop by and see the progress; Wright hadn't even started working on it since he was commissioned months earlier. LOL. But, such is the skill of a master who can generate a design in the mind's eye quickly.BTW, how much of your system relates to fractals, if at all? Fractals were a hot topic 25-30 years ago, and maybe they have a renewed practicality here.

    • @PaulMerrellResearch
      @PaulMerrellResearch  Год назад +1

      @marshallross3373 This is closely related to fractals. One of the main features of fractal is that they are self-similar. Grammars are good at producing self-similar shapes. Here's an example where I use my technique to create something similar to a Koch Snowflake: imgur.com/a/opF0iof. And I could probably get it to work on several other fractal patterns.

    • @marshallross3373
      @marshallross3373 Год назад

      @@PaulMerrellResearch Very cool. It is amazing what can be generated from a small set of primitives and grammars. Thanks for sharing your research and explorations. I'll definitely dig deeper on this subject. Really fascinating stuff.

  • @sistemafuturo
    @sistemafuturo 8 месяцев назад

    Beautiful : }

  • @neuralmax5085
    @neuralmax5085 10 месяцев назад +1

    You work is very inspiring! One additional think you could work out in the future is space proportions. Either inside or outside of your generated objects become too thin. For example too narrow spaces between skyscrapers, but there could be example almost in every object you presented. If you could obtain the constrains of minimal space and then generate with them, final results would much more believable. Thank you for your work and this presentation, I hope to use this knowledge in the near future.

    • @PaulMerrellResearch
      @PaulMerrellResearch  10 месяцев назад

      Thanks, yes, I completely agree. The spacing and proportions are really important and certainly this is something that can be improved.

  • @MaximSchoemaker
    @MaximSchoemaker Год назад +2

    Sick!

  • @tenthlegionstudios1343
    @tenthlegionstudios1343 Год назад +5

    This is awesome! I am curious how this compares to the 3d performance of the model synthesis algorithm (I think this was NP hard and required back tracking), and if you could compare the two algorithms and the models they can create. A lot of this still goes over my head - but I still find this fascinating for game dev. Thanks for the content!

    • @PaulMerrellResearch
      @PaulMerrellResearch  Год назад +5

      @tenthlegionstudios1343 The main difference is that model synthesis uses tiles on a grid while my new method is not tied to a grid. Model synthesis kind of looks like a video game where everything is tiled. But the real world is mostly not on a grid and my new method can create more natural objects. However if you are dealing with tiled objects, model synthesis has some advantages.
      Also, my new method works by making small incremental changes. Each time we apply a rule we make another incremental change and produce another valid shape. But model synthesis works by trying to fill a large space without running into any contradictions. The problem is NP-hard and when you make a mistake you may have to backtrack quite a bit. In my new method you can also run into contradictions, but just within one incremental step. You may have edges that intersect. And actually it has been shown that deciding if a graph can be drawn without self-intersection is an NP-hard problem. But this is much less of a problem because we are making small incremental changes. If we have any difficulty applying a rule we can discard it and try another one. So we don't need to backtrack very far.

  • @Gnomable
    @Gnomable Год назад

    This is so cool! I'd heard of WFC before and it's cool to see a more robust method. Looking forward to more video about this.

  • @kaishang6406
    @kaishang6406 Год назад

    this is amazing

  • @Aleamanic
    @Aleamanic 7 месяцев назад

    One even could say, that C. Alexander pioneered the concept of "generative grammar" in relation to architectural/geographic auto-modeling, which the methods you describe elaborate further...

  • @Aleamanic
    @Aleamanic 7 месяцев назад

    It makes sense to call it "grammar". It is common to speak of design "language", or per Christoph Alexander "Pattern Language" related to Architecture. Makes perfect sense to me to invoke "grammar" to refer to the underlying combinatorial logic.

    • @ItsJustAstronomical
      @ItsJustAstronomical 7 месяцев назад +1

      That's an interesting thought to tie it to Alexander's Pattern Language, but the term "grammar" originated from Chomsky's hierarchy of formal grammars. Chomsky was a linguist and was thinking about this in the context of noun phrases and verb phrases. Most computer scientists are familiar with regular, context-free, and context sensitive grammars. Graph grammars were invented in the late 60s, so I believe this was independent of Alexander's pioneering work.

  • @ironmaiden12369
    @ironmaiden12369 Год назад +1

    Im SO excited to see you upload! I gotta turn that notification bell on.
    Keep up the good work mate :)

  • @ValerioBelcamino-m5j
    @ValerioBelcamino-m5j 2 месяца назад +1

    in the 3d model case, how do you decide where to cut the model to generate the primitives? both in terms of position, orientation and scale. In the example at 15:38 there seems the choice seem to follow a grid

    • @PaulMerrellResearch
      @PaulMerrellResearch  2 месяца назад

      @ValerioBelcamino-m5j Every edge is cut in half (see 6:49). While many of the examples look like they're on a grid, this was just done for simplicity. This method works fine for shapes at any angles. You asked about the position, orientation, and scale. The edges can stretch to any length (see 3:34) and the primitives can go in any position. So the position and scale of the cut is irrelevant. The orientation matters for determine the edge label (see 4:29).

  • @khoavo5758
    @khoavo5758 6 месяцев назад

    how did you manage to do so much visuals? It’s incredible.

    • @PaulMerrellResearch
      @PaulMerrellResearch  6 месяцев назад

      Thanks! It took a lot of work. Hopefully you were able to follow from the video how I made the shapes, but I also applied a lot of textures and decorations to the edges, etc. and then rendered the 3D shapes in 3DS Max. I have some more results and will be making some more videos soon.

    • @khoavo5758
      @khoavo5758 6 месяцев назад

      @@PaulMerrellResearch Oh, no I don't really understand your research :). I actually meant the visualization of concepts, f.ex at 9:24, 10:27, etc.
      Seems like every single sentence is animated, and the animation syncs up really well with what you're saying.
      Must be an insane amount of work to do that in something like PowerPoint.

    • @PaulMerrellResearch
      @PaulMerrellResearch  6 месяцев назад

      Oh, yes that also took a good amount of work. You couldn't do something like this in PowerPoint. I recorded all the audio and then animated it so it matched the audio. For someone who does a lot of 3D animation it's not difficult, but definitely more advanced than PowerPoint.

  • @imani-games
    @imani-games 4 месяца назад

    Should put the enterprise into this to generate new starships!

  • @julius9055
    @julius9055 Год назад +5

    Really interesting, and I'm very pleased to know that your work on this is ongoing. I recently implemented a version of wave function collapse for a game I'm working on. Along the way, I discovered model synthesis. It's my understanding that model synthesis is more attuned to 3d generation and I switched to something more like that in my approach, since I was working in 3d.
    Since then I haven't done much on the project, but this video has reinvigorated my interest and I'm looking forward to implementing this new iteration. the main stumbling block for my work was the time taken for the generation. I was wondering if you had any insight into this aspect, in particular in cases with large tilesets (or many 'primitives' as I understand in the new version). I looked briefly into parallel implementations as well and was wondering if this was something you'd considered as well.
    Keep up the great work, I'd be interested in a closer look at how you used graph theory and category theory in your work too, in case you're looking for video ideas :D

    • @PaulMerrellResearch
      @PaulMerrellResearch  Год назад +1

      @julius9055 Can you tell me a little more about the tilesets where the generation is taking a long time? I've looked at many tilesets and they seem to work reasonably fast, although I haven't done exhaustive tests and for some real-time applications it might be slow. The Escheresque tileset is one of my more complicated ones with 100+ different tiles. And I can 100 x 100 x 10 = 100,000 voxel output in a few minutes.
      Is the problem related to having to it failing and restarting often? If you're not using my strategy of modifying the output in parts, you would have that problem. That was part of the original Model Synthesis Paper. For some reason it was not copied into the Wave Function Collapse code.
      I'm hoping to make more videos on lots of related topics, but I don't know you'll be seeing me dig into category theory too much. Honestly, I could use some good videos explaining that stuff to me. I find it confusing and I don't think it's terribly necessary for understanding my work.

    • @julius9055
      @julius9055 Год назад

      @PaulMerrellResearch thanks for the response. To be honest, I'd need to look back into it since it's been a few months. From my recollection though, my method was already a simplified version of your work and I'm sure I've missed some of the speed improvements that you've employed. I know for a fact that I haven't implemented a version of the modifying of the output in parts so that'll be the first port of call when I start work on this again.

  • @SneaK1ng
    @SneaK1ng Год назад +2

    很棒的算法!

  • @Ugu427
    @Ugu427 Год назад

    Amazing work !

  • @Ykulvaarlck
    @Ykulvaarlck Год назад +2

    is it possible to adjust the primitive cutting step to control the "granularity" of the analysis of the input?

    • @ItsJustAstronomical
      @ItsJustAstronomical Год назад +1

      Yes, absolutely, you can control the granularity. Remember the part where you can fill in the faces with different colors. You can do the exact same thing with the edges. You can assign different colors. This gives you a lot of control over how the primitives can be glued together. You can force certain primitives to be glued together meaning the final shape will consists of larger, more granular pieces.

    • @PaulMerrellResearch
      @PaulMerrellResearch  Год назад +1

      Oh and @@ItsJustAstronomical is also me. It's my other account. Sometimes I forget to switch them.

  • @lmthelex
    @lmthelex 2 месяца назад

    WAO

  • @chloesun1873
    @chloesun1873 2 месяца назад +1

    Have you thought of turning this into a product like City Engine by Pascal Mueller?

    • @PaulMerrellResearch
      @PaulMerrellResearch  2 месяца назад

      @chloesun1873 I have thought about it. I would need a team of people to help me out and I haven't found that yet.

    • @chloesun1873
      @chloesun1873 2 месяца назад

      @@PaulMerrellResearch I'm quite interested in turning this into a MVP in my free time...

  • @dmyyy
    @dmyyy Год назад

    Super interesting! I've read through a lot of your work on model synthesis (and implemented something similar myself but found creating matching components in 3d was not easy at all), was just wondering about the performance characteristics of the algorithm for 3d. Is this something you see being used during runtime? Or a time-saving step when doing modeling? How does it compare to model synthesis?

    • @PaulMerrellResearch
      @PaulMerrellResearch  Год назад

      The 3D shapes shown took about 1 - 1.5 minutes to generate. Whether that's fast enough depends on the application. It's fine if you just need to build a virtual world once and then you spend lots of time exploring it. I'm sure the performance can be improved. It shouldn't be difficult to parallelize it. You could have multiple processes applying rules, you would just need to make sure they apply to different parts of the shape and don't interfere with one another.
      Model Synthesis requires the input shape to be made up of tiles that neatly fit on a grid, requiring it to be rectilinear in some sense. The new approach doesn't use tiles at all. It can handles meshes at any angles. It can create curved organic shapes.

  • @BallisticLife
    @BallisticLife Год назад

    This is fantastic!
    I wonder if there's a way to get around the issue of edges getting unnaturally long in the output. My instinct is to put some sort of length constraint on edges, but the edges are lost in the reconstruction process. Maybe you could tag edges in the input, and match those tags in the output using the angle/adjacent region info. I wonder about multi-stage generation (eg. marking edges as possible spots for windows/doors) or the ability to mark a region with a minimum area constraint.

    • @PaulMerrellResearch
      @PaulMerrellResearch  Год назад

      There actually is an constraint on the edge lengths. They have a minimum and maximum length. Although I may not have set it correctly everywhere. It is necessary to do something like this. The alternative would be to look the right edge lengths from training data, but the whole point is to not require the user to provide a lot of training data.
      A multi-stage generation is certainly an interesting possibility.

  • @thegoldenatlas753
    @thegoldenatlas753 10 месяцев назад

    Question, i see alot of this being applied to map creation but could you apply it to things like enemy creation, character creation, etc How granular of an application space does it have? How much would it have to be changed to work in applications outside of map/level creation?

    • @PaulMerrellResearch
      @PaulMerrellResearch  10 месяцев назад

      The idea is built around the concept of geometric similarity. Basically, this can work on any shapes that are self-similar: building, trees, flowers, terrain, space stations, factories, etc. All the things that procedural modeling works on right now. It doesn't matter how big or small the objects are. But I don't know that it would be good for characters as they aren't really self-similar.

    • @thegoldenatlas753
      @thegoldenatlas753 10 месяцев назад

      @@PaulMerrellResearch So its good for things i can break down to more arbitrary shapes?

    • @PaulMerrellResearch
      @PaulMerrellResearch  10 месяцев назад

      ​@@thegoldenatlas753I'm not sure what you mean by break down to more arbitrary shapes. It's good for objects that a self-similar meaning they contain repeated patterns. A fractal pattern is the ultimate example of this. A tree is also a good example. It repeats the same leaf patterns and the same branch pattern over and over.

    • @thegoldenatlas753
      @thegoldenatlas753 10 месяцев назад

      @@PaulMerrellResearch ahhhh ok that makes sense. Im definitely still curious what i could make with this so im gonna explore implementing it into Rust/Bevy to see what it can do in 3D.
      This honestly reminds me of how AI is but feels like the formalized math that an AI would be trying to approximate, which is genuinely amazing. Im very glad i found this even.

  • @bulalaish
    @bulalaish Год назад

    here: future matrix architect

  • @curiousantics2097
    @curiousantics2097 9 месяцев назад

    Do you have a discord channel?

    • @ItsJustAstronomical
      @ItsJustAstronomical 9 месяцев назад

      No, should I get on discord?

    • @curiousantics2097
      @curiousantics2097 9 месяцев назад

      ​@@ItsJustAstronomical Absolutely! It's where most developers I know are and it's a good place for your community to interact. Think skype meets forums.

  • @starplatinum3305
    @starplatinum3305 9 месяцев назад

    Why bro sound like 3blue1brown lmao 😮

  • @i-make-robots
    @i-make-robots Год назад

    graph grammars for neural networks. lol