Hi,
I am running MC v12 with 4 cores and 8 threads (Intel i7) machine. Whenever I run optimization in Portfolio Trader, all 8 threads are being 100% used up and I cannot do anything else. Is there a way to limit the no. of cores (e.g. to 3 cores in my case) in Portfolio Trader optimization like the optimization in a single chart signal? Then I can let the PT optimization to take hours to run in background while doing other stuff. Thanks!
Portfolio Trader Optimization - CPU core [SOLVED]
- lingwuchung
- Posts: 50
- Joined: 03 Feb 2014
- Has thanked: 6 times
Portfolio Trader Optimization - CPU core
Last edited by lingwuchung on 14 Oct 2020, edited 1 time in total.
Re: Portfolio Trader Optimization - CPU core
You can do this yourself by creating a .BAT file to start Portfolio Trader using the /AFFINITY option to restrict which cores you want used for this app.
Here is a thread explaining this in more detail: https://www.tenforums.com/performance-m ... d-cmd.html
Here is a thread explaining this in more detail: https://www.tenforums.com/performance-m ... d-cmd.html
- lingwuchung
- Posts: 50
- Joined: 03 Feb 2014
- Has thanked: 6 times
Re: Portfolio Trader Optimization - CPU core
Thanks. I can do this with "start /affinity 7F MCPortfolio.exe" (running at 7 out of my 8 CPU). However, I cannot do this with Multicharts already running. It said "TSServer is already launched on this machine by another user. This user should close all Multicharts64 components.".You can do this yourself by creating a .BAT file to start Portfolio Trader using the /AFFINITY option to restrict which cores you want used for this app.
Here is a thread explaining this in more detail: https://www.tenforums.com/performance-m ... d-cmd.html
If I "start /affinity 7F Multicharts64.exe" and then launch Portfolio Trader from the menu bar of Multcharts, it will occupy all 8 CPUs again.
- lingwuchung
- Posts: 50
- Joined: 03 Feb 2014
- Has thanked: 6 times
Re: Portfolio Trader Optimization - CPU core
If I terminate "TSServer.exe" while MC is running, Portfolio Manager can start with /affinity again. However the MC will become halt and cannot work.Thanks. I can do this with "start /affinity 7F MCPortfolio.exe" (running at 7 out of my 8 CPU). However, I cannot do this with Multicharts already running. It said "TSServer is already launched on this machine by another user. This user should close all Multicharts64 components.".You can do this yourself by creating a .BAT file to start Portfolio Trader using the /AFFINITY option to restrict which cores you want used for this app.
Here is a thread explaining this in more detail: https://www.tenforums.com/performance-m ... d-cmd.html
If I "start /affinity 7F Multicharts64.exe" and then launch Portfolio Trader from the menu bar of Multcharts, it will occupy all 8 CPUs again.
Any suggestion? Based on this scenario, it will not help even if I get another new PC with 10 or 20 cores. All of them will be eaten up by PT, leaving me unable to work on anything else.
- TJ
- Posts: 7743
- Joined: 29 Aug 2006
- Location: Global Citizen
- Has thanked: 1033 times
- Been thanked: 2223 times
Re: Portfolio Trader Optimization - CPU core
I always recommend people to use a separate machine for testing, backtesting and optimization.
Computers are not that expensive nowadays. There is no reason not to dedicate a computer for development purpose. That's how professional do it.
Computers are not that expensive nowadays. There is no reason not to dedicate a computer for development purpose. That's how professional do it.
- lingwuchung
- Posts: 50
- Joined: 03 Feb 2014
- Has thanked: 6 times
Re: Portfolio Trader Optimization - CPU core
I do have 2 machines (going to buy a 3rd one) but I still want this feature for the following reasons:I always recommend people to use a separate machine for testing, backtesting and optimization.
Computers are not that expensive nowadays. There is no reason not to dedicate a computer for development purpose. That's how professional do it.
1. I want to make use of the latest code for optimization immediately. Having a separate machines costs the extra code and environment synchronization, which I did try but gave up after several months due to error-prone process.
2. Even I have 3 machines, I would want to optimize on the fastest machine only. I don't have the budget and motivation to upgrade multiple machines to the same processing power at the same time. Well, unless Multicharts can allow me to run optimization on cloud. Is this on roadmap?
3. Multicharts has this "Number of CPU cores to use" in optimization since v12. I am just asking when this could be introducted to Portfolio Manager, which I don't see yet in v14.
- Kate MultiCharts
- Posts: 596
- Joined: 21 Oct 2020
- Has thanked: 9 times
- Been thanked: 149 times
Re: Portfolio Trader Optimization - CPU core [SOLVED]
Hello lingwuchung,
In one of the future releases we are planning to add a new optimization manager in Portfolio Trader.
It’s going to be the same as the one in MultiCharts, it’ll allow controlling the number of engaged cores on the run with a slider.
In one of the future releases we are planning to add a new optimization manager in Portfolio Trader.
It’s going to be the same as the one in MultiCharts, it’ll allow controlling the number of engaged cores on the run with a slider.
- lingwuchung
- Posts: 50
- Joined: 03 Feb 2014
- Has thanked: 6 times
Re: Portfolio Trader Optimization - CPU core
Excellent! I have changed to i9 with 20 cores now. As expected all cores are still 100% during portfolio manager optimization but somehow I still manage to do some simple tasks like browser. Guess that’s due to improvement of the i9 processor’s architecture.
- lingwuchung
- Posts: 50
- Joined: 03 Feb 2014
- Has thanked: 6 times
Re: Portfolio Trader Optimization - CPU core
Excellent! I have changed to i9 with 20 cores now. As expected all cores are still 100% during portfolio manager optimization but somehow I still manage to do some simple tasks like browser. Guess that’s due to improvement of the i9 processor’s architecture.Hello lingwuchung,
In one of the future releases we are planning to add a new optimization manager in Portfolio Trader.
It’s going to be the same as the one in MultiCharts, it’ll allow controlling the number of engaged cores on the run with a slider.