Author Topic: Task manager shows 25 percent CPU usage when runnin ATK simulations  (Read 2951 times)

0 Members and 1 Guest are viewing this topic.

Offline hossein9876

  • New QuantumATK user
  • *
  • Posts: 2
  • Reputation: 0
    • View Profile
Task manager shows 25 percent CPU usage when runnin ATK simulations. Does this mean the code is not being processed in parallel?
« Last Edit: December 11, 2012, 23:13 by hossein9876 »

Offline Anders Blom

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 5576
  • Country: dk
  • Reputation: 96
    • View Profile
    • QuantumATK at Synopsys
Not all parts of ATK are threaded, so the CPU utilization will change a lot during the run, depending on the task. For instance, a large matrix diagonalization will for sure run on 100% CPU. Also note that hyperthreading may fool the normalization of the CPU usage, so even if a process is utilizing all of the CPU, it may be reported as 50% only. If you want to experiment with hyperthreading, you can run ATK as
Code
MLK_DYNAMIC=FALSE MKL_NUM_THREADS=4 atkpython script.py
where 4 is the number of threads to use.

Offline hossein9876

  • New QuantumATK user
  • *
  • Posts: 2
  • Reputation: 0
    • View Profile
Thanks for the answer. I opened a command prompt in windows and tried what you mentioned but I'm getting the error:
<'MKL_DYNAMIC' is not recognized as an internal or external command, operable program or batch file.>
What am I doing wrong?

And two more questions:

1-Do I have to run ATK using the above mentioned procedure every time I want to run a script? I mean, is it possible to set a default number of threads once and for all?

2-Using the above method, I have to use a command prompt (in windows) to simulate a script. Is there a method to get the same results by just using the Job Manager in VNL?

Offline Anders Blom

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 5576
  • Country: dk
  • Reputation: 96
    • View Profile
    • QuantumATK at Synopsys
The syntax I used is for Linux or Cygwin. You can set these variables in the Control Panel on Windows, then they also apply to the processes run in the Job Manager (after you restart VNL). Or you can set them just for one job, in the terminal window, using
Code
set MKL_DYNAMIC=FALSE
set MKL_NUM_THREADS=4
atkpython script.py