Jump to: Board index » General » Fusion

Expressions become drustically slow

Learn about 3D compositing, animation, broadcast design and VFX workflows.
  • Author
  • Message
Offline
User avatar

Eugene Afanasiev

  • Posts: 607
  • Joined: Sun Aug 30, 2015 2:57 pm
  • Location: Russia

Expressions become drustically slow

PostSat Jan 23, 2016 5:01 pm

Why sliding the controls in modifier expression5 is so slow? Am I doing something wrong? Is there a better way in writing them?
Code: Select all
{
   Tools = ordered() {
      Camera3D5_1 = Camera3D {
         CtrlWZoom = false,
         Inputs = {
            ["Transform3DOp.Translate.X"] = Input {
               SourceOp = "Expression5",
               Source = "NumberResult",
            },
            ["Transform3DOp.Translate.Z"] = Input {
               SourceOp = "Expression6",
               Source = "NumberResult",
            },
            ["Transform3DOp.PivotNest"] = Input { Value = 1, },
            ["Transform3DOp.UseTarget"] = Input { Value = 1, },
            ["Transform3DOp.Target.X"] = Input {
               SourceOp = "Camera3D5_1XTargetPosition",
               Source = "Value",
            },
            AoV = Input { Value = 24.3265863475745, },
            ["Stereo.Mode"] = Input { Value = FuID { "Mono" }, },
            ["SurfacePlaneInputs.ObjectID.ObjectID"] = Input { Value = 17, },
            ["MtlStdInputs.MaterialID"] = Input { Value = 34, },
         },
         ViewInfo = OperatorInfo { Pos = { 661, 145 } },
      },
      Expression5 = Expression {
         CtrlWZoom = false,
         Inputs = {
            n1 = Input { Value = 25.0913461, },
            n2 = Input {
               SourceOp = "Expression5onCamera3D5_1NumberIn2",
               Source = "Value",
            },
            NumberExpression = Input { Value = "n1*sin(n2)", },
            ShowNumber3 = Input { Value = 0, },
            ShowNumber4 = Input { Value = 0, },
            ShowNumber5 = Input { Value = 0, },
            ShowNumber6 = Input { Value = 0, },
            ShowNumber7 = Input { Value = 0, },
            ShowNumber8 = Input { Value = 0, },
            ShowNumber9 = Input { Value = 0, },
            ShowPoint1 = Input { Value = 0, },
            ShowPoint2 = Input { Value = 0, },
            ShowPoint3 = Input { Value = 0, },
            ShowPoint4 = Input { Value = 0, },
            ShowPoint5 = Input { Value = 0, },
            ShowPoint6 = Input { Value = 0, },
            ShowPoint7 = Input { Value = 0, },
            ShowPoint8 = Input { Value = 0, },
            ShowPoint9 = Input { Value = 0, },
         },
      },
      Expression5onCamera3D5_1NumberIn2 = BezierSpline {
         SplineColor = { Red = 233, Green = 19, Blue = 5 },
         NameSet = true,
         KeyFrames = {
            [210] = { -45, RH = { 223.333333333333, -20 }, Flags = { Linear = true } },
            [250] = { 30, LH = { 236.666666666667, 5 }, Flags = { Linear = true } }
         }
      },
      Expression6 = Expression {
         Inputs = {
            n1 = Input {
               Value = 25.0913461,
               Expression = "Expression5.n1",
            },
            n2 = Input {
               Value = 30,
               Expression = "Expression5.n2",
            },
            NumberExpression = Input { Value = "n1*cos(n2)", },
         },
      },
      Camera3D5_1XTargetPosition = BezierSpline {
         SplineColor = { Red = 251, Green = 183, Blue = 208 },
         NameSet = true,
         KeyFrames = {
            [210] = { -7.48619816458194, RH = { 240, -2.81971331468301 }, Flags = { Linear = true } },
            [300] = { 6.51325638511485, LH = { 270, 1.84677153521592 }, Flags = { Linear = true } }
         }
      }
   }
}
__
--[[BMD's cameras and Resolve all-post workflow evangelist
My old stuff: http://www.youtube.com/rebelorelse
Debug: Asus ROG Duo GX550 i9 10980 48Gb RAM RTX2080MaxQ DaVinci Resolve Studio / Fusion Studio Latest Version]]--
Offline
User avatar

Chad Capeland

  • Posts: 3308
  • Joined: Mon Nov 10, 2014 9:40 pm

Re: Expressions become drustically slow

PostSat Jan 23, 2016 5:36 pm

On my machine it's running about 500fps, so it's slow, but not THAT slow.

The issue is the 3D paths. Each time you move the slider you force 2 expression modifiers to evaluate 1000 times.
Chad Capeland
Indicated, LLC
www.floweffects.com
Offline
User avatar

Eugene Afanasiev

  • Posts: 607
  • Joined: Sun Aug 30, 2015 2:57 pm
  • Location: Russia

Re: Expressions become drustically slow

PostSat Jan 23, 2016 5:45 pm

No I mean the expressions run smooth if you don't touch parameters, but I can not slide them normally though is it normal behavior?

And how to convert expressions to keyframes?
__
--[[BMD's cameras and Resolve all-post workflow evangelist
My old stuff: http://www.youtube.com/rebelorelse
Debug: Asus ROG Duo GX550 i9 10980 48Gb RAM RTX2080MaxQ DaVinci Resolve Studio / Fusion Studio Latest Version]]--
Offline
User avatar

