I have a passion for optimization! And I enjoy automating tasks. Consequently, I really admire the Design Manager in Simcenter STAR-CCM+. Because:
“Design Manager provides an automated approach within Simcenter STAR-CCM+ to run design exploration studies.”
Variation of parameters and their affect on the performance of your engineering product is usually inevitably. Design space exploration gives valuable insight to find potential designs and to understand interrelation between parameters and performance. Design Manager allows you to quickly set up design sweeps with pre-defined parameters sets or optimizations where the algorithm determines the input conditions automatically in order to improve. Design Manager allows you to automate those two design exploration processes and lets you easily manager and quickly extract insights.
Design Manager STAR-CCM+
The following diagram gives you an overview of the design exploration process in Simcenter STAR-CCM+:
To run several evaluations requires of course resources. Both computation time and licenses. That´s the catch and the bottleneck in an engineer’s life. To shorten the lead time, parallel computer and cluster solutions can help. But most cluster schedulers only account for the hardware resources. In case your Simcenter STAR-CCM+ license pool is finite (essential when you are NOT using PoD license), you must decide:
- Work interactively within Simcenter STAR-CCM+
- Run an automated design exploration with the Design Manager.
Here is an example how you will be able to schedule you Design Manager job submission depending on your office hour. This works on Linux clusters and workstations with the help of the submission script. In my example I simply inquire the current day and time in the submission script and allow for submission only outside office hours.
However, when you run locally on your workstation a submission script is not needed. Yet, in this case I feign submission to the cluster que to compel STAR-CCM+ to be started through a script.
Here is the submission script that schedules the submission of local jobs depending on the date and time.
#!/bin/bash while :; do if [[ $(date +%u) -gt 5 ]]; then #submit right away echo "submitted on weekend" >> ~/debug.log STARCASE=$(cat dm_design_execute_options.txt) CASELOG=$(cat dm_design_output_info.msg) echo $STARCASE >> ~/debug.log echo $CASELOG >> ~/debug.log starccm+ $STARCASE -np 10 >> $CASELOG echo "Design done!">> ~/debug.log exit 0 else #submit after office hours currenttime=$(date +%H%M) echo $currenttime >> ~/debug.log if [[ "$currenttime" < 0800 ]] || [[ "$currenttime" > 1630 ]]; then #submit outside office hours echo "submited during office hours" >> ~/debug.log STARCASE=$(cat dm_design_execute_options.txt) CASELOG=$(cat dm_design_output_info.msg) echo $STARCASE >> ~/debug.log echo $CASELOG >> ~/debug.log starccm+ $STARCASE -np 10 >> $CASELOG echo "Design done!">> ~/debug.log exit 0 else echo 'wait...' >> ~/debug.log sleep 1h fi fi done
It checks first the week day:
- if lager than 5 (Friday), it’s a weekend
In case it is a weekday the second statement checks the clock and submits only if the time is not between 08:00-16:30. If none of statements is true the scripts waits for an hour. Once the a statement returns true, STAR-CCM+ is started in the temporary job directory. The command line command contains also the parallel options, hence the Compute Processes in STAR-CCM+ are over written.
starccm+ $STARCASE -np 10 >> $CASELOG
The Design Manager server does not interact with the script or a job scheduler on a cluster. For this reason, in my job submission script, we must read the following files from .mdxruntime/$project/$study/$design and redirect them to the Design Manager server:
This file contains additional command line options, such as license details, and other options that you define in the design study settings.
This file contains the name of the log file that Design Manager expects to be available when the design simulation executes.
In the script I read these files with the cat command in variables. The outcome of such a submission could lock like this:
submited during office hours Design done! 1206 wait... 1306 wait... 1406 wait... 1506 wait... 1606 wait... 1706 submited during office hours -batch mdxrun,Design_1.mdxin staticMixer_reference.sim Design_1.log Design done!
I hope you can make use of this scheduler. Please do not hesitate to contact me at florian.vesting(at)volupe.com or at support(at)volupe.com.
Release of Simcenter STAR-CCM+ 2020.2 part 4