Author Topic: Decision of Iteration control parameters  (Read 4626 times)

0 Members and 1 Guest are viewing this topic.

Offline sergio

  • Heavy QuantumATK user
  • ***
  • Posts: 56
  • Reputation: 0
    • View Profile
Decision of Iteration control parameters
« on: October 20, 2009, 14:11 »
Hi,

I am running the VNL to calculate the transmission coefficients for some systems including around 500 atoms. For some systems we need to increase the max. step the under  "Iteration control parameters " otherwise we get:

"ATKError: Exceeded maximum number of self-consistent iterations.
Terminated Abnormally"

and of course it takes time!

1) Is there anyway to decide  the max. steps roughly before starting the calculation, so that we are able to save time?

2) Is there any other reason(s) of that error?

3) If we get this error and program terminates abnormally, using the produced nc file, is it possible to start the calculation at this point by increasing the step number?

Many Thanks,

Offline Anders Blom

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 5565
  • Country: dk
  • Reputation: 93
    • View Profile
    • QuantumATK at Synopsys
Re: Decision of Iteration control parameters
« Reply #1 on: October 20, 2009, 15:23 »
The short answers are 1. Unfortunately, no (and even if there were, it wouldn't really save any time...) 2. No 3. Yes (see below) To restart the calculation, you can use a very small script
Code
from ATK.TwoProbe import *
import ATK
old_scf = restoreSelfConsistentCalculation("checkpointfile.nc")
ATK.setVerbosityLevel(1)
ATK.setCheckpointFilename('new.nc')
new_scf = executeSelfConsistentCalculation(self_consistent_calculation=old_scf)

Offline sergio

  • Heavy QuantumATK user
  • ***
  • Posts: 56
  • Reputation: 0
    • View Profile
Re: Decision of Iteration control parameters
« Reply #2 on: October 21, 2009, 09:03 »
Thanks for your reply A.Blom, then how can I insert the increasing step number in this script?

Offline Anders Blom

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 5565
  • Country: dk
  • Reputation: 93
    • View Profile
    • QuantumATK at Synopsys
Re: Decision of Iteration control parameters
« Reply #3 on: October 21, 2009, 09:08 »
If you restart, using the script indicated in the previous post, it will take another 100 steps. In principle, if it still hasn't converged you can just repeat the procedure, but at that point you should probably rather investigate why it fails to converge. Thus, there is no need, in this case, to increase "max_steps", since this number applies "per run", not in total. Of course, if you run several of these simulations, and they generally require more than the default max steps (100), the relevant setting is something like
Code
iterationControlParameters(max_steps=200)

Offline sergio

  • Heavy QuantumATK user
  • ***
  • Posts: 56
  • Reputation: 0
    • View Profile
Re: Decision of Iteration control parameters
« Reply #4 on: October 21, 2009, 09:30 »
Many thanks for your quick reply,