TAGGED: linux-cluster, optimization, RCWA
-
-
October 11, 2023 at 10:46 amAli VafaSubscriber
I am trying to optimize a periodic structure using the built-in optimization tools based on results from the RCWA solver, and I can successfully do that in the GUI. However, for obvious reasons, I would like to run the optimization in the background for a longer time. Is there a way to do that either locally or on a cluster with Slurm?Â
Â
Â
-
October 11, 2023 at 6:53 pmGuilin SunAnsys Employee
It is doable but a little complicated.
First, you need to know how to run script file in background. please refer to Installing and running Lumerical on Linux without GUI
second, you need to specify the sweep parameters in "model" or structure group. If you want to sweep the layer thickess, you need to use script such as
setnamed("RCWA","interface absolute positions",[-2.25e-7+t1,4.3e-7+t2,1.1e-6+t3]);
where t1,t2, and t3 are the thickness parameters ( I have initial values there) you specify in "Setup" "Script".
please test them before run sweep.
then set the sweep object to sweep the parameters.
finally, you need to write a simple script file with this line:
runsweep;
https://optics.ansys.com/hc/en-us/articles/360034931413-runsweep-Script-commandÂ
Other parameters that can be swept can be found by
?getnamed("RCWA").
But you will still need to have available GUI license to run the simulation, though GUI can be not shown.
Please try.
Â
Â
-
October 12, 2023 at 3:20 pmAli VafaSubscriber
Thank you for your reply.
I already have the steps you mentioned ready, i.e., the optimisation parameters are defined in the "model" object and the RCWA interface absolute coordinates are defined in the "setup script" of the "model" object, as you mentioned. Then, I configure the sweep settings by adding these parameters to the list of "Parameters", as shown below.
And, I can successfully run the optimisation in the GUI. However, I do not understand the final step you mentioned. If I add "runsweep();" to the script file, which is a *.lsf file, how can I run it in the linux terminal? Even the link you have provided says GUI is required to run scripts.
And if I just save the .fsp file and run it in the terminal using /opt/lumericalv232/bin/rcwa-engine-mpich2nem *.fsp, it will not run the sweep and only runs the RCWA solver for the current configuration.
Is this what you meant, or am I missing something?
-
October 12, 2023 at 4:23 pmGuilin SunAnsys Employee
Please refer to this page  https://optics.ansys.com/hc/en-us/articles/360024974033
You might be able to run the script file without GUI but with the GUI license available. Please try.
-
- The topic ‘Running Optimization in the background based on RCWA results’ is closed to new replies.
- Difference between answers in version 2024 and 2017 lumerical mode solution
- Errors Running Ring Modulator Example on Cluster
- Import material .txt file with script
- Trapezoidal ring
- Help for qINTERCONNECT
- Absorption cross-section of AuNR excited by prism-based TIR
- Issues with getting result from interconnent analysis script
- Topology Optimization Error
- How to measure transmission coefficients on a given plane .
- Edge Coupler EME Example Issue
-
1727
-
624
-
599
-
591
-
366
© 2025 Copyright ANSYS, Inc. All rights reserved.