How to unload DYR between simulations OR clear ICONs/CONs/VARs

asked Apr 4 '5

trc gravatar image

Having an issue where on looped test runs, the ICONs/CONs/VARs are never reset in index number, so they accumulate and eventually stop saving results once the index reaches the max allowed.

psspy.dyre_new([1,1,1,1],dyrfile,...etc) suggests that it will restart a dynamics run with 1 as the indices, but this does not appear to be true in practice.

Adding psspy.close_powerflow() to the beginning of each loop does nothing to resolve the issue.

Notably, each iteration after the first one says the .DYR is in use, leading me to conclude either I need to forcefully reset the indices somehow, or forcefully unload the DYR somehow.