Does #property tester_file keep files open across the span of the optimization

 

#property tester_file

Assuming an optimization starts with the files declared with these properties no longer changing (since the terminal needs to restart before the test).

So does that property just move them to the agents folder for each agent that starts a test or does it keep it open in memory ? 

i.e. open once use across all passes (since they are not changing)

In case its my fault : I'm using the property tester file for 3 files .

Documentation on MQL5: Language Basics / Preprocessor / Program Properties (#property)
Documentation on MQL5: Language Basics / Preprocessor / Program Properties (#property)
  • www.mql5.com
Program Properties (#property) - Preprocessor - Language Basics - MQL5 Reference - Reference on algorithmic/automated trading language for MetaTrader 5
 
Lorentzos Roussos: #property tester_file

Assuming an optimization starts with the files declared with these properties no longer changing (since the terminal needs to restart before the test). So does that property just move them to the agents folder for each agent that starts a test or does it keep it open in memory ? i.e. open once use across all passes (since they are not changing) In case its my fault : I'm using the property tester file for 3 files .

I doubt the MetaTester agents "collaborate" with each other. They probably each open the file independently.

I also think that the file is actually copied over too, so they each get a copy of the file and don't read the original directly. The documentation is not clear on this and only states that the file is "passed". However, since agents can also work for the cloud and farms, it seems plausible that the files are copied so each agent gets a local copy.

 

From an architecture standpoint its not feasible ?

I mean there would not be any gains in speed ?

Why not keep it in memory once instead of constantly reopening it since it wont change anyway 

 
Lorentzos Roussos #: From an architecture standpoint its not feasible ? I mean there would not be any gains in speed ? Why not keep it in memory once instead of constantly reopening it since it wont change anyway 
Obviously, it is feasible and makes absolute sense, but since when have any of MetaQuotes software applications ever been efficient? 😅
 
Fernando Carreiro #:
Obviously, it is feasible and makes absolute sense, but since when have any of MetaQuotes software applications ever been efficient? 😅

ahaha . 

Well , it would be very useful

although i understand this is not what it was built for (the tester) and the GA is also not "tuned" for such tasks
 

This is something done at the OS level. The data file is cached after it's first read.

File Caching - Win32 apps
File Caching - Win32 apps
  • 2021.01.07
  • alvinashcraft
  • learn.microsoft.com
Windows caches file data that is read from disks and written to disks.
 
Alain Verleyen #:

This is something done at the OS level. The data file is cached after it's first read.

ah

so there wont be any point in turning the data into a giant include file

 
Lorentzos Roussos #:

ah

so there wont be any point in turning the data into a giant include file

I don't think so, but you can try and keep us posted.

Anyway, your giant file would be in the ex5 and would still needs to be read by each agent.

 
Alain Verleyen #:

I don't think so, but you can try and keep us posted.

Anyway, your giant file would be in the ex5 and would still needs to be read by each agent.

xD dam it

then keeping it in the clipboard and "downloading" it on every pass xD

 
Alain Verleyen #:

This is something done at the OS level. The data file is cached after it's first read.

It's also perfectly possible that the data files are stored in shared memory by the Strategy Tester. We don't know how it's implemented. But from my experience it's very efficient. (I am using 2 data files with a total size around 165 MB).
 
Alain Verleyen #:
It's also perfectly possible that the data files are stored in shared memory by the Strategy Tester. We don't know how it's implemented. But from my experience it's very efficient. (I am using 2 data files with a total size around 165 MB).

it could be the read speed of your ssd too 

I had 2 as well and did some "prework" and now i have 3 , was surprised it only sped up 2x 

Reason: