-
-
October 31, 2024 at 1:43 pmluh1Subscriber
Hi, I am using the SFWM example on Spontaneous Four-wave Mixing (SWFM) Microring Resonator Photon Source – Ansys Optics. I am confused about how to run the python script. It returns syntax error when I put the code in Script file editor in Interconnect, and it returns "No module named 'qinterconnect'" when I run it in jupyter notebook.
-
October 31, 2024 at 4:12 pmGuilin SunAnsys Employee
qINTERCONNECT needs a separate license. So the first thing is to check if you have the license. You can also run an online example to make sure it works fine.
then, follow the Python example to import it: https://optics.ansys.com/hc/en-us/articles/360050995394-Getting-Started-with-lumopt-Python-API
If you have the license and the example file works, please paste your script here so I may have the time to diagnose the issue for you.
Â
-
October 31, 2024 at 6:35 pmluh1Subscriber
Thank you for answering! The python script is from the SFWM example on Ansys website: Spontaneous Four-wave Mixing (SWFM) Microring Resonator Photon Source – Ansys Optics. I download Python 3.13 version but I never used it before. I don't know how to use the python script for the interconnect simulation, and I think I can only use the script with an external IDE since I have only one license. Should I type the following similar code in the IDE? Thank you.
-
October 31, 2024 at 7:31 pmGuilin SunAnsys Employee
You have the license so you should be able to directly run the simulation file, without Python. For Python, it does not need special settings for license. However you will need to set proper path, https://optics.ansys.com/hc/en-us/articles/360041873053-Session-management-Python-API.
Here is the list of articles you can refer to  https://optics.ansys.com/hc/en-us/articles/360037824513-Python-API-overview
Maybe your python version is too high? we use version 3 but no other details.
Usually we suggest people to use our built-in python.
Â
-
- You must be logged in to reply to this topic.
- Assistance Needed for Wavelength Adjustment in Optical Ring Modulator Simulation
- Optic studio-zemax operand values are different from the plot (Genc and Denc)
- STEP File Exports
- Rotation of cylindrical lens affects other surfaces
- Issue when evaluating Ansys Academic Research Optics License
- RMS spot size interpretation
- Matlab linkage Zemax memory overflow problem
- Plot coupling coefficient versus power from power meter
- Relay Lens Optimization
- ZEMAX CAD export problems with tilted surfaces
-
1301
-
591
-
544
-
524
-
366
© 2025 Copyright ANSYS, Inc. All rights reserved.