Skip to content

Latest commit

 

History

History
34 lines (17 loc) · 1002 Bytes

File metadata and controls

34 lines (17 loc) · 1002 Bytes

Howto BF-MT-001: Multitasking - Parallel Algorithms

.. automodule:: mlpro.bf.examples.howto_bf_mt_001_parallel_algorithms


Prerequisites

Please install following packages to run this howto

Executable code

.. literalinclude:: ../../../../../../../../../src/mlpro/bf/examples/howto_bf_mt_001_parallel_algorithms.py
        :language: python



Results

The howto example logs details of the three runs and in particular the speed factors of multithreading and multiprocessing in comparison to the serial/synchronous execution. On a PC with an AMD Ryzen 7 CPU (8/16 cores) running Linux, the system monitor shows an approx. 5x speedup with multithreading and an approx. 18x speedup with multiprocessing.

images/howto.bf.mt.001/howto_bf_mt_001_parallel_algorithms.png

Cross Reference