Optimisation in the Strategy Tester

 
Please, help me to understand it.

For example, I chose the standard Expert Advisor from the "Moving Average.mq5" delivery (to avoid questions about the code in the Expert Advisor).
Initial data:
EURUSD, Daily, from 01.07.2010 to 31.08.2010, Open prices only, mode without optimization (i.e. one pass of the tester).
StrategyTester_1pass.log file is attached.

Here is what we see: the total running time of the tester is 8 sec, of which ONLY 546 ms was spent on testing the Expert Advisor. All the rest of the time was preparatory work.

Then I set optimization of one input parameter out of 5 values (for five passes of the tester).

Here is a screenshot of the log

tester log

and the StrategyTester_5passes.log file are attached.

The log shows that each iteration takes 7-9 seconds, i.e. we have a full cycle of single runs each time!
Hence, total optimization time is 25 sec. on a dual core processor (it would take 45 seconds on one core, instead of 3 seconds of real EA testing).

And what if we need to optimize 3 input parameters for at least 10 values (10 * 10 * 10 = 1000)? In MT4 the optimization was several orders of magnitude faster.

I found questions about the same problem in one of the forum threads https://www.mql5.com/ru/forum/852/page14, but all were sent either to my personal account or to servicedesk.

Please explain what the problem is and how to optimize correctly in the strategy tester.

 

I noticed it too... but I blamed it on "imperfection" of mql5 -))

I optimize 5 parameters... I take elementary signal as input... no calculations... I've removed everything I could...

as a result 1200 runs on a 4-core processor takes all evening... and that's just in a month...

i've been looking for a way to speed things up... i've restricted the eXpert to check conditions once every 5 minutes... it hasn't worked... not a second faster...

so for a fortnight now I've been testing and testing... and I'm inclined to think that I should just put in the parameters without any optimisation...

 
maryan.dirtyn:

I noticed it too... but I blamed it on "imperfection" of mql5 -))

I optimize 5 parameters... I take elementary signal as input... no calculations... I've removed everything I could...

as a result 1200 runs on a 4-core processor takes all evening... and that's just in a month...

i've been looking for a way to speed things up... i've restricted the eXpert to check conditions once every 5 minutes... it hasn't worked... not a second faster...

so for a fortnight now I've been testing and testing... and I'm inclined to think that I should just put in the parameters without any optimisation...

At first I also thought there was a mistake in my code. I searched and simplified it, but then I got to this (...): "expert".

input int          X = 100;

int OnInit()
  {
   return(0);
  }

void OnDeinit(const int reason)
  {
  }

void OnTick()
  {
   Print("Тик-Так.");
  }

The result was the same.

1 pass takes 7-9 seconds. Such nonsense turns out.

 
Batohov:

1 pass lasts 7-9 seconds. That's the kind of nonsense you get.

+1.

same for opening prices.

to the Red Army such optimization...

Документация по MQL5: Стандартные константы, перечисления и структуры / Константы индикаторов / Ценовые константы
Документация по MQL5: Стандартные константы, перечисления и структуры / Константы индикаторов / Ценовые константы
  • www.mql5.com
Стандартные константы, перечисления и структуры / Константы индикаторов / Ценовые константы - Документация по MQL5
 
I've been optimizing for a month now))) and it looks like there will be no end to it) but "optimization by OOP" covers all possible aspects of human stupidity... perhaps it's only us who have been doing it for so long... )) since no one else comes here... I can imagine how long the test would take, if I attached"Tilt control of balance curve during Expert Advisor's activity" to amoebaic eXpert.
 
Yeah, that's what I'm doing right now.... it's just as cumbersome as downloading a movie with GPRS....
 
maryan.dirtyn:
I've been optimizing for a month now))) and it looks like there's no end in sight... I guess it's just us for so long... ))) since no one else is looking here...
Yes, everyone does :) There's just nothing to say. I'm quite used to 5-6 days of fast optimization on a 2 core CPU on "all ticks" of 10.5 thousand steps. No complaints.
 
Yedelkin:
Yes, everyone is stopping by :) There's just nothing to say. I'm quite used to the fact that on a 2-core processor fast optimization on "all ticks" of 10.5 thousand steps takes 5-6 days. No complaints.
But it used to be significantly faster
 
maryan.dirtyn:
But it was much faster before

My computer hasn't stopped since May - it's constantly optimising. That's why I'm already lost whether it was faster or not.

Addition: I just noticed that the compiler has become 10 times faster.

 
Yedelkin:

My computer hasn't stopped since May - it's constantly optimising. So I'm already lost as to whether it was faster or not.

creepy
 

And I selected a few parameters, clicked the test... in the morning I counted the number of runs and how many were left... calculated that there were 50 days to the end of the optimisation... my computer has 4 cores + 2 core agents... I don't need this optimization, so I turned it off...

Reason: