Ask Your Question
1

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

asked 2013-05-21 00:34:47 -0500

Christian gravatar image

updated 2013-05-23 08:22:31 -0500

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?

edit retag flag offensive close merge delete

Comments

A snippet of your code would be helpful.

Eli Pack gravatar imageEli Pack ( 2013-05-22 00:22:01 -0500 )edit

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 ( 2013-05-23 08:25:02 -0500 )edit

1 answer

Sort by ยป oldest newest most voted
0

answered 2013-05-23 08:46:13 -0500

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.

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-21 00:34:47 -0500

Seen: 259 times

Last updated: May 23 '13