Ask Your Question

Revision history [back]

click to hide/show revision 1
initial version

How to avoid program abortion if the largest mismatch exceeds mismatch tolerance?

Hello all,

Does any one know how to instruct PSS\E not to abort the ACCC process if largest mismatch exceeds mismatch tolerance. Right now, I am running ACCC on different number of network data and I am required to use a fixed mismatch tolerance of 0.6. I wrote an automatic python code to run ACCC on different data, so without any prior knowledge of each data, I consistently supply 0.6 as the largest system mismatch for ACCC. Somehow, this tolerance is too small to run ACCC correctly on some data. And the program aborted even though I used code below:

# perform ACCC without dispatch model for branch contingency
accc_ierr = psspy.accc_with_dsp_2(0.6, [0,0,0,1,2,1,0,0,0,0], _s, conFileName1+'.dfx', conFileName1+'.acc', _o, _o)
outfile = open('outfile.txt", 'w')               
if accc_ierr != 0:
    outfile.write("accc_with_dsp_2_ierr_brn=" %(accc_ierr))
else:
    smry = pssarrays.accc_summary(conFileName1+'.acc')

I was expecting that PSS\E will just simply output the error code to an text file without aborting the program even there is some error (i.e. largest mismatch is exceeded). Actually this is not working. Does anyone know a way to fix this problem?

Thanks very much.

How to avoid program abortion if the largest mismatch exceeds mismatch tolerance?

Hello all,

Does any one know how to instruct PSS\E not to abort the ACCC process if largest mismatch exceeds mismatch tolerance. Right now, I am running ACCC on different number of network data and I am required to use a fixed mismatch tolerance of 0.6. I wrote an automatic python code to run ACCC on different data, so without any prior knowledge of each data, I consistently supply and I supplied 0.6 as the largest system mismatch for ACCC. ACCC for each data. Somehow, this tolerance is too small to run ACCC correctly successfully on some data. And the program aborted even though I used code below:when I tried to deal with this exception like below:

# perform ACCC without dispatch model for branch contingency
accc_ierr = psspy.accc_with_dsp_2(0.6, [0,0,0,1,2,1,0,0,0,0], _s, conFileName1+'.dfx', conFileName1+'.acc', _o, _o)
outfile = open('outfile.txt", 'w')               
if accc_ierr != 0:
    outfile.write("accc_with_dsp_2_ierr_brn=" %(accc_ierr))
else:
    smry = pssarrays.accc_summary(conFileName1+'.acc')

I was expecting that PSS\E will just simply output the error code to an text file without aborting the program even there is some error (i.e. largest mismatch is exceeded). Actually this is not working. Does anyone know a way to fix this problem?

Thanks very much.