There may have been an issue running Python file
asked 2024-11-08 12:41:28 -0600
Anonymous
When I am trying to run python file this error is appearing. Please anyone who can help me out?
First time here? We are a friendly community of Power Systems Engineers. Check out the FAQ!
asked 2024-11-08 12:41:28 -0600
Anonymous
When I am trying to run python file this error is appearing. Please anyone who can help me out?
You mentioned that Pythion in not installed on your laptop. Normally when you install PSSE it offers you the option to install Python at the same time. I would recommend that approach. It normally installs here: C:\Program Files (x86)\PTI\PSSE34
Once it is installed, you have two options:
To test whether you have it installed correctly, you could try running the PSSE Environment Manger. This is written in Python, so if it runs you are OK. Or you could go to the I/O menu, record a PSSE command as a python scrip, then run your newly created script.
If you want to install Python separately, you could go to python.org and download it. Be aware that the python version you use depends on which PSSE version you are using; for PSSE 34, use Python 2.7 You would also need to install the PSSE's Python libraries (like psspy). I haven't tried, but they should be installable using "pip install psspy"
No, the Python is unavailable in my laptop. is this the reason that I could not run my scripts?
In PSSE 34, you can use later python versions.
Eg launch GUI with this command
>"C:\Program Files (x86)\PTI\PSSE34\PSSBIN\psse34.exe" -pyver 37
or running from python, change the location PSS/E is loaded from:
PSSE_LOCATION = r"C:\Program Files (x86)\PTI\PSSE34\PSSPY37"
If multiple version of python are installed, make sure the python script is compatible with the python version in use. If problem persist, re-install PSSe.
Asked: 2024-11-08 12:41:28 -0600
Seen: 261 times
Last updated: Nov 13