discuss@lists.openscad.org

OpenSCAD general discussion Mailing-list

View all threads

vnf_bend()

JW
Joe Weinpert
Wed, May 11, 2022 6:24 PM

len( vnf[0] ) = 420204

len( vnf[1] ) = 823326

If the length of the vnf array I am trying to bend is as large as what was
echoed above, am I whistling past the graveyard to try and get this:

bent1 = vnf_bend( vnf, axis = "Y" );

to work? Machine just stops forever until I *force *openSCAD to close.

len( vnf[0] ) = 420204 len( vnf[1] ) = 823326 If the length of the vnf array I am trying to bend is as large as what was echoed above, am I whistling past the graveyard to try and get this: bent1 = vnf_bend( vnf, axis = "Y" ); to work? Machine just stops forever until I *force *openSCAD to close.
AM
Adrian Mariano
Wed, May 11, 2022 8:26 PM

I think vnf_bend is pretty slow.  It has to first cut up your input
into strips (so that means line-plane intersections with every edge in
your data) and then once that's done, it maps it to the cylinder,
which is fairly fast in comparison.  I have not done rigorous timing
tests.  I think time will mainly depend on the number of edges, so you
could try using 1% of your faces and see how long it takes.  The
result will be garbage (a non-manifold partial result ) but it will
give you some idea of time.  Then you can try 2% and see what happens,
5%, etc.  That will give you a way to predict how long your real
problem will take.

I think that you probably will need to find a way to simplify the
problem, but the above exercise will tell you how much it needs to be
simplified.

On Wed, May 11, 2022 at 2:24 PM Joe Weinpert joe.weinpert@gmail.com wrote:

len( vnf[0] ) = 420204

len( vnf[1] ) = 823326

If the length of the vnf array I am trying to bend is as large as what was echoed above, am I whistling past the graveyard to try and get this:

bent1 = vnf_bend( vnf, axis = "Y" );

to work? Machine just stops forever until I force openSCAD to close.


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

I think vnf_bend is pretty slow. It has to first cut up your input into strips (so that means line-plane intersections with every edge in your data) and then once that's done, it maps it to the cylinder, which is fairly fast in comparison. I have not done rigorous timing tests. I think time will mainly depend on the number of edges, so you could try using 1% of your faces and see how long it takes. The result will be garbage (a non-manifold partial result ) but it will give you some idea of time. Then you can try 2% and see what happens, 5%, etc. That will give you a way to predict how long your real problem will take. I think that you probably will need to find a way to simplify the problem, but the above exercise will tell you how much it needs to be simplified. On Wed, May 11, 2022 at 2:24 PM Joe Weinpert <joe.weinpert@gmail.com> wrote: > > > len( vnf[0] ) = 420204 > > len( vnf[1] ) = 823326 > > > If the length of the vnf array I am trying to bend is as large as what was echoed above, am I whistling past the graveyard to try and get this: > > > bent1 = vnf_bend( vnf, axis = "Y" ); > > > to work? Machine just stops forever until I force openSCAD to close. > > > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org
JW
Joe Weinpert
Wed, May 11, 2022 11:09 PM

$fs=.01

After running for a couple of hours it came up with:

WARNING: Bad range parameter in for statement: too many elements (2551818)
in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57

WARNING: Bad range parameter in for statement: too many elements (2551818)
in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647

WARNING: Bad range parameter in for statement: too many elements (2551818)
in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648

WARNING: Bad range parameter in for statement: too many elements (2551818)
in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428

WARNING: Bad range parameter in for statement: too many elements (2551818)
in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650

and then did not finish.

Choked to death, I guess.

On Wed, May 11, 2022 at 4:27 PM Adrian Mariano avm4@cornell.edu wrote:

I think vnf_bend is pretty slow.  It has to first cut up your input
into strips (so that means line-plane intersections with every edge in
your data) and then once that's done, it maps it to the cylinder,
which is fairly fast in comparison.  I have not done rigorous timing
tests.  I think time will mainly depend on the number of edges, so you
could try using 1% of your faces and see how long it takes.  The
result will be garbage (a non-manifold partial result ) but it will
give you some idea of time.  Then you can try 2% and see what happens,
5%, etc.  That will give you a way to predict how long your real
problem will take.

I think that you probably will need to find a way to simplify the
problem, but the above exercise will tell you how much it needs to be
simplified.

On Wed, May 11, 2022 at 2:24 PM Joe Weinpert joe.weinpert@gmail.com
wrote:

len( vnf[0] ) = 420204

len( vnf[1] ) = 823326

If the length of the vnf array I am trying to bend is as large as what

was echoed above, am I whistling past the graveyard to try and get this:

bent1 = vnf_bend( vnf, axis = "Y" );

to work? Machine just stops forever until I force openSCAD to close.


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

$fs=.01 After running for a couple of hours it came up with: WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57 WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647 WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648 WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428 WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650 and then did not finish. Choked to death, I guess. On Wed, May 11, 2022 at 4:27 PM Adrian Mariano <avm4@cornell.edu> wrote: > I think vnf_bend is pretty slow. It has to first cut up your input > into strips (so that means line-plane intersections with every edge in > your data) and then once that's done, it maps it to the cylinder, > which is fairly fast in comparison. I have not done rigorous timing > tests. I think time will mainly depend on the number of edges, so you > could try using 1% of your faces and see how long it takes. The > result will be garbage (a non-manifold partial result ) but it will > give you some idea of time. Then you can try 2% and see what happens, > 5%, etc. That will give you a way to predict how long your real > problem will take. > > I think that you probably will need to find a way to simplify the > problem, but the above exercise will tell you how much it needs to be > simplified. > > On Wed, May 11, 2022 at 2:24 PM Joe Weinpert <joe.weinpert@gmail.com> > wrote: > > > > > > len( vnf[0] ) = 420204 > > > > len( vnf[1] ) = 823326 > > > > > > If the length of the vnf array I am trying to bend is as large as what > was echoed above, am I whistling past the graveyard to try and get this: > > > > > > bent1 = vnf_bend( vnf, axis = "Y" ); > > > > > > to work? Machine just stops forever until I force openSCAD to close. > > > > > > _______________________________________________ > > OpenSCAD mailing list > > To unsubscribe send an email to discuss-leave@lists.openscad.org > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org >
RD
Revar Desmera
Wed, May 11, 2022 11:18 PM

