Hi,
I am having the same problem with FDTD 2022R1.01 that I installed on the HPC cluster of our university.
Running FDTD via the Python API on a login node works, but as soon as I try to submit the same as batch job through Slurm, I get the error:
Traceback (most recent call last):
File "test_sim_joblist.py", line 22, in
fdtd = lumapi.FDTD()
File "/cluster/apps/nss/fdtd/2022R1.01/x86_64/opt/lumerical/v221/api/python/lumapi.py", line 1371, in __init__
super(FDTD, self).__init__('fdtd', filename, key, hide, serverArgs, **kwargs)
File "/cluster/apps/nss/fdtd/2022R1.01/x86_64/opt/lumerical/v221/api/python/lumapi.py", line 1093, in __init__
self.handle = open(product, key, hide, serverArgs)
File "/cluster/apps/nss/fdtd/2022R1.01/x86_64/opt/lumerical/v221/api/python/lumapi.py", line 239, in open
raise LumApiError(error)
lumapi.LumApiError: 'appOpen error: \n Failed to start messaging, check licenses.../cluster/apps/nss/fdtd/2022R1.01/x86_64/opt/lumerical/v221/bin/fdtd-solutions: line 8: 75535 Aborted $FDTD_BIN_DIR/fdtd-solutions-app "$@"\n'
The license configuration is correct (I can open the GUI without any error message). I think that the error is caused by fdtd trying to open a graphical window in a batch job (which will obviously not work).
Is it possible to run FDTD via the Python API in batch mode without opening a graphical window?
I can workaround the problem by using a virtual framebuffer (Xvfb), that provides a fake graphical frontend, but it would be nice to have a clean solution. Can you please add some option in the Python API to be able to run computations in batch mode without opening any graphical windows? This would make it much simpler to use the software on an HPC cluster.
Best regards
Samuel Fux