PDA

View Full Version : PFX Calc Time



Chrusion
03-05-2014, 05:27 PM
Why does PFX calculation times skyrocket exponentially the longer they cook?

I have a nozzle spraying 1000 particles/sec that live for a mere 4 frames. They don't collide or interact with anything in the scene. The calc starts off speedily at 2 frames/sec. By frame 150 it's down to 1/sec. By 300 is 1 every 6 seconds. And at 500 it's 1 every 15 secs as LW 11 goes unresponsive during that time and open panels shift positions and/or appear/disappear in Windows 7 x64 Ultimate.

jeric_synergy
03-05-2014, 07:20 PM
I'm guessing "math", and large data arrays. If whatever data structure is storing the location of every stinkin' particle on a frame by frame basis, and those data structures are slow to access, you'd see this behavior.

Like, for instance, it wasn't possible to simply append to a data structure, but it had to be COPIED each time. --Hey, stupider things have happened in Computer 'Science'.

It's POSSIBLE that such an inefficient data structure is in use, or a thousand other pitfalls. If the devs used a simple or wimpy animation/simulation to verify functionality, they'd never see significant slowdowns-- like if they only did 150 frame animations with 500 particles. All the code would 'work fine', and it's time to move to the next task.

prometheus
03-06-2014, 12:54 PM
weird...1000 particles and it goes slow, and that is when hitting calculate? if you donīt have any interaction you shouldnīt need to calculate though, but anyway it is strange since I donīt notice any lag at all when calculating such small number.

can you post a scene?

jeric_synergy
03-06-2014, 08:52 PM
Wouldn't you still have to calc things like gravity, momentum, etc?

The reason I suggested data structure inefficiency is that such an issue would increase over time, ie frames, no matter what the interaction math became, no matter how simple.

prometheus
03-06-2014, 09:05 PM
Wouldn't you still have to calc things like gravity, momentum, etc?

The reason I suggested data structure inefficiency is that such an issue would increase over time, ie frames, no matter what the interaction math became, no matter how simple.

gravity works within the particle emitter without any calculation, so unless other forces or collision objects are to interact.... thereīs no need to calculate.
Same goes for adding gravity dynamic object and interact with particles..not necessary to calculate.

Momentum? ..whatīs that?...sounds more like some NHL term:) I recall a funny quote from Mikael Renberg..a former Philadelphia flyer forward who played in "the legion of doom"
He said that he wasnīt that familiar with some english terms, and he recognized all players saying in the interviews..we got to keep the momentum etc....so Mikael did the same ..and said just that, but then after a while he asked a team mate, Ivé been using this word momentum in my interviews...but what does it mean..haha:) that was funny.

Havenīt seen any button or function called momentum though:)
Michael

jeric_synergy
03-06-2014, 09:32 PM
Inertia=momentum.

bazsa73
03-07-2014, 01:17 AM
In layout top row Utilities menu then on the left Additional, select FX Browser->Option Background job, shouldn't it use multithreading?

creacon
03-07-2014, 07:18 AM
This is a funny post. "Without any calculation" ;-)
So you think the particles are self aware and they know how they are expected to behave? What you probably mean is that the calculation is fast enough to play near real time. Add a few million particles with gravity and you'll see that there is a lot of calculation going on.

The problem with the internal particle systems in LW is that they are not really suited for large amounts of particles and that the implementation is a naive one.

creacon


gravity works within the particle emitter without any calculation, so unless other forces or collision objects are to interact.... thereīs no need to calculate.
Same goes for adding gravity dynamic object and interact with particles..not necessary to calculate.

Momentum? ..whatīs that?...sounds more like some NHL term:) I recall a funny quote from Mikael Renberg..a former Philadelphia flyer forward who played in "the legion of doom"
He said that he wasnīt that familiar with some english terms, and he recognized all players saying in the interviews..we got to keep the momentum etc....so Mikael did the same ..and said just that, but then after a while he asked a team mate, Ivé been using this word momentum in my interviews...but what does it mean..haha:) that was funny.

Havenīt seen any button or function called momentum though:)
Michael

prometheus
03-07-2014, 07:47 AM
This is a funny post. "Without any calculation" ;-)
So you think the particles are self aware and they know how they are expected to behave? What you probably mean is that the calculation is fast enough to play near real time. Add a few million particles with gravity and you'll see that there is a lot of calculation going on.

The problem with the internal particle systems in LW is that they are not really suited for large amounts of particles and that the implementation is a naive one.

creacon

Well yes..your post is funny too...
well yes and no, I donīt think the particles are self aware, that is something a machine in meka form canīt do, only we orgas are self aware...I think:D.

You and I do know that particles can be played or calculated..right? and thus it takes either in account hardbody and softbody or it just fast calculate itīs own motion behavior when hitting play only..so I reckon you understand me talking about Calculate and not calculate even if I do refer it to"not calculate"(there is a calculate button..yes there is:) )...and we do know that one of those two options are considerably slower.

and Yes...I can get around 300 000 of particles playing decently fast, creating velocity driven motions with textures on the particles in decent fast manner, but adding a wind dynamics
and use the velocity vectors there in directional winds and procedural textures....that will halt the system at that amount.

I have reached over 6 millions of particles and using the above method of using textures in the particles velocity channels...but at over 1-2 millions it takes time before the particles settle(cooking)..but playing them goes a little faster than the initial wait for them to be "added to the scene" when raising the birth rate and particle limits.

Michael

Chrusion
03-07-2014, 11:40 AM
You need to calc in order to SAVE motion for network rendering. I suppose I could have thought through this better and reasoned that since this is a cone spray of water that particle location continuity between render nodes is probably irrelevant due to the speed and duration of particles. Maybe the additional randomness of each node would create a nice visual effect. Oh well, the 600 frame calc finished and it's in the BNR queue rendering away.

Yes, PFX and HVs need a LOT of attention. They've been suffering lack of serious attention for years under the over burden of Bullet, VPR, GI, AA, and other necessary goodies needed for LW to stay almost current with the industry. The foundations of these two are extremely old in comparison to current computational technologies. We can only hope something massively better is in the works as we speak for LW 12.

Just wanted to inquire if it was me, my i7 960 (yeah, a bit old), or the old underlying architecture of PFX causing such workflow impediment.