# Pybox Nuke

**URL:** <https://forum.logik.tv/t/pybox-nuke/4091>\
**Category:** Flame Questions\
**Created:** [October 19, 2021, 8:01am UTC](https://forum.logik.tv/t/pybox-nuke/4091 "2021-10-19T08:01:06Z")\
**Posts on this page:** 20\
**Page:** 1

<div class="post-metadata">

**Author:** ![johnt](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/johnt/32/14040_2.png) [@johnt](https://forum.logik.tv/u/johnt)\
**Post date:** [October 19, 2021, 8:01am UTC](https://forum.logik.tv/t/pybox-nuke/4091/1 "2021-10-19T08:01:06Z")

</div>

Can anyone spare two minutes to write an idiot’s guide to pybox nuke?

I remember getting somewhere with it but I’ve completely forgotten.

All out nuke scripts and renders are kept on a local server. Can these still be used?

---

<div class="post-metadata">

**Author:** ![andymilkis](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/andymilkis/32/11067_2.png) [@andymilkis](https://forum.logik.tv/u/andymilkis)\
**Post date:** [October 19, 2021, 10:42am UTC](https://forum.logik.tv/t/pybox-nuke/4091/2 "2021-10-19T10:42:00Z")

</div>

Hey John,

All I’ve done with Pybox & Nuke was pass images in and get the render back. I haven’t done anything with exposing the controls of Nuke nodes in Flame yet.

Would they still be of help?

---

<div class="post-metadata">

**Author:** ![johnt](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/johnt/32/14040_2.png) [@johnt](https://forum.logik.tv/u/johnt)\
**Post date:** [October 19, 2021, 11:33am UTC](https://forum.logik.tv/t/pybox-nuke/4091/3 "2021-10-19T11:33:21Z")

</div>

Absolutely - all I need to do is run something through an existing setup and am being lazy by not wanting to boot up nuke.

---

<div class="post-metadata">

**Author:** ![andymilkis](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/andymilkis/32/11067_2.png) [@andymilkis](https://forum.logik.tv/u/andymilkis)\
**Post date:** [October 19, 2021, 4:13pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/4 "2021-10-19T16:13:22Z")

</div>

No problem. You should be able to take care of it in four steps:

1. Put the path to your Nuke install in the Handler file:  

2. Modify your nuke script to have the appropriate Read and Write nodes (they need to be named like this)  

3. Drag a Pybox node into Batch and load the Nuke\_px handler  

4. Load the Nuke script and you should be good to go.  

Full disclosure this can be A LOT slower than just launching Nuke. It basically calls a command line render for each frame. I had a comp that took 5 mins in Nuke and 40 mins in Flame via PyBox on the same machine. But, if you’re dealing with someone who doesn’t know Nuke, etc, it’s seamless.

---

<div class="post-metadata">

**Author:** ![johnt](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/johnt/32/14040_2.png) [@johnt](https://forum.logik.tv/u/johnt)\
**Post date:** [October 19, 2021, 4:17pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/5 "2021-10-19T16:17:21Z")

</div>

So every time you want to do this, you have to edit the .py file?

Also your full disclosure is very informative - it seems pretty unattractive in light of this.

---

<div class="post-metadata">

**Author:** ![andymilkis](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/andymilkis/32/11067_2.png) [@andymilkis](https://forum.logik.tv/u/andymilkis)\
**Post date:** [October 19, 2021, 4:19pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/6 "2021-10-19T16:19:46Z")

</div>

No, you only have to do that edit to the .py file once. Once the path is declared then you are good to go. PyBox really seems like a viable option if you’re trying to integrate something that cannot be done in Flame, or if you have a tool that can only be done in Nuke but you want to expose it to Flame artists. I’ve been building bespoke tools with Nuke Copycat and making them available to our Flame artists who don’t know Nuke. The major caveat with that is to treat it like something that you need to pre-render instead of keeping it live in your Batch comp.

---

<div class="post-metadata">

**Author:** ![johnt](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/johnt/32/14040_2.png) [@johnt](https://forum.logik.tv/u/johnt)\
**Post date:** [October 19, 2021, 4:22pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/7 "2021-10-19T16:22:35Z")

</div>

Sorry - what I meant was you need to edit the .py for each new comp it seems since all out comps are stored on a server in shot folders within jobs. It just seems easier to open up nuke. I don’t really like using nuke much - it feels very awkward but it’s easier than editing a text file.

---

<div class="post-metadata">

**Author:** ![andymilkis](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/andymilkis/32/11067_2.png) [@andymilkis](https://forum.logik.tv/u/andymilkis)\
**Post date:** [October 19, 2021, 10:16pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/8 "2021-10-19T22:16:15Z")

</div>

Hey John. No…that .py file just specifies where Nuke is installed. Not your individual Nuke comps. Those you just load in the PyBox node as needed.

---

<div class="post-metadata">

**Author:** ![ALan](https://avatars.discourse-cdn.com/v4/letter/a/a87d85/32.png) [@ALan](https://forum.logik.tv/u/ALan)\
**Post date:** [November 11, 2021, 12:25am UTC](https://forum.logik.tv/t/pybox-nuke/4091/9 "2021-11-11T00:25:37Z")

</div>

Anyone tested Pybox with CentOS 8.2 and Nuke13? We can’t get it to work. Spits out a bunch of errors in the Flame shell.

---

<div class="post-metadata">

**Author:** ![Stefan](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/stefan/32/631_2.png) [@Stefan](https://forum.logik.tv/u/Stefan)\
**Post date:** [October 14, 2022, 5:18pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/10 "2022-10-14T17:18:09Z")

</div>

Would anyone have an example of a pybox running a nuke process with exposed nuke parameters?  
Or an explanation about how to expose nuke parameters in a pybox?

---

<div class="post-metadata">

**Author:** ![johnt](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/johnt/32/14040_2.png) [@johnt](https://forum.logik.tv/u/johnt)\
**Post date:** [October 14, 2022, 5:36pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/11 "2022-10-14T17:36:56Z")

</div>

I’m not sure you can expose the parameters in Pybox.

---

<div class="post-metadata">

**Author:** ![Stefan](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/stefan/32/631_2.png) [@Stefan](https://forum.logik.tv/u/Stefan)\
**Post date:** [October 14, 2022, 5:59pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/12 "2022-10-14T17:59:02Z")

</div>

I thought that was why we can design the pybox ui with different widgets (buttons, value fields, colors, dropdown)

---

<div class="post-metadata">

**Author:** ![johnt](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/johnt/32/14040_2.png) [@johnt](https://forum.logik.tv/u/johnt)\
**Post date:** [October 14, 2022, 6:22pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/13 "2022-10-14T18:22:59Z")

</div>

Let me be more specific: it is my belief that nuke parameters (like baselight parameters) are not exposed in Pybox deliberately. Happy to be proved wrong.

---

<div class="post-metadata">

**Author:** ![Stefan](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/stefan/32/631_2.png) [@Stefan](https://forum.logik.tv/u/Stefan)\
**Post date:** [October 14, 2022, 8:37pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/14 "2022-10-14T20:37:29Z")

</div>

Thanks John! And if I understand things correctly, happy to prove you wrong 🙂  
Thiago Porto shows that its possible in this video

[![](https://us1.discourse-cdn.com/flex020/uploads/thedepartmentofexternalservices/original/2X/0/0e4f22749d500194b62eeba3e4c20bb20a3fa7db.jpeg "Demo Flame2020 - Part3of3 - Eddy Simulations in Flame Idea") ](https://www.youtube.com/watch?v=rY43QX3pjBI)

---

<div class="post-metadata">

**Author:** ![johnt](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/johnt/32/14040_2.png) [@johnt](https://forum.logik.tv/u/johnt)\
**Post date:** [October 14, 2022, 8:57pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/15 "2022-10-14T20:57:32Z")

</div>

Calling @tpo

---

<div class="post-metadata">

**Author:** ![tpo](https://avatars.discourse-cdn.com/v4/letter/t/bbe5ce/32.png) [@tpo](https://forum.logik.tv/u/tpo)\
**Post date:** [October 14, 2022, 9:21pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/16 "2022-10-14T21:21:32Z")

</div>

Hey guys!  
Yes there is a few parameters you can control inside Nuke from Flame UI using PyBox.  
Not all options in Nuke in possible, but most of the options are. (If this is what yr asking?)  
I like to create a Group node in Nuke, then you name what you want and in PyBox look for that to be available in Flame.  
On the video above i was controlling lights with its Axis ops linked to the Pybox Flame UI.  
Options that has Sliders in Nuke are the ones that work better. Option with buttons only i never had much success.  
You add Transform for exemple, as adsk\_UI, Flame pickups and reads

For exemple:  
Nuke node which name starts with `adsk_` can have its knobs exposed in Flame’s Pybox…

set cut\_paste\_input [stack 0]  
version 13.2 v2  
Group {  
inputs 0  
name adsk\_UI  
selected true  
xpos -221  
ypos -114  
addUserKnob {20 User}  
addUserKnob {41 adsk\_translate l translate T Transform1.translate}  
addUserKnob {41 adsk\_scale l scale T Transform1.scale}  
addUserKnob {41 adsk\_saturation l saturation T ColorCorrect1.saturation}  
addUserKnob {41 adsk\_contrast l contrast T ColorCorrect1.contrast}  
addUserKnob {41 adsk\_gamma l gamma T ColorCorrect1.gamma}  
addUserKnob {41 adsk\_gain l gain T ColorCorrect1.gain}  
}  
Transform {  
inputs 0  
center {1024 778}  
name Transform1  
xpos -631  
ypos -89  
}  
ColorCorrect {  
name ColorCorrect1  
selected true  
xpos -631  
ypos -63  
}  
end\_group

 ![Screen Shot 2022-10-14 at 18.28.20](https://us1.discourse-cdn.com/flex020/uploads/thedepartmentofexternalservices/original/2X/3/3f9d0a93c246c8f56603e84bca1ffc07a22ccd39.png)

---

<div class="post-metadata">

**Author:** ![Stefan](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/stefan/32/631_2.png) [@Stefan](https://forum.logik.tv/u/Stefan)\
**Post date:** [October 14, 2022, 10:19pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/17 "2022-10-14T22:19:36Z")

</div>

Thanks Thiago, much appreciated!!!  
Also I guess I’ve been lazy and didn’t scroll all the way down on the user manual page, there’s a section about it.  
[https://help.autodesk.com/view/FLAME/2022/ENU/?guid=Flame\_API\_Pybox\_Documentation\_html](https://help.autodesk.com/view/FLAME/2022/ENU/?guid=Flame_API_Pybox_Documentation_html)

---

<div class="post-metadata">

**Author:** ![TimC](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/timc/32/11881_2.png) [@TimC](https://forum.logik.tv/u/TimC)\
**Post date:** [October 14, 2022, 11:19pm UTC](https://forum.logik.tv/t/pybox-nuke/4091/20 "2022-10-14T23:19:43Z")

</div>

> [@tpo](#):
>
> …orm1.scale}addUserKnob {41 adsk\_saturation l saturation T ColorCorrect1.saturation}addUserKnob {41 adsk\_contrast l contrast T ColorCorrect1.contrast}addUserKnob {41 adsk\_gamma l gamma T ColorCorrect1.gamma}addUserKnob {41 adsk\_gain l gain T ColorCorrect1.gain}}Transform {inputs 0center {1024 778}name Transform1xpos -631ypos -89}ColorCorrect {name ColorCorrect1selected truexpos -631ypos -63}end\_group

![](https://us1.discourse-cdn.com/flex020/uploads/thedepartmentofexternalservices/original/2X/d/d585ebc52cfdd886aef89930082f97fa172546b6.gif)

---

<div class="post-metadata">

**Author:** ![cnoellert](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/cnoellert/32/559_2.png) [@cnoellert](https://forum.logik.tv/u/cnoellert)\
**Post date:** [October 15, 2022, 12:31am UTC](https://forum.logik.tv/t/pybox-nuke/4091/21 "2022-10-15T00:31:48Z")

</div>

I like the slow walk better but this will do.

---

<div class="post-metadata">

**Author:** ![Stefan](https://sea2.discourse-cdn.com/flex020/user_avatar/forum.logik.tv/stefan/32/631_2.png) [@Stefan](https://forum.logik.tv/u/Stefan)\
**Post date:** [October 15, 2022, 12:42am UTC](https://forum.logik.tv/t/pybox-nuke/4091/22 "2022-10-15T00:42:16Z")

</div>

There’s really not much in the doc ☹  
@tpo, would it be possible to shed some light on how to set the handler? Or even share a python script?  
[edit] I mean, once the nuke script has a group and, let say a blur node with its value linked to the added adsk\_something parameter … how do you add the float field in the pybox ui that would control the nuke blur?

[Next page](https://forum.logik.tv/t/pybox-nuke/4091.md?page=2)
