MATLAB 2024 default number of threads

조회 수: 29 (최근 30일)
Fadhel Alsaffar
Fadhel Alsaffar 2025년 3월 3일
답변: Edric Ellis 2025년 3월 4일
Hello,
I have 16 logical threads in my system but matlab rejects to use more than 8. How can I increase the limit. I used to be able to control it in 2022 version, but once I upgraded to 2024 I could not use more than 8.
  댓글 수: 2
Walter Roberson
Walter Roberson 2025년 3월 3일
Could you confirm that you are using the Parallel Computing toolbox, and that you are talking about BackgroundPool (thread-based) instead of about Parpool (process-based) ?
Fadhel Alsaffar
Fadhel Alsaffar 2025년 3월 3일
Yes, I'm using Parallel Computing toolbox with thread-based not process-based.

댓글을 달려면 로그인하십시오.

답변 (2개)

Walter Roberson
Walter Roberson 2025년 3월 3일
If you have a license for Parallel Computing Toolbox, NumWorkers is equal to the number of physical cores you have. For example, if you run MATLAB on a machine with four physical cores, the value is 4. You can reduce this value using maxNumCompThreads before first usage of backgroundPool.
So you cannot increase the number of threads beyond the number of physical cores your system has.
  댓글 수: 1
Fadhel Alsaffar
Fadhel Alsaffar 2025년 3월 3일
Thanks for your answer. I have 16 physical cores. I can run process-based parpool with 16 workers but not more than 8 with thread-based.
I tried to use maxNumCompThreads to change it from 8 to 16 or 12 but could not.

댓글을 달려면 로그인하십시오.


Edric Ellis
Edric Ellis 2025년 3월 4일
You can change the maximum number of workers to use with a thread pool by modifying the NumWorkers property in the "Cluster Profile Manager". This will allow you to run a thread pool of size 16.

카테고리

Help CenterFile Exchange에서 Parallel Computing Fundamentals에 대해 자세히 알아보기

제품


릴리스

R2024b

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by