Lumerical Python API

Dear colleagues,

I was exploring the novel opportunities provided by the Python integration in Lumerical, when I encountered the following mistake:

LumApiError: 'Invalid directory name passed to cd Note: Vector arguments expect numpy arrays’

The sample script was taken from Lumerical Knowledge Base (https://kb.lumerical.com/interop-python-api.html).

Please, if you know how to fix the problem, provide your comments.
Many thanks in advance!!!

@snigirev.vs14,

Welcome to Lumerical Knowledge Exchange.

Please check out our Python API setup/configuration guide:

We recommend using the supplied Python installation and running the scrips from within our script environment.
image

Best,
Lito

Thank you very much for your swift response!

I tried to launch the code in the Lumerical script editor, as you proposed, however, it still indicates the same mistake:

I suppose that something may be wrong with the code itself, but I have no clue what exactly should be done.

Maybe, there is another issue preventing the code from working, so that, if you have got an idea of what is going on, please, share it.

I have updated the version of my Lumerical products to 2019b. Now that everything has been set as it is suggested in the Python Integration article, the mistake type is different:

How would you propose to handle it?

@snigirev.vs14,

Please try to check if the API is working by:

  1. Using the Python provided by Lumerical (shown in the Python integration status.
  2. Open and run the script provided. test-win.py (469 Bytes)
  3. This should open a new FDTD instance and run the rest of the python script.

Please send us the screenshot of your Python integration status.

Best,
Lito