First time here? We are a friendly community of Power Systems Engineers. Check out the FAQ!

Ask Your Question
1

File ".\pssexcel.py", line 1472, in accc

asked May 21 '13

Christian gravatar image

updated May 23 '13

JervisW gravatar image

I am working with script to run ACCC activity, but reports this error:

Traceback (most recent call last):
  File "E:\BACK_UP\DIC14-DMAX-EXP-NORTE\ACCC.py", line 84, in <module>
    baseflowvio=True, basevoltvio=True, flowlimit=100.0, flowchange=5.0, voltchange=0.04)
  File ".\pssexcel.py", line 1472, in accc
IndexError: list index out of range
>>>

can somebody tell me why this problem occurs and how to fix it?

Comments

A snippet of your code would be helpful.

Eli Pack gravatar imageEli Pack (May 22 '13)

Agree with Eli. From here it looks like there is a bug in PSSE's pssexcel.py module. PSSE don't distribute the raw source code for their Python. Instead shipping the bytecode compiled files. Of course, we can still work their pyc file back into a .py, it's just another step.

JervisW gravatar imageJervisW (May 23 '13)

1 answer

Sort by » oldest newest most voted
0

answered May 23 '13

JervisW gravatar image

I had a look at the accc funtion. It's 650 lines long.

and there is a lot of this type of code:

if accshts['phase shifter angle'][0]:
        sht = accshts['phase shifter angle'][0]

Which means if the list element for accshts and key phase_shifter_angle is empty then you'll get the IndexError.

It would be a really difficult bug to track down given the circumstances. If you are desperate to fix the bug, start with a smaller accc study and see if that works. You may find that the size of the study is a problem. Or perhaps some combination of your arguments to the accc function.

You may find just writing the data to a CSV file will be quicker.

link

Your Answer

Please start posting anonymously - your entry will be published after you log in or create a new account.
Want to format code in your answer? Here is a one minute demo on Youtube

Add Answer

[hide preview]

Question Tools

Stats

Asked: May 21 '13

Seen: 260 times

Last updated: May 23 '13