Ask Your Question
1

Importing self-made modules and PSSPY

asked 2013-05-28 15:09:47 -0600

Daniel gravatar image

Hi everybody.

I am trying to build a more o less complex set of scripts with PSSPY.

Usually with python I have a main.py and then several submodules (e.g. power_flow.py, dynamics.py ...).

However, this doesn't work when I am using PSSPY. I can either import PSSPY in the main.py or in one of the submodules. But if I try to call PSSPY functions from both, the interpreter will say that the functions I am trying to call doesn't exist.

Has anyone faced the same problem?

edit retag flag offensive close merge delete

1 answer

Sort by ยป oldest newest most voted
0

answered 2013-06-04 00:49:02 -0600

JervisW gravatar image

You'll need to tell Python where PSSE is installed. Otherwise it cannot find the psspy library.

There is a question about that here:

https://psspy.org/psse-help-forum/que...

To summarise that link, you'll need to append your pssbin folder to the sys.path variable before you can import psspy.

You should do this in your main.py before you start importing other modules that require psspy.

edit flag offensive delete link more

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.

Add Answer

[hide preview]

Question Tools

Stats

Asked: 2013-05-28 15:09:47 -0600

Seen: 673 times

Last updated: Jun 04 '13