Constructing class objects before the parfor loop
显示 更早的评论
Hi!
I am using OOP by constructing objects and running it multiple times within a while loop. In order to make the code faster, I pass my initial arguments to the class before the loop so it does not need to be initilized everytime.
I am tried switching the while loop to a parfor loop since I have multiple objects which I need to run independently every iteration. However, I am not able to initialize the objects before the parfor loop nor can I figure out how to call the objects after the loop since they are defined within the loop.
I am very new to oop so I might be wrong on many things and I would really appreciate the help.
Thanks!
采纳的回答
更多回答(0 个)
类别
在 帮助中心 和 File Exchange 中查找有关 Parallel for-Loops (parfor) 的更多信息
Community Treasure Hunt
Find the treasures in MATLAB Central and discover how the community can help you!
Start Hunting!