420k vertices and 823k faces, bending with $fs=0.01… That is an excessive degree of detail for OpenSCAD, I’m afraid.

  • Revar

On May 11, 2022, at 4:09 PM, Joe Weinpert joe.weinpert@gmail.com wrote:

$fs=.01

After running for a couple of hours it came up with:

WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57 <>
WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647 <>
WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648 <>
WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428 <>
WARNING: Bad range parameter in for statement: too many elements (2551818) in file  <>Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650 <>

and then did not finish.

Choked to death, I guess.

On Wed, May 11, 2022 at 4:27 PM Adrian Mariano <avm4@cornell.edu mailto:avm4@cornell.edu> wrote:
I think vnf_bend is pretty slow.  It has to first cut up your input
into strips (so that means line-plane intersections with every edge in
your data) and then once that's done, it maps it to the cylinder,
which is fairly fast in comparison.  I have not done rigorous timing
tests.  I think time will mainly depend on the number of edges, so you
could try using 1% of your faces and see how long it takes.  The
result will be garbage (a non-manifold partial result ) but it will
give you some idea of time.  Then you can try 2% and see what happens,
5%, etc.  That will give you a way to predict how long your real
problem will take.

I think that you probably will need to find a way to simplify the
problem, but the above exercise will tell you how much it needs to be
simplified.

On Wed, May 11, 2022 at 2:24 PM Joe Weinpert <joe.weinpert@gmail.com mailto:joe.weinpert@gmail.com> wrote:

len( vnf[0] ) = 420204

len( vnf[1] ) = 823326

If the length of the vnf array I am trying to bend is as large as what was echoed above, am I whistling past the graveyard to try and get this:

bent1 = vnf_bend( vnf, axis = "Y" );

to work? Machine just stops forever until I force openSCAD to close.


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org mailto:discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org mailto:discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

420k vertices and 823k faces, bending with $fs=0.01… That is an excessive degree of detail for OpenSCAD, I’m afraid. - Revar > On May 11, 2022, at 4:09 PM, Joe Weinpert <joe.weinpert@gmail.com> wrote: > > > $fs=.01 > > After running for a couple of hours it came up with: > > WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57 <> > WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647 <> > WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648 <> > WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428 <> > WARNING: Bad range parameter in for statement: too many elements (2551818) in file <>Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650 <> > > and then did not finish. > > Choked to death, I guess. > > > > > On Wed, May 11, 2022 at 4:27 PM Adrian Mariano <avm4@cornell.edu <mailto:avm4@cornell.edu>> wrote: > I think vnf_bend is pretty slow. It has to first cut up your input > into strips (so that means line-plane intersections with every edge in > your data) and then once that's done, it maps it to the cylinder, > which is fairly fast in comparison. I have not done rigorous timing > tests. I think time will mainly depend on the number of edges, so you > could try using 1% of your faces and see how long it takes. The > result will be garbage (a non-manifold partial result ) but it will > give you some idea of time. Then you can try 2% and see what happens, > 5%, etc. That will give you a way to predict how long your real > problem will take. > > I think that you probably will need to find a way to simplify the > problem, but the above exercise will tell you how much it needs to be > simplified. > > On Wed, May 11, 2022 at 2:24 PM Joe Weinpert <joe.weinpert@gmail.com <mailto:joe.weinpert@gmail.com>> wrote: > > > > > > len( vnf[0] ) = 420204 > > > > len( vnf[1] ) = 823326 > > > > > > If the length of the vnf array I am trying to bend is as large as what was echoed above, am I whistling past the graveyard to try and get this: > > > > > > bent1 = vnf_bend( vnf, axis = "Y" ); > > > > > > to work? Machine just stops forever until I force openSCAD to close. > > > > > > _______________________________________________ > > OpenSCAD mailing list > > To unsubscribe send an email to discuss-leave@lists.openscad.org <mailto:discuss-leave@lists.openscad.org> > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org <mailto:discuss-leave@lists.openscad.org> > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org
JW
Joe Weinpert
Wed, May 11, 2022 11:41 PM

No doubt.  But it is always interesting to try! Here is what it was
freezing on.

[image: result2.png]

It is something like this that would be nice to bend ... in this case a few
degrees in the Y axis.

But, anyway, just so you know, Revar,  This was created from a data file
that was created using your python script, heightfield(), and
vnf_polyhedron().  Took less than a minute runtime.  Beautiful, indeed.

On Wed, May 11, 2022 at 7:18 PM Revar Desmera revarbat@gmail.com wrote:

420k vertices and 823k faces, bending with $fs=0.01… That is an excessive
degree of detail for OpenSCAD, I’m afraid.

  • Revar

On May 11, 2022, at 4:09 PM, Joe Weinpert joe.weinpert@gmail.com wrote:

$fs=.01

After running for a couple of hours it came up with:

WARNING: Bad range parameter in for statement: too many elements (2551818)
in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57
WARNING: Bad range parameter in for statement: too many elements (2551818)
in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647
WARNING: Bad range parameter in for statement: too many elements (2551818)
in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648
WARNING: Bad range parameter in for statement: too many elements (2551818)
in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428
WARNING: Bad range parameter in for statement: too many elements (2551818)
in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650

and then did not finish.

Choked to death, I guess.

On Wed, May 11, 2022 at 4:27 PM Adrian Mariano avm4@cornell.edu wrote:

I think vnf_bend is pretty slow.  It has to first cut up your input
into strips (so that means line-plane intersections with every edge in
your data) and then once that's done, it maps it to the cylinder,
which is fairly fast in comparison.  I have not done rigorous timing
tests.  I think time will mainly depend on the number of edges, so you
could try using 1% of your faces and see how long it takes.  The
result will be garbage (a non-manifold partial result ) but it will
give you some idea of time.  Then you can try 2% and see what happens,
5%, etc.  That will give you a way to predict how long your real
problem will take.

