Log into your account to keep track of your progress. You can work through the lessons without logging in but your progress will be lost when you refresh the page.

TOTAL DURATION: 59m 10s

To manage pipeline workflows, you can turn to Task Operators (TOPs) which are built using a technology called the Procedural Dependency Graph (PDG). Workflows created using PDG use TOP nodes that generate work items that distribute tasks to either your local computer or a larger compute farm.

In this lesson, you will use TOP nodes to take a city map, create buildings for each city block and then grow this system to handle more complex buildings and larger city maps. Houdini artists will probably know how to do this in SOPs, but by using TOPs, you can learn the PDG workflow while creating a system that can be easily scaled to distribute multiple tasks to an external compute farm to process in parallel.

The complete Houdini Foundations for Houdini 19.5 is also available as Downloadable PDF and a Print-on-Demand book through the Lulu Ebook company. This 224 page book contains 9 chapters designed to help artists take their first steps into Houdini.

Research for this lesson by Michael Buckley

A quick overview of all the different parts of the lesson. Take a look at where you are headed with this lesson.
To build a procedural city, you will start with a city grid. You are going to create the geometry by tracing an image file that includes a black and white image of a city map. This will be the input geometry for the network you will be building in TOPs.
Now that you have a city grid, you can break out the different city blocks into separate work items. That will allow you to use each block to generate buildings. You will set up a TOP network to save out each of the blocks. At the same time, you will create an object for visualizing selected work items to verify that you are getting the results you want.
To create buildings, you want to set a fixed base height and a random height variation so that your buildings are not all the same size. You could set up these attributes at the geometry level of the city map but you can also assign them here in TOPs. This will make it easier to make changes at the TOP level if needed down the line.
You are now going to use a ROP Geometry node to create a simple building. To see what you are doing in the viewport, you need to generate the work items and select one of them. You can then use that work item to design the building at the geometry level.
Once the buildings have been completed, you will want to bring them back together to create the city. This involves a partition node called Wait for All and a Geometry Import. You will also add in a city core where the buildings will be taller than elsewhere in the city.
Up until now the building heights are determined by the randomness of the height_variation. If there is one building that you want to fix to a certain height, a second attribute create node can be used to choose a primitive and set specific values. This makes it easier to art direct a system when you want to override the randomness.
In order to wedge the position of the sphere within the street_grid object, the network will need to be turned into a Houdini Digital Asset [HDA] and run through an HDA Processor TOP node. The ability to load these assets and add them to the system lets you create a complex system out of discreet tools that can be updated and adapted as needed.
To create context for the buildings, you will now create city blocks and streets to use in the final rendering. While the four wedges currently all use the same map, you will set up this geometry in TOPs to allow for the use of different maps down the line. It is always a good idea to build in flexibility to create the most robust system.
Let’s add one extra variable into the wedging. You are going to access four different maps and create one rendering for each one of them. Each of the different black and while images will be traced and used to feed the system. This shows another way to add more content into the pipeline.
Now you are going to add a camera and a skylight then render out the cities. The resulting images will then be combined into a single mosaic with the wedge attributes on display so that creative decisions can be made based on the results. The mosaic node will use the Image Magick application which needs to be installed on your computer for these steps to work.
In the beginning you pointed out that this city building example could probably be created in SOPs without too much difficulty. The issue is that as the system gets more complex there is a bottleneck since all the processing happens within a single network. With TOPs, you can distribute work items to a compute farm and as you scale up things don’t have to slow down.

CREATED BY

rmagee
ROBERT MAGEE

Robert Magee is a Senior Product Marketing Manager at SideFX who has been working with Houdini for 20 years. He has created lots of learning material and demos designed to help artists understand how going procedural with Houdini can benefit their work.

More from Robert Magee

