Gamestudio Links
Zorro Links
Newest Posts
Zorro FIX plugin - Experimental
by flink. 04/21/24 07:12
Data from CSV not parsed correctly
by EternallyCurious. 04/20/24 21:39
M1 Oversampling
by 11honza11. 04/20/24 20:57
Scripts not found
by juergen_wue. 04/20/24 18:51
zorro 64bit command line support
by 7th_zorro. 04/20/24 10:06
StartWeek not working as it should
by jcl. 04/20/24 08:38
folder management functions
by VoroneTZ. 04/17/24 06:52
AUM Magazine
Latest Screens
The Bible Game
A psychological thriller game
SHADOW (2014)
DEAD TASTE
Who's Online Now
1 registered members (rki), 405 guests, and 1 spider.
Key: Admin, Global Mod, Mod
Newest Members
EternallyCurious, howardR, 11honza11, ccorrea, sakolin
19047 Registered Users
Previous Thread
Next Thread
Print Thread
Rate Thread
Zorro S is not using more than 1 CPU core #476008
01/17/19 13:56
01/17/19 13:56
Joined: Oct 2017
Posts: 52
Brazil
J
jmlocatelli Offline OP
Junior Member
jmlocatelli  Offline OP
Junior Member
J

Joined: Oct 2017
Posts: 52
Brazil
Hi,
I cannot make Zorro S use more than 1 CPU core during TRAIN mode, with or without Walk Forward.
This command has no effect:
if(is(INITRUN)) NumCores = -1;
No matters the number I assign to NumCores, the total CPU usage is around 15%. And I can see just one CPU running with Resouce Monitor.

Are there code restrictions to enable multi-core processing?

I'm using Zorro S 1.96 in an Intel i7 PC.

Thanks in advance.
jm

Re: Zorro S is not using more than 1 CPU core [Re: jmlocatelli] #476009
01/17/19 15:57
01/17/19 15:57
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
Two things to check:

* When you start Zorro, make sure it says that you are running Zorro S.
* Once confirmed, observe your script. Maybe there is something wrong with it?

If you can't figure it out, post your script.

Re: Zorro S is not using more than 1 CPU core [Re: AndrewAMD] #476010
01/17/19 16:19
01/17/19 16:19
Joined: Oct 2017
Posts: 52
Brazil
J
jmlocatelli Offline OP
Junior Member
jmlocatelli  Offline OP
Junior Member
J

Joined: Oct 2017
Posts: 52
Brazil
During Zorro start:

Zorro S 1.96.4
(c) oP group Germany 2018
Zorro S Subscription

So this part seems ok.

I'll check the script.

Thanks for the help.
jm

Re: Zorro S is not using more than 1 CPU core [Re: jmlocatelli] #476011
01/17/19 16:45
01/17/19 16:45
Joined: Oct 2017
Posts: 52
Brazil
J
jmlocatelli Offline OP
Junior Member
jmlocatelli  Offline OP
Junior Member
J

Joined: Oct 2017
Posts: 52
Brazil
Checked the code. It seems ok.
Here it is:

function run()
{
set(PARAMETERS);
set(LOGFILE);
assetList("Assets_ALMA.csv");
if(is(INITRUN)) NumCores = -1;
BarPeriod = 10;
LookBack = 250;
StartDate = 20180701;
EndDate = 20181231;
// NumWFOCycles = -10;

while(loop(Assets))
{
asset(Loop1);
PIP = 0.01;
PIPCost = 0.01;
Spread = RollLong = RollShort = 0;
var PositionValue = 100000;
int pALMAPeriod = optimize(50,5,250);
var pALMASigma = optimize(6,1,20,1);
var pALMAOffset = optimize(0.85,0.01,1.00);
vars indALMA = series(ALMA(series(price()),pALMAPeriod,pALMASigma,pALMAOffset));
Lots = round(PositionValue/price()/100)*100;
if(valley(indALMA))
{
exitShort();
enterLong();
}
if(peak(indALMA))
{
exitLong();
enterShort();
}
}
}

Re: Zorro S is not using more than 1 CPU core [Re: jmlocatelli] #476013
01/17/19 17:30
01/17/19 17:30
Joined: Feb 2017
Posts: 1,725
Chicago
AndrewAMD Online
Serious User
AndrewAMD  Online
Serious User

Joined: Feb 2017
Posts: 1,725
Chicago
Originally Posted By: jmlocatelli
//NumWFOCycles = -10;
You can't do multiprocess with anchored, since cycle 3 depends on cycle 2, which depends on cycle 1.

Re: Zorro S is not using more than 1 CPU core [Re: AndrewAMD] #476136
01/29/19 01:42
01/29/19 01:42
Joined: Oct 2017
Posts: 52
Brazil
J
jmlocatelli Offline OP
Junior Member
jmlocatelli  Offline OP
Junior Member
J

Joined: Oct 2017
Posts: 52
Brazil
I didn't find any restriction in Zorro documentation regarding anchored WF and NumCores.
But anyway, it does not use more than 1 core in both WF configuration, anchored or not anchored.

It's a very basic script. Can any one run WF with this script and tell me if it can or can not use multiple cores?

regards, jm

Re: Zorro S is not using more than 1 CPU core [Re: jmlocatelli] #476145
01/29/19 02:46
01/29/19 02:46
Joined: Jul 2000
Posts: 27,982
Frankfurt
jcl Offline

Chief Engineer
jcl  Offline

Chief Engineer

Joined: Jul 2000
Posts: 27,982
Frankfurt
It cannot because you outcommented WFO.

If something particular does not work, first look into a script where it works - there are several scripts included that use multiple cores. Then check where yours is different. This way you can find the reason of such issues quickly without going at length through the manual.


Moderated by  Petra 

Powered by UBB.threads™ PHP Forum Software 7.7.1