I think that you probably will need to find a way to simplify the
problem, but the above exercise will tell you how much it needs to be
simplified.

On Wed, May 11, 2022 at 2:24 PM Joe Weinpert joe.weinpert@gmail.com
wrote:

len( vnf[0] ) = 420204

len( vnf[1] ) = 823326

If the length of the vnf array I am trying to bend is as large as what

was echoed above, am I whistling past the graveyard to try and get this:

bent1 = vnf_bend( vnf, axis = "Y" );

to work? Machine just stops forever until I force openSCAD to close.


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

No doubt. But it is always interesting to try! Here is what it was freezing on. [image: result2.png] It is something like this that would be nice to bend ... in this case a few degrees in the Y axis. But, anyway, just so you know, Revar, This was created from a data file that was created using your python script, heightfield(), and vnf_polyhedron(). Took less than a minute runtime. Beautiful, indeed. On Wed, May 11, 2022 at 7:18 PM Revar Desmera <revarbat@gmail.com> wrote: > 420k vertices and 823k faces, bending with $fs=0.01… That is an excessive > degree of detail for OpenSCAD, I’m afraid. > > - Revar > > > On May 11, 2022, at 4:09 PM, Joe Weinpert <joe.weinpert@gmail.com> wrote: > > > $fs=.01 > > After running for a couple of hours it came up with: > > WARNING: Bad range parameter in for statement: too many elements (2551818) > in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57 > WARNING: Bad range parameter in for statement: too many elements (2551818) > in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647 > WARNING: Bad range parameter in for statement: too many elements (2551818) > in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648 > WARNING: Bad range parameter in for statement: too many elements (2551818) > in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428 > WARNING: Bad range parameter in for statement: too many elements (2551818) > in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650 > > and then did not finish. > > Choked to death, I guess. > > > > > On Wed, May 11, 2022 at 4:27 PM Adrian Mariano <avm4@cornell.edu> wrote: > >> I think vnf_bend is pretty slow. It has to first cut up your input >> into strips (so that means line-plane intersections with every edge in >> your data) and then once that's done, it maps it to the cylinder, >> which is fairly fast in comparison. I have not done rigorous timing >> tests. I think time will mainly depend on the number of edges, so you >> could try using 1% of your faces and see how long it takes. The >> result will be garbage (a non-manifold partial result ) but it will >> give you some idea of time. Then you can try 2% and see what happens, >> 5%, etc. That will give you a way to predict how long your real >> problem will take. >> >> I think that you probably will need to find a way to simplify the >> problem, but the above exercise will tell you how much it needs to be >> simplified. >> >> On Wed, May 11, 2022 at 2:24 PM Joe Weinpert <joe.weinpert@gmail.com> >> wrote: >> > >> > >> > len( vnf[0] ) = 420204 >> > >> > len( vnf[1] ) = 823326 >> > >> > >> > If the length of the vnf array I am trying to bend is as large as what >> was echoed above, am I whistling past the graveyard to try and get this: >> > >> > >> > bent1 = vnf_bend( vnf, axis = "Y" ); >> > >> > >> > to work? Machine just stops forever until I force openSCAD to close. >> > >> > >> > _______________________________________________ >> > OpenSCAD mailing list >> > To unsubscribe send an email to discuss-leave@lists.openscad.org >> _______________________________________________ >> OpenSCAD mailing list >> To unsubscribe send an email to discuss-leave@lists.openscad.org >> > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org > > > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org >
AM
Adrian Mariano
Wed, May 11, 2022 11:48 PM

You could definitely shrink the VNF from something like that, which would
probably help.  You could decrease the number of points in your image.

But also, the slow part of vnf_bend() is slicing the VNF into strips.  The
VNF you have there from the image I think is already in strips!  The hard
part has been done.  So you could just remap the points yourself without
going through vnf_bend().  That would be fast.

On Wed, May 11, 2022 at 7:41 PM Joe Weinpert joe.weinpert@gmail.com wrote:

No doubt.  But it is always interesting to try! Here is what it was
freezing on.

[image: result2.png]

It is something like this that would be nice to bend ... in this case a
few degrees in the Y axis.

But, anyway, just so you know, Revar,  This was created from a data file
that was created using your python script, heightfield(), and
vnf_polyhedron().  Took less than a minute runtime.  Beautiful, indeed.

On Wed, May 11, 2022 at 7:18 PM Revar Desmera revarbat@gmail.com wrote:

420k vertices and 823k faces, bending with $fs=0.01… That is an excessive
degree of detail for OpenSCAD, I’m afraid.

  • Revar

On May 11, 2022, at 4:09 PM, Joe Weinpert joe.weinpert@gmail.com wrote:

$fs=.01

After running for a couple of hours it came up with:

