Replies: 9 comments 1 reply
-
The main recent change was that we don't calculate shrunk instrument correlation matricies, but instead shrink them when they are used for DO. This involves making a copy of the correlation matrix before shrinking it, so it will be increasing memory usage. It might be that this pushes you into memory issues. I'd advise trying with a smaller set of instruments to see if it will run. If this turns out to be the problem then it might be worth thinking about some backtest memory optimisations. |
Beta Was this translation helpful? Give feedback.
-
I realize this is an old thread but I find myself running into it now that I've tried running backtests with many more instruments and estimating forecast/instrument weights. It always crashes in the first dozen optimizations. I have 32GB memory, intel i3-12100. If I run a much smaller list of instruments it'll usually finish running. |
Beta Was this translation helpful? Give feedback.
-
FWIW, I have had similar issues for a while. I used to run another application on my trading machine that used a lot of memory, so I just chalked it up to trying to do too much with an underpowered machine (8GB RAM), and I limited my system to around 40 instruments. I also found that saving (pickling) the backtest basically doubles the amount of RAM required. I've disabled this, and instead have modified the code to immediately produce a strategy report using the system object that is already in memory. Of course, that means I don't have any saved backtests, so this may or may not work for others. I have recently moved that memory-hogging application to a different machine. Just to give you a rough ballpark, with my 8GB RAM (and not saving the backtest), I'm currently running my system with about 85 instruments. I know that it definitely runs out of memory with 145 instruments, but I haven't tried to see how far I can push it between those numbers. |
Beta Was this translation helpful? Give feedback.
-
The backtest was with 199 instruments and my machine can't handle it. My live system has 140-ish or so and runs fine. The memory requirements for the daily run_system method seems lighter too since it's not estimating weights. |
Beta Was this translation helpful? Give feedback.
-
Wouldn't it be better to do the estimation and optimisation separately? Do the estimation with a static system, then copy the config values into your DO setup |
Beta Was this translation helpful? Give feedback.
-
This is probably ignorance on my part but when I run a backtest using just the base system with all instruments I still crash when estimating correlations. |
Beta Was this translation helpful? Give feedback.
-
I use static forecast & instrument weights, etc. But toward the end of the backtest, the are 3 or 4 progress bars about estimating correlations. Probably related to DO. That is where it crashes for me. (Sorry, not at my desk right now.) This may or may not be the same place @oldlore is seeing the crash. If I recall correctly, even Rob, with beefier machines than both of us, said he can't estimate forecast weight for all instruments at once. |
Beta Was this translation helpful? Give feedback.
-
Maybe I'm doing this wrong. If so, perhaps someone can help. My current DO system has ~140 instruments with fixed FWs and IWs. I've been working on adding a bunch (~40) new instruments to DO and updating to the new autogroup methodology for calculating FW/IWs. However, I need new FDMs for the instruments. But whenever I run a backtest to estimate these (using the autogroup for FW/IWs) it gives me a bunch of FDMs that are almost all the same. I'm not sure if this is a mistake in how I'm running the backtest or a consequence of using the new FW methodology? So I tried estimating everything to see if the results would change but this gets us back to the crashing problem above.
For comparison, these are some of my current FDMs
Thanks. |
Beta Was this translation helpful? Give feedback.
-
Beta Was this translation helpful? Give feedback.
-
Hello All
I recently updated to 0c1033e
and in running a DO backtest have repeatedly got this:
and no further calculations are done.
This is not always at the same instrument previously CAC , COPPER.
The config is attached as a text file.
config_yaml.txt
There are no error messages.
Prior to the update, this worked.
Any ideas?
Beta Was this translation helpful? Give feedback.
All reactions