For all issues regarding the Forums use, please, refer to the Forum Rules.

Our Solutions

Need professional assistance?
Consider our:

Support Offerings

 

Need to speed up your development?
Have a look at our:

Samples & Tools

 

Need some functionality extending standard OCCT capabilities?
Check out our:

Adv. Components

Related pages

10000 cubes with Draw

davide ciarloni's picture
Forums: 

Hi

I am testing performances.
Here is my basic procedure (.tcl file)

box b 0 0 0 1 1 1
compound b cubes
for {set i 1} {$i copy b b$i
ttranslate b$i $i 0 0
add b$i cubes
}
save cubes c:/temp/10000cubes.brep

It takes hours for duplicating the cube.

Am I missing something?

thanks

Davide

jelle's picture

probably. in pythonocc this sort of things is pretty rapid...

davide ciarloni's picture

thanks

I am not a developer. I am just veryfing the performances.
If you did it, please post here a .brep with 10.000 cubes.
The cube is
box b 0 0 0 1 1 1
the increment, in x only, is 1

thanks in advance

davide

jelle's picture

> I am not a developer. I am just veryfing the performances

I'm sorry that's impossible ;)

P Dolbey's picture

Sorry jelle, but that's called testing and is often carried out by people other than developers - we call them testers :)

Peye

P Dolbey's picture

er, should say Pete

jelle's picture

yes / no; a tcl test is not representative of OCC's execution speed, wouldnt you say?
[ but your right, my reply wasnt very constructive / on the verge of rude, sorry... ]

P Dolbey's picture

It's a test of creating 10,000 boxes using a scripting language and as such does excecute only a very small amount of the total OCC library, which doesn't give an overall indication of performance (or find performance hotspots). However, its a simple test that can be carried out similarly in the scripting languages of other CAD/CAE apps or libraries and as such could provide a relative measure of performance against other vendors products - as you might carry out in a product selection excercise.

Pete

Denis Barbier's picture

If you add some echo statement in the loop, you will see that it slows down at each iteration. The most obvious culprit is compound, you should move this command away from the loop:

box b 0 0 0 1 1 1
set boxes "b"
for {set i 1} {$i copy b b$i
ttranslate b$i $i 0 0
lappend boxes "b$i"
}
eval compound $boxes cubes

davide ciarloni's picture

many thanks Denis

it worked fine

my goal was just to generate a native .brep file with 10.000 cubes

thanks!

davide