OPF.load_json#
- OPF.load_json(path)#
Load scheduling results from a json file.
- Parameters:
- pathstr
Path of the json file to load.
- Returns:
- bool
True if the loading is successful, False otherwise.
Notes
Differences from ANDES: ANDES has no direct analog for post-solve result rehydration. The closest related facility is
andes.routines.tds.TDS.run()withfrom_csv=, but that replays a time-domain trajectory through the integrator rather than restoring solved values into post-solve storage. AMS reads scheduling results back into existingVarandExpressionCalcstorage and marks the routine as converged so subsequentget()andams.system.System.report()calls behave as if the routine just solved.Added in version 1.0.13.
Changed in version 1.3.0: A successful load now sets
self.converged = Trueandself.exit_code = 0. Callers that loaded "candidate" results into a scratch system and relied onconverged == Falseshould reset the flag explicitly after the load.