Chad Capeland

  • Posts: 3308
  • Joined: Mon Nov 10, 2014 9:40 pm

Re: Expressions become drustically slow

PostSat Jan 23, 2016 6:43 pm

You're missing the point. The reason it plays smoothly is because it's already been evaluated. If you change it, of course it reevaluates, which is slower than not reevaluating.
Chad Capeland
Indicated, LLC
www.floweffects.com
Offline
User avatar

Eugene Afanasiev

  • Posts: 607
  • Joined: Sun Aug 30, 2015 2:57 pm
  • Location: Russia

Re: Expressions become drustically slow

PostSat Jan 23, 2016 6:59 pm

Understood. Thank you.
__
--[[BMD's cameras and Resolve all-post workflow evangelist
My old stuff: http://www.youtube.com/rebelorelse
Debug: Asus ROG Duo GX550 i9 10980 48Gb RAM RTX2080MaxQ DaVinci Resolve Studio / Fusion Studio Latest Version]]--
Offline
User avatar

Eugene Afanasiev

  • Posts: 607
  • Joined: Sun Aug 30, 2015 2:57 pm
  • Location: Russia

Re: Expressions become drustically slow

PostSat Jan 23, 2016 7:10 pm

And argonomically is my comp correct or could it be set up easier and lighter for calculations?
__
--[[BMD's cameras and Resolve all-post workflow evangelist
My old stuff: http://www.youtube.com/rebelorelse
Debug: Asus ROG Duo GX550 i9 10980 48Gb RAM RTX2080MaxQ DaVinci Resolve Studio / Fusion Studio Latest Version]]--
Offline
User avatar

Chad Capeland

  • Posts: 3308
  • Joined: Mon Nov 10, 2014 9:40 pm

Re: Expressions become drustically slow

PostSun Jan 24, 2016 3:27 am

You might have better performance using SimpleExpressions. I haven't really tried comparing them.
Chad Capeland
Indicated, LLC
www.floweffects.com
Offline
User avatar

Eugene Afanasiev

  • Posts: 607
  • Joined: Sun Aug 30, 2015 2:57 pm
  • Location: Russia

Re: Expressions become drustically slow

PostSun Jan 24, 2016 6:40 am

Thanks, l'll check that
__
--[[BMD's cameras and Resolve all-post workflow evangelist
My old stuff: http://www.youtube.com/rebelorelse
Debug: Asus ROG Duo GX550 i9 10980 48Gb RAM RTX2080MaxQ DaVinci Resolve Studio / Fusion Studio Latest Version]]--
Offline
User avatar

Eugene Afanasiev

  • Posts: 607
  • Joined: Sun Aug 30, 2015 2:57 pm
  • Location: Russia

Re: Expressions become drustically slow

PostSun Jan 24, 2016 6:43 am

Anyway then it's a feature request cause this is urgent to see changes on the fly you slide you - want respond, at least there shouldn't be the hanging of the whole thing while it's recalculating
__
--[[BMD's cameras and Resolve all-post workflow evangelist
My old stuff: http://www.youtube.com/rebelorelse
Debug: Asus ROG Duo GX550 i9 10980 48Gb RAM RTX2080MaxQ DaVinci Resolve Studio / Fusion Studio Latest Version]]--
Offline
User avatar

Chad Capeland

  • Posts: 3308
  • Joined: Mon Nov 10, 2014 9:40 pm

Re: Expressions become drustically slow

PostSun Jan 24, 2016 7:33 am

Eugene Afanasiev wrote:Anyway then it's a feature request cause this is urgent to see changes on the fly you slide you - want respond, at least there shouldn't be the hanging of the whole thing while it's recalculating


Fusion is interactive. It is not realtime. When you put something in the viewer, you expect it to render. There's no "Do" button in Fusion. You always have to balance what you want to see with how much time you want to wait for it. It might be handy to have a temporal proxy with piecewise linear interpolation, but you'll always be trying to balance feedback time and content.
Chad Capeland
Indicated, LLC
www.floweffects.com
Offline
User avatar

michael vorberg

  • Posts: 943
  • Joined: Wed Nov 12, 2014 8:47 pm
  • Location: stuttgart, germany

Re: Expressions become drustically slow

PostSun Jan 24, 2016 9:46 am

i think it can be related to the view controls.
fusion has to calculate and draw the 3d spline of the animation. to do so it must calculate all the frames of the animation and this takes some time.
if you disable the view controls of the camera everything is interactive and running smoothly
Offline
User avatar

Eugene Afanasiev

  • Posts: 607
  • Joined: Sun Aug 30, 2015 2:57 pm
  • Location: Russia

Re: Expressions become drustically slow

PostSun Jan 24, 2016 10:58 am

You are totally right! Thanks a lot!!!
__
--[[BMD's cameras and Resolve all-post workflow evangelist
My old stuff: http://www.youtube.com/rebelorelse
Debug: Asus ROG Duo GX550 i9 10980 48Gb RAM RTX2080MaxQ DaVinci Resolve Studio / Fusion Studio Latest Version]]--

Return to Fusion

Who is online

Users browsing this forum: No registered users and 57 guests