discuss@lists.openscad.org

OpenSCAD general discussion Mailing-list

View all threads

Help with reducing compilation speed for this model

J
jsc
Tue, Jul 11, 2017 8:13 PM

I am trying to create a model of a Helicone
(http://beyond123.com/pa/helicone.html). It is made up of simple shapes with
a few differences and unions. It takes 22 minutes on my desktop to compile.
I've certainly had renders take much longer, but not for what should be a
fairly simple object. Might anyone have some insight as to what is causing
it to choke, and potentially how to speed things up?

https://www.dropbox.com/s/jipez0ov80sjixn/helicone.scad?dl=0

--
View this message in context: http://forum.openscad.org/Help-with-reducing-compilation-speed-for-this-model-tp21803.html
Sent from the OpenSCAD mailing list archive at Nabble.com.

I am trying to create a model of a Helicone (http://beyond123.com/pa/helicone.html). It is made up of simple shapes with a few differences and unions. It takes 22 minutes on my desktop to compile. I've certainly had renders take much longer, but not for what should be a fairly simple object. Might anyone have some insight as to what is causing it to choke, and potentially how to speed things up? https://www.dropbox.com/s/jipez0ov80sjixn/helicone.scad?dl=0 -- View this message in context: http://forum.openscad.org/Help-with-reducing-compilation-speed-for-this-model-tp21803.html Sent from the OpenSCAD mailing list archive at Nabble.com.
AD
Ari Diacou
Tue, Jul 11, 2017 8:27 PM

It's the rotate_extrudes being done inside the loop. RE's are a real pain
to render.

On Tue, Jul 11, 2017 at 4:13 PM, jsc jsc@alum.mit.edu wrote:

I am trying to create a model of a Helicone
(http://beyond123.com/pa/helicone.html). It is made up of simple shapes
with
a few differences and unions. It takes 22 minutes on my desktop to compile.
I've certainly had renders take much longer, but not for what should be a
fairly simple object. Might anyone have some insight as to what is causing
it to choke, and potentially how to speed things up?

https://www.dropbox.com/s/jipez0ov80sjixn/helicone.scad?dl=0

--
View this message in context: http://forum.openscad.org/
Help-with-reducing-compilation-speed-for-this-model-tp21803.html
Sent from the OpenSCAD mailing list archive at Nabble.com.


OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org

It's the rotate_extrudes being done inside the loop. RE's are a real pain to render. On Tue, Jul 11, 2017 at 4:13 PM, jsc <jsc@alum.mit.edu> wrote: > I am trying to create a model of a Helicone > (http://beyond123.com/pa/helicone.html). It is made up of simple shapes > with > a few differences and unions. It takes 22 minutes on my desktop to compile. > I've certainly had renders take much longer, but not for what should be a > fairly simple object. Might anyone have some insight as to what is causing > it to choke, and potentially how to speed things up? > > https://www.dropbox.com/s/jipez0ov80sjixn/helicone.scad?dl=0 > > > > -- > View this message in context: http://forum.openscad.org/ > Help-with-reducing-compilation-speed-for-this-model-tp21803.html > Sent from the OpenSCAD mailing list archive at Nabble.com. > > _______________________________________________ > OpenSCAD mailing list > Discuss@lists.openscad.org > http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org >
AD
Ari Diacou
Tue, Jul 11, 2017 8:30 PM

commenting out line 19: "$fs = 0.5;" reduced the render time to 5 minutes
on a good/slightly dated gaming desktop.

On Tue, Jul 11, 2017 at 4:27 PM, Ari Diacou ari.diacou@gmail.com wrote:

It's the rotate_extrudes being done inside the loop. RE's are a real pain
to render.

On Tue, Jul 11, 2017 at 4:13 PM, jsc jsc@alum.mit.edu wrote:

I am trying to create a model of a Helicone
(http://beyond123.com/pa/helicone.html). It is made up of simple shapes
with
a few differences and unions. It takes 22 minutes on my desktop to
compile.
I've certainly had renders take much longer, but not for what should be a
fairly simple object. Might anyone have some insight as to what is causing
it to choke, and potentially how to speed things up?

https://www.dropbox.com/s/jipez0ov80sjixn/helicone.scad?dl=0

--
View this message in context: http://forum.openscad.org/Help
-with-reducing-compilation-speed-for-this-model-tp21803.html
Sent from the OpenSCAD mailing list archive at Nabble.com.


OpenSCAD mailing list
Discuss@lists.openscad.org
http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org

commenting out line 19: "$fs = 0.5;" reduced the render time to 5 minutes on a good/slightly dated gaming desktop. On Tue, Jul 11, 2017 at 4:27 PM, Ari Diacou <ari.diacou@gmail.com> wrote: > It's the rotate_extrudes being done inside the loop. RE's are a real pain > to render. > > On Tue, Jul 11, 2017 at 4:13 PM, jsc <jsc@alum.mit.edu> wrote: > >> I am trying to create a model of a Helicone >> (http://beyond123.com/pa/helicone.html). It is made up of simple shapes >> with >> a few differences and unions. It takes 22 minutes on my desktop to >> compile. >> I've certainly had renders take much longer, but not for what should be a >> fairly simple object. Might anyone have some insight as to what is causing >> it to choke, and potentially how to speed things up? >> >> https://www.dropbox.com/s/jipez0ov80sjixn/helicone.scad?dl=0 >> >> >> >> -- >> View this message in context: http://forum.openscad.org/Help >> -with-reducing-compilation-speed-for-this-model-tp21803.html >> Sent from the OpenSCAD mailing list archive at Nabble.com. >> >> _______________________________________________ >> OpenSCAD mailing list >> Discuss@lists.openscad.org >> http://lists.openscad.org/mailman/listinfo/discuss_lists.openscad.org >> > >
P
Parkinbot
Tue, Jul 11, 2017 8:31 PM

OpenSCAD is not very fast when it comes to unions with a large number of
objects having a large number of vertices.
As you will have print to the slices one by one, why not also render the
slices one by one?

jsc wrote

I am trying to create a model of a Helicone
(http://beyond123.com/pa/helicone.html). It is made up of simple shapes
with a few differences and unions. It takes 22 minutes on my desktop to
compile. I've certainly had renders take much longer, but not for what
should be a fairly simple object. Might anyone have some insight as to
what is causing it to choke, and potentially how to speed things up?

https://www.dropbox.com/s/jipez0ov80sjixn/helicone.scad?dl=0

--
View this message in context: http://forum.openscad.org/Help-with-reducing-compilation-speed-for-this-model-tp21803p21807.html
Sent from the OpenSCAD mailing list archive at Nabble.com.

OpenSCAD is not very fast when it comes to unions with a large number of objects having a large number of vertices. As you will have print to the slices one by one, why not also render the slices one by one? jsc wrote > I am trying to create a model of a Helicone > (http://beyond123.com/pa/helicone.html). It is made up of simple shapes > with a few differences and unions. It takes 22 minutes on my desktop to > compile. I've certainly had renders take much longer, but not for what > should be a fairly simple object. Might anyone have some insight as to > what is causing it to choke, and potentially how to speed things up? > > https://www.dropbox.com/s/jipez0ov80sjixn/helicone.scad?dl=0 -- View this message in context: http://forum.openscad.org/Help-with-reducing-compilation-speed-for-this-model-tp21803p21807.html Sent from the OpenSCAD mailing list archive at Nabble.com.
J
jsc
Tue, Jul 11, 2017 10:03 PM

drxenocide wrote

commenting out line 19: "$fs = 0.5;" reduced the render time to 5 minutes
on a good/slightly dated gaming desktop.

Yes, I can turn down the fidelity to view, and compile a slice at a time
when I go to use it. It just surprised me that a model that doesn't use
anything fancy in terms of minkowski would take so long.

drxenocide wrote

It's the rotate_extrudes being done inside the loop. RE's are a real pain
to render.

Removing the pin slot code and the $fs setting lowered the compile down to
1:40, which is still way more than what I would have expected for just a
bunch of cylinders and flat extrusions.

--
View this message in context: http://forum.openscad.org/Help-with-reducing-compilation-speed-for-this-model-tp21803p21808.html
Sent from the OpenSCAD mailing list archive at Nabble.com.

drxenocide wrote > commenting out line 19: "$fs = 0.5;" reduced the render time to 5 minutes > on a good/slightly dated gaming desktop. Yes, I can turn down the fidelity to view, and compile a slice at a time when I go to use it. It just surprised me that a model that doesn't use anything fancy in terms of minkowski would take so long. drxenocide wrote > It's the rotate_extrudes being done inside the loop. RE's are a real pain > to render. Removing the pin slot code and the $fs setting lowered the compile down to 1:40, which is still way more than what I would have expected for just a bunch of cylinders and flat extrusions. -- View this message in context: http://forum.openscad.org/Help-with-reducing-compilation-speed-for-this-model-tp21803p21808.html Sent from the OpenSCAD mailing list archive at Nabble.com.
IO
Ian Oliver
Wed, Jul 12, 2017 7:23 AM

On 2017-07-11 23:03, jsc wrote:

Yes, I can turn down the fidelity to view, and compile a slice at a time
when I go to use it.

I have a block of code like this at the top of every file. I then have
OnPlate false when working on an object and set it true from the command
line when also setting other variables to select a slice of the object
to "plate up". This then slices it and rotates/translates to get the
right print orientation.

ViewDetail = "m";
PrintDetail = "h";
ViewFN = 60;
PrintFN = 120;
ViewFA = 360/ViewFN;
PrintFA= 360/PrintFN;
ViewFS = 0.5;
PrintFS = 0.1;

fn = OnPlate == true ? PrintFN : ViewFN;        // Note not $fn - used
by some code for loop steps etc.
$fs = OnPlate == true ? PrintFS : ViewFS;
$fa = OnPlate == true ? PrintFA : ViewFA;
$detail = OnPlate == true ? PrintDetail : ViewDetail;    // Allow
detail to be disabled to speed things up during development
$OnPlate = OnPlate;

On 2017-07-11 23:03, jsc wrote: > Yes, I can turn down the fidelity to view, and compile a slice at a time > when I go to use it. I have a block of code like this at the top of every file. I then have OnPlate false when working on an object and set it true from the command line when also setting other variables to select a slice of the object to "plate up". This then slices it and rotates/translates to get the right print orientation. ViewDetail = "m"; PrintDetail = "h"; ViewFN = 60; PrintFN = 120; ViewFA = 360/ViewFN; PrintFA= 360/PrintFN; ViewFS = 0.5; PrintFS = 0.1; fn = OnPlate == true ? PrintFN : ViewFN; // Note not $fn - used by some code for loop steps etc. $fs = OnPlate == true ? PrintFS : ViewFS; $fa = OnPlate == true ? PrintFA : ViewFA; $detail = OnPlate == true ? PrintDetail : ViewDetail; // Allow detail to be disabled to speed things up during development $OnPlate = OnPlate;