COMMENTS

  • TwinSnakes007 1 year, 11 months ago  | 

    This level of detail is much appreciated- into the black box of pdg/tops. The sops synergy is an added bonus of even procedural options into existing sops workflows.

    SideFX has been killing it with these last series of tutorials that have come out - with PDF’s too boot!

    • j00ey 1 year, 11 months ago  | 

      Thank you for this, it's very useful.

      One question - On my machine when I use the service cook-type, it runs through all the work items very quickly - except for 3, and which 3 varies. Does that ring any bells?

      • DennisSmolek 1 year, 6 months ago  | 

        Did you ever resolve this?
        When I use "Out of Process" it runs 4 at a time ina pretty slow but steady pace.
        When I use the service it blazes through what looks like 10 at a time but then gets stuck on 6 and spins seemingly forever...

      • Quelltroi 1 year, 11 months ago  | 

        Beautifully-designed pdf/book that reeks with vigor and a magnetic freshness.

        • chavinskyblahblah 1 year, 10 months ago  | 

          the ImageMagick node are not work it gave me this ERROR: Could not find the ImageMagick executable

          • kenchen19 1 year, 10 months ago  | 

            Hello, but I did not find the GeometryFile file referenced in the second tutorial in tops_lesson_start_geo.

            • Kokesh 1 year, 9 months ago  | 

              Yes, my "geo" file is empty too. Tried to download repatedly but with the same result. Any idea?

              • Kokesh 1 year, 9 months ago  | 

                Problem solved -> I saved the project in a different file than the original lesson. So I found the new "geo" file in the new one I made.

              • vinyvince 1 year, 10 months ago  | 

                Thanks, it's cool but i feel it's very similar tutorial has already been published. I would like more advanced than redundant basic content, like the machien learning tutorial posted few year agos which some parts were also skipped

                • cliffordart3d 1 year, 5 months ago  | 

                  Would love to follow this one along but it looks like the geo folder provided is empty

                  • rmagee 1 year, 5 months ago  | 

                    All the geometry is generated during the lesson - there are four images of street grids that you will use to generate the city blocks and then the buildings themselves.

                  • buse.duz 1 year, 5 months ago  | 

                    the ImageMagick node are not work it gave me this ERROR: Could not find the ImageMagick executable, i am getting the same error any reaason it could be that?

                    • derekthegood1 1 year, 5 months ago  | 

                      I really appreciate all the exercise. Everything works except for the imagemagick node. I too, get an error:
                      [22:44:58.723] Running with PID 42472
                      [22:44:58.724] ERROR: Could not find the ImageMagick executable

                      Using what I learned thus mar, I LMB clicked and confirmed that all input files were being generated, but the output file is missing.
                      $HIP/images/city_01.imagemagick1.0.png

                      The expected output says it should be
                      I:/Houdini/tops_lesson_start/images/city_01.imagemagick1.0.png

                      My guess is that since all 4 files are being generated with the correct text overlay, there must be some issue with the node execution

                      • hitariq 1 year, 3 months ago  | 

                        Thank you so much for the lesson, however I am a stuck at the second video where you use the file node to enter '@pdg_output'. That is not working for me.

                        • mattiacon92 1 year, 3 months ago  | 

                          Hi, did you manage to sort this out? I am having the same issue. Trying to understand whether that's happening because I am using the Apprentice version.

                          • HArrCorr 1 year, 2 months ago  | 

                            i think you have the wrong symbol. try grave accent `@pdg_output`

                            • heidi-ya 1 year ago  | 

                              I'have same question!!Can l ask you how fix this question?although I write `@pdg_output` that doesn't work

                              • newkinostudio 1 year ago  | 

                                yeah I'm not sure if it's a backslash as he says in the tutorial.

                                • newkinostudio 1 year ago  | 

                                  just tested `@pdg_output` and it worked!

                            • a_p_92 8 months, 1 week ago  | 

                              My Geo File isnt inside the Folder!
                              pls Solve my Prob would be nice that i can take next steps

                            • Ela_Eichu 10 months, 2 weeks ago  | 

                              Hi unfortunately the incoming file node in the build_streets network doesn't work for me (Part 8). I get :

                              Error
                              Please specify a geometry file.
                              Warning
                              Local variable 'pdg_input' not found.

                              I tried both 'pdg_input' as on the videos and 'pdg_output' as on the PDF and none gives me results. The city disappears.

                              • mtea9152 9 months, 2 weeks ago  | 

                                Be careful as the symbols ' and ` are different.
                                I often make mistakes and get warned.

                                • mtea9152 9 months, 1 week ago  | 

                                  I had trouble installing "Image Magick".
                                  I have little experience with command line operations.
                                  I don't know the "$PATH" setting.
                                  The path was directly specified in "ImageMagick Node".

                                Please log in to leave a comment.