WARNING: Bad range parameter in for statement: too many elements
(2551818) in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57
WARNING: Bad range parameter in for statement: too many elements
(2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647
WARNING: Bad range parameter in for statement: too many elements
(2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648
WARNING: Bad range parameter in for statement: too many elements
(2551818) in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428

WARNING: Bad range parameter in for statement: too many elements
(2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650

and then did not finish.

Choked to death, I guess.

On Wed, May 11, 2022 at 4:27 PM Adrian Mariano avm4@cornell.edu wrote:

I think vnf_bend is pretty slow.  It has to first cut up your input
into strips (so that means line-plane intersections with every edge in
your data) and then once that's done, it maps it to the cylinder,
which is fairly fast in comparison.  I have not done rigorous timing
tests.  I think time will mainly depend on the number of edges, so you
could try using 1% of your faces and see how long it takes.  The
result will be garbage (a non-manifold partial result ) but it will
give you some idea of time.  Then you can try 2% and see what happens,
5%, etc.  That will give you a way to predict how long your real
problem will take.

I think that you probably will need to find a way to simplify the
problem, but the above exercise will tell you how much it needs to be
simplified.

On Wed, May 11, 2022 at 2:24 PM Joe Weinpert joe.weinpert@gmail.com
wrote:

len( vnf[0] ) = 420204

len( vnf[1] ) = 823326

If the length of the vnf array I am trying to bend is as large as what

was echoed above, am I whistling past the graveyard to try and get this:

bent1 = vnf_bend( vnf, axis = "Y" );

to work? Machine just stops forever until I force openSCAD to close.


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

You could definitely shrink the VNF from something like that, which would probably help. You could decrease the number of points in your image. But also, the slow part of vnf_bend() is slicing the VNF into strips. The VNF you have there from the image I think is already in strips! The hard part has been done. So you could just remap the points yourself without going through vnf_bend(). That would be fast. On Wed, May 11, 2022 at 7:41 PM Joe Weinpert <joe.weinpert@gmail.com> wrote: > No doubt. But it is always interesting to try! Here is what it was > freezing on. > > [image: result2.png] > > It is something like this that would be nice to bend ... in this case a > few degrees in the Y axis. > > But, anyway, just so you know, Revar, This was created from a data file > that was created using your python script, heightfield(), and > vnf_polyhedron(). Took less than a minute runtime. Beautiful, indeed. > > > > > > On Wed, May 11, 2022 at 7:18 PM Revar Desmera <revarbat@gmail.com> wrote: > >> 420k vertices and 823k faces, bending with $fs=0.01… That is an excessive >> degree of detail for OpenSCAD, I’m afraid. >> >> - Revar >> >> >> On May 11, 2022, at 4:09 PM, Joe Weinpert <joe.weinpert@gmail.com> wrote: >> >> >> $fs=.01 >> >> After running for a couple of hours it came up with: >> >> WARNING: Bad range parameter in for statement: too many elements >> (2551818) in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57 >> WARNING: Bad range parameter in for statement: too many elements >> (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647 >> WARNING: Bad range parameter in for statement: too many elements >> (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648 >> WARNING: Bad range parameter in for statement: too many elements >> (2551818) in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428 >> >> WARNING: Bad range parameter in for statement: too many elements >> (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650 >> >> and then did not finish. >> >> Choked to death, I guess. >> >> >> >> >> On Wed, May 11, 2022 at 4:27 PM Adrian Mariano <avm4@cornell.edu> wrote: >> >>> I think vnf_bend is pretty slow. It has to first cut up your input >>> into strips (so that means line-plane intersections with every edge in >>> your data) and then once that's done, it maps it to the cylinder, >>> which is fairly fast in comparison. I have not done rigorous timing >>> tests. I think time will mainly depend on the number of edges, so you >>> could try using 1% of your faces and see how long it takes. The >>> result will be garbage (a non-manifold partial result ) but it will >>> give you some idea of time. Then you can try 2% and see what happens, >>> 5%, etc. That will give you a way to predict how long your real >>> problem will take. >>> >>> I think that you probably will need to find a way to simplify the >>> problem, but the above exercise will tell you how much it needs to be >>> simplified. >>> >>> On Wed, May 11, 2022 at 2:24 PM Joe Weinpert <joe.weinpert@gmail.com> >>> wrote: >>> > >>> > >>> > len( vnf[0] ) = 420204 >>> > >>> > len( vnf[1] ) = 823326 >>> > >>> > >>> > If the length of the vnf array I am trying to bend is as large as what >>> was echoed above, am I whistling past the graveyard to try and get this: >>> > >>> > >>> > bent1 = vnf_bend( vnf, axis = "Y" ); >>> > >>> > >>> > to work? Machine just stops forever until I force openSCAD to close. >>> > >>> > >>> > _______________________________________________ >>> > OpenSCAD mailing list >>> > To unsubscribe send an email to discuss-leave@lists.openscad.org >>> _______________________________________________ >>> OpenSCAD mailing list >>> To unsubscribe send an email to discuss-leave@lists.openscad.org >>> >> _______________________________________________ >> OpenSCAD mailing list >> To unsubscribe send an email to discuss-leave@lists.openscad.org >> >> >> _______________________________________________ >> OpenSCAD mailing list >> To unsubscribe send an email to discuss-leave@lists.openscad.org >> > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org >
RD
Revar Desmera
Wed, May 11, 2022 11:51 PM

Actually yes, the triangulation is small enough that you can just re-map the vertices into a curve without splitting vertices.  That should be much faster.

  • Revar

On May 11, 2022, at 4:48 PM, Adrian Mariano avm4@cornell.edu wrote:

You could definitely shrink the VNF from something like that, which would probably help.  You could decrease the number of points in your image.

But also, the slow part of vnf_bend() is slicing the VNF into strips.  The VNF you have there from the image I think is already in strips!  The hard part has been done.  So you could just remap the points yourself without going through vnf_bend().  That would be fast.

On Wed, May 11, 2022 at 7:41 PM Joe Weinpert <joe.weinpert@gmail.com mailto:joe.weinpert@gmail.com> wrote:
No doubt.  But it is always interesting to try! Here is what it was freezing on.

<result2.png>

It is something like this that would be nice to bend ... in this case a few degrees in the Y axis.

But, anyway, just so you know, Revar,  This was created from a data file that was created using your python script, heightfield(), and vnf_polyhedron().  Took less than a minute runtime.  Beautiful, indeed.

On Wed, May 11, 2022 at 7:18 PM Revar Desmera <revarbat@gmail.com mailto:revarbat@gmail.com> wrote:
420k vertices and 823k faces, bending with $fs=0.01… That is an excessive degree of detail for OpenSCAD, I’m afraid.

  • Revar

On May 11, 2022, at 4:09 PM, Joe Weinpert <joe.weinpert@gmail.com mailto:joe.weinpert@gmail.com> wrote:

$fs=.01

After running for a couple of hours it came up with:

WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57 <>
WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647 <>
WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648 <>
WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428 <>
WARNING: Bad range parameter in for statement: too many elements (2551818) in file  <>Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650 <>

and then did not finish.

Choked to death, I guess.

On Wed, May 11, 2022 at 4:27 PM Adrian Mariano <avm4@cornell.edu mailto:avm4@cornell.edu> wrote:
I think vnf_bend is pretty slow.  It has to first cut up your input
into strips (so that means line-plane intersections with every edge in
your data) and then once that's done, it maps it to the cylinder,
which is fairly fast in comparison.  I have not done rigorous timing
tests.  I think time will mainly depend on the number of edges, so you
could try using 1% of your faces and see how long it takes.  The
result will be garbage (a non-manifold partial result ) but it will
give you some idea of time.  Then you can try 2% and see what happens,
5%, etc.  That will give you a way to predict how long your real
problem will take.

I think that you probably will need to find a way to simplify the
problem, but the above exercise will tell you how much it needs to be
simplified.

On Wed, May 11, 2022 at 2:24 PM Joe Weinpert <joe.weinpert@gmail.com mailto:joe.weinpert@gmail.com> wrote:

len( vnf[0] ) = 420204

len( vnf[1] ) = 823326

If the length of the vnf array I am trying to bend is as large as what was echoed above, am I whistling past the graveyard to try and get this:

bent1 = vnf_bend( vnf, axis = "Y" );

to work? Machine just stops forever until I force openSCAD to close.


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org mailto:discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org mailto:discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org mailto:discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org mailto:discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org mailto:discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

Actually yes, the triangulation is small enough that you can just re-map the vertices into a curve without splitting vertices. That should be much faster. - Revar > On May 11, 2022, at 4:48 PM, Adrian Mariano <avm4@cornell.edu> wrote: > > You could definitely shrink the VNF from something like that, which would probably help. You could decrease the number of points in your image. > > But also, the slow part of vnf_bend() is slicing the VNF into strips. The VNF you have there from the image I think is already in strips! The hard part has been done. So you could just remap the points yourself without going through vnf_bend(). That would be fast. > > On Wed, May 11, 2022 at 7:41 PM Joe Weinpert <joe.weinpert@gmail.com <mailto:joe.weinpert@gmail.com>> wrote: > No doubt. But it is always interesting to try! Here is what it was freezing on. > > <result2.png> > > It is something like this that would be nice to bend ... in this case a few degrees in the Y axis. > > But, anyway, just so you know, Revar, This was created from a data file that was created using your python script, heightfield(), and vnf_polyhedron(). Took less than a minute runtime. Beautiful, indeed. > > > > > > On Wed, May 11, 2022 at 7:18 PM Revar Desmera <revarbat@gmail.com <mailto:revarbat@gmail.com>> wrote: > 420k vertices and 823k faces, bending with $fs=0.01… That is an excessive degree of detail for OpenSCAD, I’m afraid. > > - Revar > > >> On May 11, 2022, at 4:09 PM, Joe Weinpert <joe.weinpert@gmail.com <mailto:joe.weinpert@gmail.com>> wrote: >> >> >> $fs=.01 >> >> After running for a couple of hours it came up with: >> >> WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57 <> >> WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647 <> >> WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648 <> >> WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428 <> >> WARNING: Bad range parameter in for statement: too many elements (2551818) in file <>Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650 <> >> >> and then did not finish. >> >> Choked to death, I guess. >> >> >> >> >> On Wed, May 11, 2022 at 4:27 PM Adrian Mariano <avm4@cornell.edu <mailto:avm4@cornell.edu>> wrote: >> I think vnf_bend is pretty slow. It has to first cut up your input >> into strips (so that means line-plane intersections with every edge in >> your data) and then once that's done, it maps it to the cylinder, >> which is fairly fast in comparison. I have not done rigorous timing >> tests. I think time will mainly depend on the number of edges, so you >> could try using 1% of your faces and see how long it takes. The >> result will be garbage (a non-manifold partial result ) but it will >> give you some idea of time. Then you can try 2% and see what happens, >> 5%, etc. That will give you a way to predict how long your real >> problem will take. >> >> I think that you probably will need to find a way to simplify the >> problem, but the above exercise will tell you how much it needs to be >> simplified. >> >> On Wed, May 11, 2022 at 2:24 PM Joe Weinpert <joe.weinpert@gmail.com <mailto:joe.weinpert@gmail.com>> wrote: >> > >> > >> > len( vnf[0] ) = 420204 >> > >> > len( vnf[1] ) = 823326 >> > >> > >> > If the length of the vnf array I am trying to bend is as large as what was echoed above, am I whistling past the graveyard to try and get this: >> > >> > >> > bent1 = vnf_bend( vnf, axis = "Y" ); >> > >> > >> > to work? Machine just stops forever until I force openSCAD to close. >> > >> > >> > _______________________________________________ >> > OpenSCAD mailing list >> > To unsubscribe send an email to discuss-leave@lists.openscad.org <mailto:discuss-leave@lists.openscad.org> >> _______________________________________________ >> OpenSCAD mailing list >> To unsubscribe send an email to discuss-leave@lists.openscad.org <mailto:discuss-leave@lists.openscad.org> >> _______________________________________________ >> OpenSCAD mailing list >> To unsubscribe send an email to discuss-leave@lists.openscad.org <mailto:discuss-leave@lists.openscad.org> > > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org <mailto:discuss-leave@lists.openscad.org> > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org <mailto:discuss-leave@lists.openscad.org> > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org
RD
Revar Desmera
Wed, May 11, 2022 11:52 PM

I meant without splitting faces, of course.

  • Revar

On May 11, 2022, at 4:51 PM, Revar Desmera revarbat@gmail.com wrote:

Actually yes, the triangulation is small enough that you can just re-map the vertices into a curve without splitting vertices.  That should be much faster.

  • Revar

On May 11, 2022, at 4:48 PM, Adrian Mariano <avm4@cornell.edu mailto:avm4@cornell.edu> wrote:

You could definitely shrink the VNF from something like that, which would probably help.  You could decrease the number of points in your image.

But also, the slow part of vnf_bend() is slicing the VNF into strips.  The VNF you have there from the image I think is already in strips!  The hard part has been done.  So you could just remap the points yourself without going through vnf_bend().  That would be fast.

On Wed, May 11, 2022 at 7:41 PM Joe Weinpert <joe.weinpert@gmail.com mailto:joe.weinpert@gmail.com> wrote:
No doubt.  But it is always interesting to try! Here is what it was freezing on.

<result2.png>

It is something like this that would be nice to bend ... in this case a few degrees in the Y axis.

But, anyway, just so you know, Revar,  This was created from a data file that was created using your python script, heightfield(), and vnf_polyhedron().  Took less than a minute runtime.  Beautiful, indeed.

On Wed, May 11, 2022 at 7:18 PM Revar Desmera <revarbat@gmail.com mailto:revarbat@gmail.com> wrote:
420k vertices and 823k faces, bending with $fs=0.01… That is an excessive degree of detail for OpenSCAD, I’m afraid.

  • Revar

On May 11, 2022, at 4:09 PM, Joe Weinpert <joe.weinpert@gmail.com mailto:joe.weinpert@gmail.com> wrote:

$fs=.01

After running for a couple of hours it came up with:

WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57 <>
WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647 <>
WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648 <>
WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428 <>
WARNING: Bad range parameter in for statement: too many elements (2551818) in file  <>Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650 <>

and then did not finish.

Choked to death, I guess.

On Wed, May 11, 2022 at 4:27 PM Adrian Mariano <avm4@cornell.edu mailto:avm4@cornell.edu> wrote:
I think vnf_bend is pretty slow.  It has to first cut up your input
into strips (so that means line-plane intersections with every edge in
your data) and then once that's done, it maps it to the cylinder,
which is fairly fast in comparison.  I have not done rigorous timing
tests.  I think time will mainly depend on the number of edges, so you
could try using 1% of your faces and see how long it takes.  The
result will be garbage (a non-manifold partial result ) but it will
give you some idea of time.  Then you can try 2% and see what happens,
5%, etc.  That will give you a way to predict how long your real
problem will take.

I think that you probably will need to find a way to simplify the
problem, but the above exercise will tell you how much it needs to be
simplified.

On Wed, May 11, 2022 at 2:24 PM Joe Weinpert <joe.weinpert@gmail.com mailto:joe.weinpert@gmail.com> wrote:

len( vnf[0] ) = 420204

len( vnf[1] ) = 823326

If the length of the vnf array I am trying to bend is as large as what was echoed above, am I whistling past the graveyard to try and get this:

bent1 = vnf_bend( vnf, axis = "Y" );

to work? Machine just stops forever until I force openSCAD to close.


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org mailto:discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org mailto:discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org mailto:discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org mailto:discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org mailto:discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org mailto:discuss-leave@lists.openscad.org

I meant without splitting faces, of course. - Revar > On May 11, 2022, at 4:51 PM, Revar Desmera <revarbat@gmail.com> wrote: > > Actually yes, the triangulation is small enough that you can just re-map the vertices into a curve without splitting vertices. That should be much faster. > > - Revar > > >> On May 11, 2022, at 4:48 PM, Adrian Mariano <avm4@cornell.edu <mailto:avm4@cornell.edu>> wrote: >> >> You could definitely shrink the VNF from something like that, which would probably help. You could decrease the number of points in your image. >> >> But also, the slow part of vnf_bend() is slicing the VNF into strips. The VNF you have there from the image I think is already in strips! The hard part has been done. So you could just remap the points yourself without going through vnf_bend(). That would be fast. >> >> On Wed, May 11, 2022 at 7:41 PM Joe Weinpert <joe.weinpert@gmail.com <mailto:joe.weinpert@gmail.com>> wrote: >> No doubt. But it is always interesting to try! Here is what it was freezing on. >> >> <result2.png> >> >> It is something like this that would be nice to bend ... in this case a few degrees in the Y axis. >> >> But, anyway, just so you know, Revar, This was created from a data file that was created using your python script, heightfield(), and vnf_polyhedron(). Took less than a minute runtime. Beautiful, indeed. >> >> >> >> >> >> On Wed, May 11, 2022 at 7:18 PM Revar Desmera <revarbat@gmail.com <mailto:revarbat@gmail.com>> wrote: >> 420k vertices and 823k faces, bending with $fs=0.01… That is an excessive degree of detail for OpenSCAD, I’m afraid. >> >> - Revar >> >> >>> On May 11, 2022, at 4:09 PM, Joe Weinpert <joe.weinpert@gmail.com <mailto:joe.weinpert@gmail.com>> wrote: >>> >>> >>> $fs=.01 >>> >>> After running for a couple of hours it came up with: >>> >>> WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57 <> >>> WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647 <> >>> WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648 <> >>> WARNING: Bad range parameter in for statement: too many elements (2551818) in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428 <> >>> WARNING: Bad range parameter in for statement: too many elements (2551818) in file <>Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650 <> >>> >>> and then did not finish. >>> >>> Choked to death, I guess. >>> >>> >>> >>> >>> On Wed, May 11, 2022 at 4:27 PM Adrian Mariano <avm4@cornell.edu <mailto:avm4@cornell.edu>> wrote: >>> I think vnf_bend is pretty slow. It has to first cut up your input >>> into strips (so that means line-plane intersections with every edge in >>> your data) and then once that's done, it maps it to the cylinder, >>> which is fairly fast in comparison. I have not done rigorous timing >>> tests. I think time will mainly depend on the number of edges, so you >>> could try using 1% of your faces and see how long it takes. The >>> result will be garbage (a non-manifold partial result ) but it will >>> give you some idea of time. Then you can try 2% and see what happens, >>> 5%, etc. That will give you a way to predict how long your real >>> problem will take. >>> >>> I think that you probably will need to find a way to simplify the >>> problem, but the above exercise will tell you how much it needs to be >>> simplified. >>> >>> On Wed, May 11, 2022 at 2:24 PM Joe Weinpert <joe.weinpert@gmail.com <mailto:joe.weinpert@gmail.com>> wrote: >>> > >>> > >>> > len( vnf[0] ) = 420204 >>> > >>> > len( vnf[1] ) = 823326 >>> > >>> > >>> > If the length of the vnf array I am trying to bend is as large as what was echoed above, am I whistling past the graveyard to try and get this: >>> > >>> > >>> > bent1 = vnf_bend( vnf, axis = "Y" ); >>> > >>> > >>> > to work? Machine just stops forever until I force openSCAD to close. >>> > >>> > >>> > _______________________________________________ >>> > OpenSCAD mailing list >>> > To unsubscribe send an email to discuss-leave@lists.openscad.org <mailto:discuss-leave@lists.openscad.org> >>> _______________________________________________ >>> OpenSCAD mailing list >>> To unsubscribe send an email to discuss-leave@lists.openscad.org <mailto:discuss-leave@lists.openscad.org> >>> _______________________________________________ >>> OpenSCAD mailing list >>> To unsubscribe send an email to discuss-leave@lists.openscad.org <mailto:discuss-leave@lists.openscad.org> >> >> _______________________________________________ >> OpenSCAD mailing list >> To unsubscribe send an email to discuss-leave@lists.openscad.org <mailto:discuss-leave@lists.openscad.org> >> _______________________________________________ >> OpenSCAD mailing list >> To unsubscribe send an email to discuss-leave@lists.openscad.org <mailto:discuss-leave@lists.openscad.org> >> _______________________________________________ >> OpenSCAD mailing list >> To unsubscribe send an email to discuss-leave@lists.openscad.org <mailto:discuss-leave@lists.openscad.org> >
FH
Father Horton
Wed, May 11, 2022 11:56 PM

Simplifying/reducing the face count would be my advice too. I think
Meshmixer does that.

On Wed, May 11, 2022 at 6:53 PM Revar Desmera revarbat@gmail.com wrote:

I meant without splitting faces, of course.

  • Revar

On May 11, 2022, at 4:51 PM, Revar Desmera revarbat@gmail.com wrote:

Actually yes, the triangulation is small enough that you can just re-map
the vertices into a curve without splitting vertices.  That should be much
faster.

  • Revar

On May 11, 2022, at 4:48 PM, Adrian Mariano avm4@cornell.edu wrote:

You could definitely shrink the VNF from something like that, which would
probably help.  You could decrease the number of points in your image.

But also, the slow part of vnf_bend() is slicing the VNF into strips.  The
VNF you have there from the image I think is already in strips!  The hard
part has been done.  So you could just remap the points yourself without
going through vnf_bend().  That would be fast.

On Wed, May 11, 2022 at 7:41 PM Joe Weinpert joe.weinpert@gmail.com
wrote:

No doubt.  But it is always interesting to try! Here is what it was
freezing on.

<result2.png>

It is something like this that would be nice to bend ... in this case a
few degrees in the Y axis.

But, anyway, just so you know, Revar,  This was created from a data file
that was created using your python script, heightfield(), and
vnf_polyhedron().  Took less than a minute runtime.  Beautiful, indeed.

On Wed, May 11, 2022 at 7:18 PM Revar Desmera revarbat@gmail.com wrote:

420k vertices and 823k faces, bending with $fs=0.01… That is an
excessive degree of detail for OpenSCAD, I’m afraid.

  • Revar

On May 11, 2022, at 4:09 PM, Joe Weinpert joe.weinpert@gmail.com
wrote:

$fs=.01

After running for a couple of hours it came up with:

WARNING: Bad range parameter in for statement: too many elements
(2551818) in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57
WARNING: Bad range parameter in for statement: too many elements
(2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647
WARNING: Bad range parameter in for statement: too many elements
(2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648
WARNING: Bad range parameter in for statement: too many elements
(2551818) in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428

WARNING: Bad range parameter in for statement: too many elements
(2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650

and then did not finish.

Choked to death, I guess.

On Wed, May 11, 2022 at 4:27 PM Adrian Mariano avm4@cornell.edu wrote:

I think vnf_bend is pretty slow.  It has to first cut up your input
into strips (so that means line-plane intersections with every edge in
your data) and then once that's done, it maps it to the cylinder,
which is fairly fast in comparison.  I have not done rigorous timing
tests.  I think time will mainly depend on the number of edges, so you
could try using 1% of your faces and see how long it takes.  The
result will be garbage (a non-manifold partial result ) but it will
give you some idea of time.  Then you can try 2% and see what happens,
5%, etc.  That will give you a way to predict how long your real
problem will take.

I think that you probably will need to find a way to simplify the
problem, but the above exercise will tell you how much it needs to be
simplified.

On Wed, May 11, 2022 at 2:24 PM Joe Weinpert joe.weinpert@gmail.com
wrote:

len( vnf[0] ) = 420204

len( vnf[1] ) = 823326

If the length of the vnf array I am trying to bend is as large as

what was echoed above, am I whistling past the graveyard to try and get
this:

bent1 = vnf_bend( vnf, axis = "Y" );

to work? Machine just stops forever until I force openSCAD to close.


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org


OpenSCAD mailing list
To unsubscribe send an email to discuss-leave@lists.openscad.org

Simplifying/reducing the face count would be my advice too. I think Meshmixer does that. On Wed, May 11, 2022 at 6:53 PM Revar Desmera <revarbat@gmail.com> wrote: > I meant without splitting faces, of course. > > - Revar > > > On May 11, 2022, at 4:51 PM, Revar Desmera <revarbat@gmail.com> wrote: > > Actually yes, the triangulation is small enough that you can just re-map > the vertices into a curve without splitting vertices. That should be much > faster. > > - Revar > > > On May 11, 2022, at 4:48 PM, Adrian Mariano <avm4@cornell.edu> wrote: > > You could definitely shrink the VNF from something like that, which would > probably help. You could decrease the number of points in your image. > > But also, the slow part of vnf_bend() is slicing the VNF into strips. The > VNF you have there from the image I think is already in strips! The hard > part has been done. So you could just remap the points yourself without > going through vnf_bend(). That would be fast. > > On Wed, May 11, 2022 at 7:41 PM Joe Weinpert <joe.weinpert@gmail.com> > wrote: > >> No doubt. But it is always interesting to try! Here is what it was >> freezing on. >> >> <result2.png> >> >> It is something like this that would be nice to bend ... in this case a >> few degrees in the Y axis. >> >> But, anyway, just so you know, Revar, This was created from a data file >> that was created using your python script, heightfield(), and >> vnf_polyhedron(). Took less than a minute runtime. Beautiful, indeed. >> >> >> >> >> >> On Wed, May 11, 2022 at 7:18 PM Revar Desmera <revarbat@gmail.com> wrote: >> >>> 420k vertices and 823k faces, bending with $fs=0.01… That is an >>> excessive degree of detail for OpenSCAD, I’m afraid. >>> >>> - Revar >>> >>> >>> On May 11, 2022, at 4:09 PM, Joe Weinpert <joe.weinpert@gmail.com> >>> wrote: >>> >>> >>> $fs=.01 >>> >>> After running for a couple of hours it came up with: >>> >>> WARNING: Bad range parameter in for statement: too many elements >>> (2551818) in file Documents/OpenSCAD/libraries/BOSL2/math.scad, line 57 >>> WARNING: Bad range parameter in for statement: too many elements >>> (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 647 >>> WARNING: Bad range parameter in for statement: too many elements >>> (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 648 >>> WARNING: Bad range parameter in for statement: too many elements >>> (2551818) in file Documents/OpenSCAD/libraries/BOSL2/lists.scad, line 428 >>> >>> WARNING: Bad range parameter in for statement: too many elements >>> (2551818) in file Documents/OpenSCAD/libraries/BOSL2/vnf.scad, line 650 >>> >>> and then did not finish. >>> >>> Choked to death, I guess. >>> >>> >>> >>> >>> On Wed, May 11, 2022 at 4:27 PM Adrian Mariano <avm4@cornell.edu> wrote: >>> >>>> I think vnf_bend is pretty slow. It has to first cut up your input >>>> into strips (so that means line-plane intersections with every edge in >>>> your data) and then once that's done, it maps it to the cylinder, >>>> which is fairly fast in comparison. I have not done rigorous timing >>>> tests. I think time will mainly depend on the number of edges, so you >>>> could try using 1% of your faces and see how long it takes. The >>>> result will be garbage (a non-manifold partial result ) but it will >>>> give you some idea of time. Then you can try 2% and see what happens, >>>> 5%, etc. That will give you a way to predict how long your real >>>> problem will take. >>>> >>>> I think that you probably will need to find a way to simplify the >>>> problem, but the above exercise will tell you how much it needs to be >>>> simplified. >>>> >>>> On Wed, May 11, 2022 at 2:24 PM Joe Weinpert <joe.weinpert@gmail.com> >>>> wrote: >>>> > >>>> > >>>> > len( vnf[0] ) = 420204 >>>> > >>>> > len( vnf[1] ) = 823326 >>>> > >>>> > >>>> > If the length of the vnf array I am trying to bend is as large as >>>> what was echoed above, am I whistling past the graveyard to try and get >>>> this: >>>> > >>>> > >>>> > bent1 = vnf_bend( vnf, axis = "Y" ); >>>> > >>>> > >>>> > to work? Machine just stops forever until I force openSCAD to close. >>>> > >>>> > >>>> > _______________________________________________ >>>> > OpenSCAD mailing list >>>> > To unsubscribe send an email to discuss-leave@lists.openscad.org >>>> _______________________________________________ >>>> OpenSCAD mailing list >>>> To unsubscribe send an email to discuss-leave@lists.openscad.org >>>> >>> _______________________________________________ >>> OpenSCAD mailing list >>> To unsubscribe send an email to discuss-leave@lists.openscad.org >>> >>> >>> _______________________________________________ >>> OpenSCAD mailing list >>> To unsubscribe send an email to discuss-leave@lists.openscad.org >>> >> _______________________________________________ >> OpenSCAD mailing list >> To unsubscribe send an email to discuss-leave@lists.openscad.org >> > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org > > > > _______________________________________________ > OpenSCAD mailing list > To unsubscribe send an email to discuss-leave@lists.openscad.org >
JB
Jordan Brown
Thu, May 12, 2022 12:05 AM

On 5/11/2022 4:18 PM, Revar Desmera wrote:

420k vertices and 823k faces, bending with $fs=0.01… That is an
excessive degree of detail for OpenSCAD, I’m afraid.

$fs = 0.01 is really really small (assuming that BOSL2's use of it is
consistent with OpenSCAD's).

That's saying that you want each feature, each straight line in the
result, to be at least a hundredth of a millimeter, ten micrometers, long.

To put that in context:
Standard 20lb bond paper is about 100 micrometers thick.
A human hair is between 17 and 181 micrometers in diameter.
Typical 3D printer extrusion widths are around 400 micrometers.
Typical X-Y resolution is 100 micrometers.
Typical high resolution printing is 100 micrometers per layer.

I'd be shocked if you couldn't increase that to 0.1 without any visible
impact, and I wouldn't be surprised if you could increase it to 1.0
without visible impact.

On 5/11/2022 4:18 PM, Revar Desmera wrote: > 420k vertices and 823k faces, bending with $fs=0.01… That is an > excessive degree of detail for OpenSCAD, I’m afraid. $fs = 0.01 is really really small (assuming that BOSL2's use of it is consistent with OpenSCAD's). That's saying that you want each feature, each straight line in the result, to be at least a hundredth of a millimeter, ten micrometers, long. To put that in context: Standard 20lb bond paper is about 100 micrometers thick. A human hair is between 17 and 181 micrometers in diameter. Typical 3D printer extrusion widths are around 400 micrometers. Typical X-Y resolution is 100 micrometers. Typical high resolution printing is 100 micrometers per layer. I'd be shocked if you couldn't increase that to 0.1 without any visible impact, and I wouldn't be surprised if you could increase it to 1.0 without visible impact.