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:
Other parameters that can be swept can be found by
But you will still need to have available GUI license to run the simulation, though GUI can be not shown.
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.
- You must be logged in to reply to this topic.
Boost Ansys Fluent Simulations with AWS
Computational Fluid Dynamics (CFD) helps engineers design products in which the flow of fluid components is a significant challenge. These different use cases often require large complex models to solve on a traditional workstation. Click here to join this event to learn how to leverage Ansys Fluids on the cloud, thanks to Ansys Gateway powered by AWS.
Earth Rescue – An Ansys Online Series
The climate crisis is here. But so is the human ingenuity to fight it. Earth Rescue reveals what visionary companies are doing today to engineer radical new ideas in the fight against climate change. Click here to watch the first episode.
Subscribe to the Ansys Blog to get great new content about the power of simulation delivered right to your email on a weekly basis. With content from Ansys experts, partners and customers you will learn about product development advances, thought leadership and trends and tips to better use Ansys tools. Sign up here.
- “Import optical generation” or “delta generation rate”?
- Why am I getting “process exited without calling finalize”, and how do I fix it?
- Using a license file on a new license server
- Ansys Insight: Diverging Simulations
- Error: addfdtd is not a valid function or a variable name
- Questions about the calculation of the cross-polarization conversion efficiency of metasurface
- Finding your Ansys (or Lumerical) account number
- Error on Lumerical device
- Ansys Insight: About override mesh in FDTD: its use and settings
- Lumerical – error message when trying to open from Linux terminal
© 2023 Copyright ANSYS, Inc. All rights reserved.