respec / HSPsquared

Hydrologic Simulation Program Python (HSPsquared)
GNU Affero General Public License v3.0
43 stars 17 forks source link

Fix Issue#77 (saveall=false) bug #85

Closed ptomasula closed 2 years ago

ptomasula commented 2 years ago

Reference #77. This commit modifies the save_timeseries function to generate a list of the columns in the dataframe that should be saved and now passes the dataframe to the IOManager. The logic for selectively removing columns prior to export is now handled by the IOManager. However, the IOManager first caches the dataframe will all columns in memory prior to selectively dropping columns. This allows subsequent modules to access those timeseries without saving them to the output file.

aufdenkampe commented 2 years ago

@ptomasula & @PaulDudaRESPEC,

Given other commits on develop (see PR #86), I'm wondering if it might make sense to merge this into develop then test there.

PaulDudaRESPEC commented 2 years ago

Seems reasonable to me.

aufdenkampe commented 2 years ago

I'll do a little testing of all this, probably next week, when I update the tutorials with the new context manager approach described in https://github.com/respec/HSPsquared/issues/83#issuecomment-1018916429