setup_base_simulation#
- Project.setup_base_simulation(fdtd_session: FdtdSession = None, params: ndarray = None, lock_grid: bool = False) None#
Return the FDTD session to the base setup.
Can provide an optional FDTD session (e.g. with CAD shown) for visualization purposes. If none is provided, uses the project’s own FDTD session.
- Parameters:
- fdtd_session
FdtdSession,optional FDTD session to configure. If None, the project’s own session is used.
- params
np.ndarray,optional Parameter array to apply to the geometry. If None, geometry is loaded without updating parameters.
- lock_gridbool,
optional If True, re-applies the locked mesh settings after loading the base simulation. Use this when reverting to the base setup mid-optimization to keep the mesh consistent across iterations (default: False).
- fdtd_session
- Raises:
RuntimeErrorIf no FDTD session is available or the base simulation cannot be set up.