- ago
Trying to check a few simple optimizations for percent profit and the optimizer just keeps spinning. does not seem to be working. also shrinking window is being used.
0
369
Solved
18 Answers

Reply

Bookmark

Sort
- ago
#1
There are not enough details about the "few simple optimizations". Have you updated the DataSet? Data load may be still in progress. What are the parameters, the data range and other Strategy settings? Attaching some screenshots could help.
0
- ago
#2
I am using the building blocks. I was trying to run to following.

constants:
SP 500 data, 20 yr.
ROC 100 days
Positions 6
spy over 80 ema
Bars held 100 days

Variable:
% Profit 1 to 200 by 1

The optimizer would not work. I tried again this morning without success.
0
- ago
#3
What do you mean ROC 100 days? What Building Block rule? Can you share a screen shot of the design surface?

Also, did you first try optimizing on a single symbol instead of the entire S&P 500 (which is about 1000 stocks with all the delisted and stocks that went out of the index?)
0
- ago
#4
"Would not work" just does not work. Can you take a screenshot to illustrate what's going on there (data being collected, an error, whatever)?
0
- ago
#5
not sure if the pic will post.


0
- ago
#6
OK that's a start. What's happening with the Optimization dialog then?
0
- ago
#7
Normally when I run studies like this it only takes about 20 minutes or so to get the results. some of the more complicated studies can take hours to get results. I would expect this one to take about 20 min. However, on this one (pic above) the optimizer wheel keeps spinning and no results are achieved. it does not even give me an estimated time to get the results.
0
- ago
#8
Not sure why but this seems to be working now!
1
- ago
#9
I'm trying to test these simple perameters and the optimizer will not run. This happens often. I would like to use this program but it just dosn't run over half the time. Is there a problem with this below?



0
- ago
#10
I've deleted your new topic as it's duplicate, and moved the post where appropriate (here). Please provide more info:

1. What does it mean it's not running? Can you switch to the Optimization tab which is busy running your optimization?

2. Is this happening on both your machines or just one, and if the latter which one?

3. Can you export the 'problematic' strategies and send us at support@wealth-lab.com? Please upgrade to Build 14, if not yet. For a how to please refer to the Help > Strategy > Strategy Import and Export.
0
- ago
#11
I believe i have encountered this issue also. However it seems to be intermittant. I have not managed to identify the specific scenario that triggers it.

In my case, this occured first for me about a month ago - also when using the shinking window optimization process. At the time I thought it was just bogged down in calulations. 30-40 stocks, 10years+ history, multple parameters etc. Interestingly the GUI also became unresponsive after a while, but the Task Manager shows that Wealthlab is still utilizing memory, CPU and disk with fluctuating values (alive in the background) providing evidence to my theory that it was just "busy" deep in optimiation loops. I left it for several days, but it never reached the end of the optimization process.

An "end task" via the Task Manager and PC restart resulted in being able to run an optimization without issue (took about 20 minutes). However the optimization was exhaustive - not Shining Window - on only a few years of data an only 2 paramseters

I started a new Shinking window optimizer yesterday (latest software version and all extensions updated) and found the same issue again. Could it be an issue with the shinking window's progress report event to GUI thread not firing often enough with a larger paramter set? Just a shot in the dark.

Screenshot below from todays event on my laptop (minimal CPU and RAM) showing task manager and GUI unresponsive. It's been this way for 5-6 hours. I havent tested it on my high end machine yet. Will kill this one and try an exhaustive then report back.

I should note that my original test was on the pre-packed SMA50 SMA200 Cross Over Strategy (not a custom built strategy). I thought this worth noting as coding errors / unoptimized logic etc could also lead to longer run times and hangs. However in this case it was a WL7 shipped strategy which hopefuly is logic optimised :-)

0
- ago
#12
I haven't seen this problem, but I would like to offer a troubleshooting suggestion.

Create some type of "optional progress log" for the optimizer for troubleshooting such a problem. My guess is that there's some kind of infinite loop or numerical, data-dependent, non-convergence with the strategy. There needs to be some kind of optional logging (or progress bar) to narrow down exactly where the problem is; otherwise, you're just guessing.

The only recourse today is to start including "return;" lines in the code or deleting lines in the code until the problem goes away. That works, but it's not the best way.

If it's a data dependent problem with the convergence, then you need to find which stock is messed up that causes the non-convergence. Just start making the dataset smaller (removing stocks) until the problem disappears.
1
- ago
#13
All good suggestions thanks. I'll start working my way through the data set and add some logging to the strategy.

Follow up to previous post for interest:
------------------------------------
I set an Exhaustive Optimization running today. 4 paramters, WLD Dow 30 stock list which is about 40 tickers (I think) over a 10 year period.

The GUI continued to updated until about the 13 hour mark albeit at longer intervals between updates as time progressed. Initially every few minutes, then every 10-15, increasing to every hour then one last update from 10 hours to 13 hours. Since then it has been in the same seemingly unresponsive sate as described earlier for over 10 hours.

Comparatively, the Shinking Window stopped updating the GUI after about 2 hours. Same strategy, dataset and timeframes. However, a larger number of params were selected for optimization.

I'll keep digging and report back.
0
- ago
#14
It sounds like something in your strategy is running into an infinite loop, if you want to send it over via email you can do so to support@wealth-lab.com.
0
- ago
#15
Thanks for the feedback Superticker & Glitch.

I've identified a few issues...

1) A parameter in my strategy was set to default 0, when optimization range was set from 1-50. The 0 value was causing an infinite loop.

After this I was able to run a successful shrinking window on the WLD Dow30 data set over a 15 year period (1996-2010) on my laptop/notpad.

2) The data size and permutations selected on my laptop/notebook had a significantly significantly greater demand on resources than I expected. I have run a comparison on my Dual CPU Xeon with SSD's and 96GB ram and the difference is remarkable. An optimization that took nearly 8 hours to complet on the Xeon had barely reached 10% on the laptop/notebook. The first 12 hours exibhited all the same characteristics as described in earlier posts it was not until the second 12 hour window that the progress bar began to show change.

3) It would seem the WLD SP500 data set has an issue somewhere in the nearly 1000 stocks. Any atempt to complete a backtest (not optimization) on this dataset results in "spinning wheel". I'll try deleting all the data and starting fresh. But I think the major issues are all dealtwith.

Additional note: I have successfully run backtest on WLD SP100 dataset over 25 years (1996-2021) without any issues. Looks like the data file in question is one of the other 800 in the SP500 list :)
2
Cone7
- ago
#16
QUOTE:
Looks like the data file in question is one of the other 800 in the SP500 list
I'll see if I can find something. I suspect that it may be the metadata (when the components enter and leave the index) and not the data itself.
0
Cone7
- ago
#17
Not sure if this is it, but our Index source wasn't updated for a recent symbol change COG became CTRA, and only appears in the S&P 500 list.

That's fixed now (make sure to restart Wealth-Lab to refresh the cache).
2
Best Answer
- ago
#18
Confirmed fix.

I've restarted WL7 on my notebook, updated data and successfully run a backtest on the WLD SP500 dataset from 1996-2021.

Thank you.
1

Reply

Bookmark

Sort