Is 30 second compute times normal for more complex models?

Post here for help on using FreeCAD's graphical user interface (GUI).
Will2
Posts: 14
Joined: Thu Apr 28, 2016 3:19 pm

Is 30 second compute times normal for more complex models?

Postby Will2 » Tue Aug 14, 2018 10:40 pm

I love FreeCAD and it has been super helpful for years now. One thing I have been wondering about is if I'm getting poor performance or if something is wrong across the couple machines I've been running it on or that I've been doing things wrong. It's been worse since I've started making more complex models. Currently I have a PartDesign model with 20ish additive/subtractive features and it often take 30 seconds or more to compute when I make a feature change. I've worked around it by having a couple instances of FreeCAD running so when on is computing I can work on another model.

Is this normal? Are there things I can do in the design to reduce this? (I do follow the recommended practices with sketcher) Since I plan on getting new hardware soon, is there anything specific I can look for?

I see some of these beautiful designs with complex parts and think some of those must take some insane compute time using my experience as a benchmark.

Currently on an Intel Core i5-4210U

OS: Linux Mint 17.3 Rosa
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.17.13528 (Git)
Build type: None
Branch: releases/FreeCAD-0-17
Hash: 5c3f7bf8ec51e2c7187789f7edba71a7aa82a88b
Python version: 2.7.6
Qt version: 4.8.6
Coin version: 4.0.0a
OCC version: 7.3.0
Locale: English/UnitedStates (en_US)
freedman
Posts: 337
Joined: Thu Mar 22, 2018 3:02 am
Location: Washington State, USA

Re: Is 30 second compute times normal for more complex models?

Postby freedman » Tue Aug 14, 2018 10:52 pm

Set Edit->Preferences->Part Design-> Shape view->Tesstallation at 1.0 or 2.0 % and time it.
User avatar
ppemawm
Posts: 441
Joined: Fri May 17, 2013 3:54 pm
Location: Manhattan New York

Re: Is 30 second compute times normal for more complex models?

Postby ppemawm » Tue Aug 14, 2018 11:50 pm

Will2 wrote:
Tue Aug 14, 2018 10:40 pm
Currently I have a PartDesign model with 20ish additive/subtractive features and it often take 30 seconds or more to compute when I make a feature change.

Is this normal?
I routinely create models in excess of 50 Mb with many complex bodies with many features without any appreciable performance degradation while modelling. Save, autosave, and opening the file can take several minutes, however. I do not see any significant performance loss until the file grows to 100 Mb or so.

I am running an I7-4710HQ with 16 Gb RAM. Tessaltion is set at 0.02%. I am currently on V0.18.13983.

Without seeing an example file it is difficult to say what may be causing your problem.
What version are you using?
Will2
Posts: 14
Joined: Thu Apr 28, 2016 3:19 pm

Re: Is 30 second compute times normal for more complex models?

Postby Will2 » Tue Aug 14, 2018 11:53 pm

Thanks for the reply freedman.

I chose a demanding operation at the base of the feature and this is the results:
original was set to 0.5% which gave me 40 second compute time
Set it to 2% and restarted FreeCAD and it ended up being about 35 seconds
Set it to 1% and it was about 40 seconds.
8% 35 seconds.

Looks like I got some improvement out of it.

Also the variable in my version I think is labelled "Maximum deviation depending on the model bounding box" which is the only variable with units as a percentage. Is this the correct one? Edit, I see the main heading is labeled Tellellation.
Last edited by Will2 on Wed Aug 15, 2018 12:04 am, edited 1 time in total.
Will2
Posts: 14
Joined: Thu Apr 28, 2016 3:19 pm

Re: Is 30 second compute times normal for more complex models?

Postby Will2 » Wed Aug 15, 2018 12:02 am

ppemawm, I'm envious.

Currently the file resides around 10MB. I'm running v0.17.13528 with about 8 gigs of ram, though I rarely approach max and often close applications to give myself more headroom if I'm worried about getting low.

Thanks for the input, are you running on WIndows?
User avatar
ppemawm
Posts: 441
Joined: Fri May 17, 2013 3:54 pm
Location: Manhattan New York

Re: Is 30 second compute times normal for more complex models?

Postby ppemawm » Wed Aug 15, 2018 12:27 am

Will2 wrote:
Wed Aug 15, 2018 12:02 am
Thanks for the input, are you running on WIndows?
Sorry, I should have included all the info:

OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.18.13983 (Git)
Build type: Release
Branch: master
Hash: 8f1c6f77c090ae7d9c2bfd4f18811083b01a3eb2
Python version: 2.7.14
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 7.2.0
Locale: English/UnitedStates (en_US)
wmayer
Site Admin
Posts: 13090
Joined: Thu Feb 19, 2009 10:32 am

Re: Is 30 second compute times normal for more complex models?

Postby wmayer » Wed Aug 15, 2018 6:00 am

Some further relevant factors are:
  • The number of cores of the CPU. In the past OCCT did almost everything in a single thread but they move forward to use multi-threading more and more. So, the more cores that fast the algorithms will be.
  • It depends on how the binaries are built. If the optimization level flag of the compiler is not used then the binaries are slower at execution time. Will2 you said that Build type is None while Release should be normal. So, it might be possible that optimization level is low or even off.
    If it's not too much work you could try to build your own version where in the CMake GUI panel you explicitly set Release as build type.
Koemi
Posts: 61
Joined: Thu Dec 28, 2017 11:13 am
Location: The Netherlands

Re: Is 30 second compute times normal for more complex models?

Postby Koemi » Wed Aug 15, 2018 8:01 am

I am having the same as Will2. When I read there are people using designs more than 50MB... :shock: :shock: :shock:

Delays of >20s with files larger than 4MB... :|

I already made a topic about this, but no solution so far...
https://forum.freecadweb.org/viewtopic.php?f=3&t=26803

Maybe FreeCAD gets sluggish because I am not working with files saved locally... I am not sure...


OS: Windows 10
Word size of OS: 64-bit
Word size of FreeCAD: 64-bit
Version: 0.16.6712 (Git)
Build type: Release
Branch: releases/FreeCAD-0-16
Hash: da2d364457257a7a8c6fb2137cea12c45becd71a
Python version: 2.7.8
Qt version: 4.8.7
Coin version: 4.0.0a
OCC version: 6.8.0.oce-0.17
wmayer
Site Admin
Posts: 13090
Joined: Thu Feb 19, 2009 10:32 am

Re: Is 30 second compute times normal for more complex models?

Postby wmayer » Wed Aug 15, 2018 8:40 am

About compiler options this was an issue that was discussed a few years ago: https://forum.freecadweb.org/viewtopic.php?f=8&t=7136
At that time we implemented a way to pass the required optimization flags to the build system. But who knows maybe things have changed again or Mint does certain things differently. I wonder whether there is a way on Mint to access the build log of the FreeCAD package.
User avatar
sgrogan
Posts: 4443
Joined: Wed Oct 22, 2014 5:02 pm

Re: Is 30 second compute times normal for more complex models?

Postby sgrogan » Wed Aug 15, 2018 11:40 am

wmayer wrote:
Wed Aug 15, 2018 8:40 am
I wonder whether there is a way on Mint to access the build log of the FreeCAD package.
I'm pretty sure Will2 is using the stable PPA, Mint 17.3 is based on Ubuntu 14.04. So maybe it's the same problem as before? I haven't made any changes to the compiler flags, but tonight I will compare to your linked post.
This should be the build log https://launchpadlibrarian.net/37882210 ... ING.txt.gz
And the rules file https://git.launchpad.net/~freecad-main ... ?h=release