cvxportfolio icon indicating copy to clipboard operation
cvxportfolio copied to clipboard

Suggestion: return concise SimulationResult object

Open kch382001 opened this issue 5 years ago • 0 comments

SimulationResult object contains policy and simulator objects. Both take a lot of spaces. This is causing problem if we run parameter tuning codes because many SimulationResult object will be created and co-exist in memory. I suggest we add in an option to return concise version of SimulationResult object(remove policy and simulator objects and keep only the relevant simulation metrics). Here is what I can think of:

In run_backtest and run_multiple_backtest function in policies.py run_backtest(....., return_concise_results=False, ...) ..... if return_concise_results: results = results.concise_version return results

run_multiple_back_test(..., return_concise_results=False, ...)

Then in SimulationResult.py @property def concise_version(self): self.policy=None self.simulator = None return self

kch382001 avatar Oct 03 '19 14:10 kch382001