Closed jinningwang closed 2 years ago
Kudos, SonarCloud Quality Gate passed!
Hi Hantao,
I prepared an example to demonstrate the TDS results save and load. However, I'm not sure how I realized it is the way you desired.
Further, I suggest setting a return handle of TDS.plt.export_csv()
. Maybe the output file name can be a good choice.
Another question is that I failed to follow the new feature "Plot tool works with in-memory time-series data specified by Output.", is there any clue to plot Output results?
Regards, Jinning
Merging #328 (a4bafb1) into develop (62253ba) will not change coverage. The diff coverage is
n/a
.
@@ Coverage Diff @@
## develop #328 +/- ##
========================================
Coverage 77.81% 77.81%
========================================
Files 169 169
Lines 14058 14058
========================================
Hits 10939 10939
Misses 3119 3119
Continue to review full report at Codecov.
Legend - Click here to learn more
Δ = absolute <relative> (impact)
,ø = not affected
,? = missing data
Powered by Codecov. Last update 62253ba...a4bafb1. Read the comment docs.
Thanks for putting it up!
Plot tool works with in-memory time-series data specified by Output
This is about the model `Output
for selecting the specific models and variables for specific devices to save. When Output
is used, the indices of the stored variables will change. Plot has been updated to work with systems that include Output
.
Jining, most of the notebook you provided can be integrated into ex1: Simulate and Plot.
Also, your use of from_csv
is very creative, but it's not meant to be used in this way. from_csv
was added when Qiwei needed to stream custom data. What it does is use the data provided by the CSV file as mock simulation data.
Data from the CSV will be processed identically to actual simulation data for processing. In a recent version, if ss.TDS.config.limit_store = 1
, the size of the time series will be limited. In this scenario, if data loaded from the CSV exceeds a certain size, the in-memory data will be a subset of the CSV data. Plotting will then be incomplete.
Also, if one uses Output
, reading from the CSV will error outright.
What actually needs to be done is to use the andes.plot.TDSData
class for reading from an npz
file and plotting the data.
Thanks, let me find the right way to do it.
Closing this PR due to inactivity.
Add an example for TDS save and load