How to Implement Parallel Computing Toolbox while Using Simulink Design Optimization

1 view (last 30 days)
Good day. I am currently learning how use Simulink Design Optimization toolbox. The model that I would like to estimate has around 30 parameters (including initial conditions/states), so it will take hours to estimate those parameters.
In order to shorten the estimation period, I decided by implementing the Parallel Computing Toolbox. However, the only reference that I found so far is one example in Matlab's website and user's manual ( http://www.mathworks.com/help/sldo/examples/improving-optimization-performance-using-parallel-computing.html?prodcode=SO&language=en )
The original code (without using Parrallel Computing Toolbox) that I wrote for Simulink Design Optimization setting is as follows:
opt = sdo.OptimizeOptions;
opt.Method = 'lsqnonlin';
While running the code, below is what happened:
Optimization started 21-Aug-2016 01:13:03
Step-size First-order
Iter F-count f(x) optimality
0 11 2.9044e+06 1
1 22 193518 9.607 2.05e+04
2 34 170966 0.2278 1.35e+04
3 46 169797 7.822 1.15e+04
4 57 160630 20 8.06e+03
5 69 158108 40 7.32e+03
6 80 154059 80 5.72e+03
7 92 151884 0.1198 5.24e+03
8 104 144929 143.9 3.13e+03
9 115 144929 160 3.13e+03
10 126 143223 40 2.78e+03
11 138 141226 79.09 2.39e+03
12 150 127748 7.384 345
13 162 122379 20.62 47.5
14 174 122379 120.7 47.5
15 186 122335 30.16 47.5
Local minimum possible.
lsqnonlin stopped because the final change in the sum of squares relative to
its initial value is less than the selected value of the function tolerance.
After that, I modified the previous Simulink Design Optimization setting to enable Parrallel Computing Toolbox. Based on the example that I mentioned before ( http://www.mathworks.com/help/sldo/examples/improving-optimization-performance-using-parallel-computing.html?prodcode=SO&language=en ), I added 2 additional commands to the settings, which are as follows:
opt = sdo.OptimizeOptions;
opt.Method = 'lsqnonlin';
opt.UseParallel = 'always';
opt.OptimizedModel = 'one_wall';
However, I think the estimation algorithm does not work because it does not estimate the parameter at all. The toolbox stops at 0 iteration. The output of the estimation is as follows:
Starting parallel pool (parpool) using the 'local' profile ... connected to 2 workers.
Configuring parallel workers for optimization...
Parallel workers configured for optimization.
Optimization started 21-Aug-2016 01:33:42
Step-size First-order
Iter F-count f(x) optimality
0 1 2.9044e+06 1
Initial point is a local minimum.
Optimization completed because the size of the gradient at the initial point
is less than the selected value of the function tolerance.
Removing data from parallel workers...
Data removed from parallel workers.
I hope anyone here can help to guide me if there is any other setting that I am suppose to do in order to activate the Parallel Computing Toolbox. Feel free to inform me if you would like to see my complete source code of the Simulink Design Optimization Setting.
Thank you very much.

Answers (0)

Categories

Find more on Simulink Design Optimization 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!