OpenCL Wrangle COP: Image Manipulation on the GPU using OpenCL

   6362   14   2
User Avatar
Member
4495 posts
Joined: Feb. 2012
Offline
This operator allows you to run an OpenCL kernel as part of your COP network. Depending on the GPU, some operators can be orders of magnitude faster than even VEX.

In this case OpenCL is 192 times faster than VEX on GTX 970. Please note that the actual cooking time for the VEX node is much longer (~77s for 100 iterations vs 40s for 10000 iterations) than what the status bar is showing. The cooking timer is shown long after I set iterations to 100 as can be seen in the video.

Edited by animatrix_ - June 28, 2017 02:44:58
Senior FX TD @ Industrial Light & Magic
Get to the NEXT level in Houdini & VEX with Pragmatic VEX! [www.pragmatic-vfx.com]

youtube.com/@pragmaticvfx | patreon.com/animatrix | animatrix2k7.gumroad.com
User Avatar
Member
181 posts
Joined: Feb. 2013
Offline
Looks impressive. I look forward to how steps like this might lead to a more robust compositing system that approaches realtime rendering performance.
User Avatar
Member
4495 posts
Joined: Feb. 2012
Offline
Thanks, I sent many RFEs regarding COPs also. Things like multi-threaded COPs cooking, multi-threaded thumbnail generation like Nuke, GPU cooking support (the default GPU option is not working, bugs submitted), ability to write pixel shader filters and more. As always SESI knows best

If you want to RFE OpenCL COP, the ID you can reference is 83299.
Senior FX TD @ Industrial Light & Magic
Get to the NEXT level in Houdini & VEX with Pragmatic VEX! [www.pragmatic-vfx.com]

youtube.com/@pragmaticvfx | patreon.com/animatrix | animatrix2k7.gumroad.com
User Avatar
Staff
5156 posts
Joined: July 2005
Offline
COPs has had multithreaded cooking since its debut. Also, in COPs' case, VEX is more of a flexibility feature, not a performance one. If you want to write fast image operations, VEX is not the way to go.
User Avatar
Member
4495 posts
Joined: Feb. 2012
Offline
Thanks Mark, I worded it poorly I think. I meant multi-threaded cooking i.e. many independent COPs cooking at the same time and gathering the results in the end if they are merged together.

Not sure if this is as practical in COPs as they are in SOPs, since as you also said COPs cook multi-threaded, so there might not be a need to cook multiple COP chains at the same time.

Also multi-threaded UI so Houdini is always responsive but I think that's a global Houdini issue not a COP one.
Senior FX TD @ Industrial Light & Magic
Get to the NEXT level in Houdini & VEX with Pragmatic VEX! [www.pragmatic-vfx.com]

youtube.com/@pragmaticvfx | patreon.com/animatrix | animatrix2k7.gumroad.com
User Avatar
Staff
5156 posts
Joined: July 2005
Offline
That's what the COPs engine does. It can put all threads on 1 COP if it's the bottleneck, or spread them out over a bunch of COPs if there is a large tree with independent branches, or end up somewhere in between. It can also cook multiple frames in a single cook in order to better saturate the cores during a cook (parm on the composite ROP). Thumbnails don't have as much opportunity for concurrency due to the small image size, which is why I always turn them off.
User Avatar
Member
4495 posts
Joined: Feb. 2012
Offline
Thanks Mark for clearing this up. Now if only Houdini GUI was muli-threaded we could really see how good COPs are.
Senior FX TD @ Industrial Light & Magic
Get to the NEXT level in Houdini & VEX with Pragmatic VEX! [www.pragmatic-vfx.com]

youtube.com/@pragmaticvfx | patreon.com/animatrix | animatrix2k7.gumroad.com
User Avatar
Member
459 posts
Joined: Oct. 2011
Offline
@pusat Your signature tiny.cc url redirects to passion.com
http://www.racecar.no [www.racecar.no]
User Avatar
Member
4495 posts
Joined: Feb. 2012
Offline
Thanks a lot man, I updated it. The url redirect services can't be trusted it seems
Senior FX TD @ Industrial Light & Magic
Get to the NEXT level in Houdini & VEX with Pragmatic VEX! [www.pragmatic-vfx.com]

