How to limit CPU availabilty to Matlab
40 ビュー (過去 30 日間)
表示 古いコメント
When i running Matlab simulation on my Linux PC (20 cores), it consuming all cores, is there any way to limit CPU availability to Matlab (Use only 10 cores).
0 件のコメント
回答 (2 件)
Dhritishman
2022 年 6 月 15 日
編集済み: Dhritishman
2022 年 6 月 15 日
LASTN = maxNumCompThreads(N)
sets the maximum number of computational threads to N, and returns the previous maximum number of computational threads, LASTN. N in your case is 10.
You can also use
LASTN = maxNumCompThreads('automatic')
which will set the maximum number of computational threads to the most desirable number according to MATLAB.
You can read more about it here:
0 件のコメント
参考
カテゴリ
Find more on Startup and Shutdown in Help Center and File Exchange
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!