Community
HSM Beta Testing (English / Deutsch)
cancel
Showing results for 
Show  only  | Search instead for 
Did you mean: 

New tool sorting algorithm for HSMWorks 2014 R3

10 REPLIES 10
Reply
Message 1 of 11
fonsecr
2430 Views, 10 Replies

New tool sorting algorithm for HSMWorks 2014 R3

We added a new algorithm to minimize the number of tool changes in the latest HSMWorks 2014 R3 development release.

It is an interesting algorithm which is equivalent to the common problem of the "Travelling salesman" when taken to the extreme. See this link if you are interested:
http://en.wikipedia.org/wiki/Travelling_salesman_problem

Luckily the problem for the common use cases is more manageable since the number of jobs/different work offsets will be low and the number of different tools used will likely not be that big (less than 50). But the number of solutions is still huge (could be 2^200 for some realistic examples) so it is not possible to find the best solution in reasonable time in general. But a good solution will likely be found very quickly (maybe within a few seconds).

The new algorithm also supports multi-core/CPU systems.

I have limited the number of solutions checked to 2*10^9 and the maximum time to 30 seconds. That seems to be a good limit for now.

Our HP ZBook 17 with Intel i7 2.80GHZ test system can do around 2*10^9 checks in 12 seconds. The algorithm doesn't use more memory than fits in the CPU cache which means it runs nicely on the multiple cores available for the CPU. And the CPU was actually able to run at 3.6GHz due to Intel Turbo Boost for my tests with multiple cores engaged. If you have older hardware you might see that the tool sorting will use all available 30 seconds before stopping.

René Fonseca
Software Architect

10 REPLIES 10
Message 2 of 11
cj.abraham
in reply to: fonsecr

;D

Message 3 of 11
Rob.Lockwood
in reply to: fonsecr

René Fonseca wrote:

We added a new algorithm to minimize the number of tool changes in the latest HSMWorks 2014 R3 development release.

It is an interesting algorithm which is equivalent to the common problem of the "Travelling salesman" when taken to the extreme. See this link if you are interested:
http://en.wikipedia.org/wiki/Travelling_salesman_problem

Luckily the problem for the common use cases is more manageable since the number of jobs/different work offsets will be low and the number of different tools used will likely not be that big (less than 50). But the number of solutions is still huge (could be 2^200 for some realistic examples) so it is not possible to find the best solution in reasonable time in general. But a good solution will likely be found very quickly (maybe within a few seconds).

The new algorithm also supports multi-core/CPU systems.

I have limited the number of solutions checked to 2*10^9 and the maximum time to 30 seconds. That seems to be a good limit for now.

Our HP ZBook 17 with Intel i7 2.80GHZ test system can do around 2*10^9 checks in 12 seconds. The algorithm doesn't use more memory than fits in the CPU cache which means it runs nicely on the multiple cores available for the CPU. And the CPU was actually able to run at 3.6GHz due to Intel Turbo Boost for my tests with multiple cores engaged. If you have older hardware you might see that the tool sorting will use all available 30 seconds before stopping.


Good read; I havent given it a shot yet, though.. are the development releases still in 'watch the output code closely' mode?


Rob Lockwood
Maker of all the things.
| Oculus | | Locked Tool | | Instagram |

Message 4 of 11
fonsecr
in reply to: fonsecr

Have the devel releases ever been anything else 🙂


Important: The downloads on this page are development releases which contain the latest features and fixes. The development versions are, however, not thoroughly tested, and therefore not suitable for production use.
For production work, please use the latest official version.


Anyway, no known issues have so far been reported or found for the post processor and it is expected to work like before. But that doesn't mean you should be lazy and not check the output.

René Fonseca
Software Architect

Message 5 of 11
Rob.Lockwood
in reply to: fonsecr

🙂 but when the developer goes out of their way to warn once again..

Good to know. I always stick to the major release, until the development offers up a shiny object.


Rob Lockwood
Maker of all the things.
| Oculus | | Locked Tool | | Instagram |

Message 6 of 11
Rob.Lockwood
in reply to: fonsecr

René Fonseca wrote:

We added a new algorithm to minimize the number of tool changes in the latest HSMWorks 2014 R3 development release.

It is an interesting algorithm which is equivalent to the common problem of the "Travelling salesman" when taken to the extreme. See this link if you are interested:
http://en.wikipedia.org/wiki/Travelling_salesman_problem

Luckily the problem for the common use cases is more manageable since the number of jobs/different work offsets will be low and the number of different tools used will likely not be that big (less than 50). But the number of solutions is still huge (could be 2^200 for some realistic examples) so it is not possible to find the best solution in reasonable time in general. But a good solution will likely be found very quickly (maybe within a few seconds).

The new algorithm also supports multi-core/CPU systems.

I have limited the number of solutions checked to 2*10^9 and the maximum time to 30 seconds. That seems to be a good limit for now.

Our HP ZBook 17 with Intel i7 2.80GHZ test system can do around 2*10^9 checks in 12 seconds. The algorithm doesn't use more memory than fits in the CPU cache which means it runs nicely on the multiple cores available for the CPU. And the CPU was actually able to run at 3.6GHz due to Intel Turbo Boost for my tests with multiple cores engaged. If you have older hardware you might see that the tool sorting will use all available 30 seconds before stopping.


Sending feedback, still not getting anything close to optimal.. 😞


Rob Lockwood
Maker of all the things.
| Oculus | | Locked Tool | | Instagram |

Message 7 of 11
fonsecr
in reply to: fonsecr

Yes, thanks.

René Fonseca
Software Architect

Message 8 of 11
fonsecr
in reply to: fonsecr

The sorting was effectively disabled. Fixed in the latest development release.

René Fonseca
Software Architect

Message 9 of 11
Rob.Lockwood
in reply to: fonsecr

René Fonseca wrote:

The sorting was effectively disabled. Fixed in the latest development release.


;D

Looks to be working quite well indeed!


Rob Lockwood
Maker of all the things.
| Oculus | | Locked Tool | | Instagram |

Message 10 of 11
fonsecr
in reply to: fonsecr

Yeah, after a few iterations 🙂

René Fonseca
Software Architect

Message 11 of 11
fonsecr
in reply to: fonsecr

From the next release, the tool reordering feature will also apply between jobs/setups that use the same work offset.

René Fonseca
Software Architect

Can't find what you're looking for? Ask the community or share your knowledge.

Post to forums  

Autodesk Design & Make Report