youtube.com/@pragmaticvfx | patreon.com/animatrix | animatrix2k7.gumroad.com
User Avatar
Member
4495 posts
Joined: Feb. 2012
Offline
Btw I posted the HDA in the description if you want to download it.
Senior FX TD @ Industrial Light & Magic
Get to the NEXT level in Houdini & VEX with Pragmatic VEX! [www.pragmatic-vfx.com]

youtube.com/@pragmaticvfx | patreon.com/animatrix | animatrix2k7.gumroad.com
User Avatar
Member
72 posts
Joined: July 2011
Offline
Thanks Animatrix for sharing all of this info and probing the point such strongly.

On the other side, here we are, year 2022, H19.5 but still no gpu COPS or COP opencl node from sidefx.


I don't really understand why this has never been implemented. What could be the reason for not doing so?
User Avatar
Member
4495 posts
Joined: Feb. 2012
Offline
Thanks a lot Andreu, really appreciate it It could be combination of user demand and how much effort SESI needs to spend vs how much resources they have and how much they need it themselves to enable a new feature. When it's the latter, I noticed they add whatever they need very fast, for example the ol' Loop COP and OpenCL SOP that enabled many other nodes like Attribute Blur SOP, HF Erode SOP, etc.

For example C++ Wrangle SOP was discussed before and one of the SESI devs even made his own version that has more features (super smart guy, check out his github):
https://github.com/lecopivo/cpp-wrangle [github.com]

But the difficulty of shipping compilers vs how many people need this feature, it wasn't deemed as a popular feature. Feel free to send an RFE though please

Most of the performance optimization requests I sent with faster implementations were fixed quickly. For larger features, they implemented these based on my observations:

I made OpenCL Wrangle SOP and SESI added OpenCL SOP:


I made OpenCL Smooth SOP and SESI added Attribute Blur SOP that's also OpenCL based:


I made Falloff SOP for computing geodesic distance and SESI added their own Falloff SOP, later replaced these with Distance Along/From SOPs:


Now they even added Heat Geodesic SOP in H19.5 which is one of my fav nodes:
https://www.sidefx.com/docs/houdini/nodes/sop/heatgeodesic.html [www.sidefx.com]

I made Curve Gradient SOP and SESI added Edge Transport SOP:


I made Edge Wrangle SOP and SESI added half edges:


I made Principal Component Analysis SOP & DOP Microsolver and SESI added svddecomp VEX function:



I am not claiming they did it based on my implementation or because I did it first, could be a coincidence. I am just happy to see these additions. All credits to SESI

Still waiting for Supercharged extension style overlay network editor (as an option), and context-sensitive rule-based hotkey system, OpenCL-based volume SOPs for operations like Volume Blur, Volume Convolution, etc, OpenCL COPs with a new COP system implemented using 2d volumes, C++ Wrangle SOP, Poly Carve SOP, OpenSubdiv Subdivide SOP that properly stitches adjacent primitives when using sub-geometry, multi-threaded GUI, etc.

The more people sent RFEs for these, the higher they bump up the priority in their database. So it would help a lot if you send a few RFEs from your work email so they can see the need from a studio rather than an individual IMO.

As always SESI knows best :P
Senior FX TD @ Industrial Light & Magic
Get to the NEXT level in Houdini & VEX with Pragmatic VEX! [www.pragmatic-vfx.com]

youtube.com/@pragmaticvfx | patreon.com/animatrix | animatrix2k7.gumroad.com
User Avatar
Member
900 posts
Joined: Feb. 2016
Offline
That's weird, I don't see any Heat Geodesic SOP in my 19.5 installation. I have Labs installed too.
User Avatar
Member
4495 posts
Joined: Feb. 2012
Offline
That's strange it's visible in my build:



https://www.sidefx.com/docs/houdini/nodes/sop/heatgeodesic.html [www.sidefx.com]
Senior FX TD @ Industrial Light & Magic
Get to the NEXT level in Houdini & VEX with Pragmatic VEX! [www.pragmatic-vfx.com]

youtube.com/@pragmaticvfx | patreon.com/animatrix | animatrix2k7.gumroad.com
User Avatar
Member
900 posts
Joined: Feb. 2016
Offline
thanks, now I see it, after I updated to the last .403 production build
  • Quick Links