Author Topic: 'Physics Exception'  (Read 3621 times)

0 Members and 1 Guest are viewing this topic.

Offline Vit

  • Regular QuantumATK user
  • **
  • Posts: 6
  • Reputation: 0
    • View Profile
'Physics Exception'
« on: February 18, 2011, 14:24 »
Hello, I'm looking for help regarding changing the temperature of a two probe calculation. I've carried out a calculation at a higher temperature, and now want to bring the temperature down, using the electronic structure generated at the higher temp as a starting point. The script I've made (for ATK 10.8.2) is:
Code: python
# Load config and define: calc, NAP
config = nlread('Mo2Cl9-S3-0.6V-hiT.nc', object_id='gID000')[0]
calculator = config.calculator()
NAP = NumericalAccuracyParameters(electron_temperature = 300.0*Kelvin)

# Change temp
config.setCalculator(calculator(numerical_accuracy_parameters = NAP))

# Run SCF and save
config.update()
nlsave('Mo2Cl9-S3-0.6V-loT.nc')
However, I encounter this error:
Code: python
terminate called after throwing an instance of 'PhysicsException'
terminate called after throwing an instance of 'PhysicsException'
terminate called after throwing an instance of 'PhysicsException'
Center = 107, Left = 97


** Back Engine Exception 29 : central and left electrode has different grid size in i direction
** Location : electrodeutils.cpp:126

Center = 107, Left = 97


** Back Engine Exception 29 : central and left electrode has different grid size in i direction
** Location : electrodeutils.cpp:126

Center = 107, Left = 97


** Back Engine Exception 29 : central and left electrode has different grid size in i direction
** Location : electrodeutils.cpp:126

Center = 107, Left = 97


** Back Engine Exception 29 : central and left electrode has different grid size in i direction
** Location : electrodeutils.cpp:126

rank 5 in job 146  spartan_34202   caused collective abort of all ranks
  exit status of rank 5: killed by signal 9 
Center = 107, Left = 97


** Back Engine Exception 29 : central and left electrode has different grid size in i direction
** Location : electrodeutils.cpp:126
Both the left and right electrode calculations converge, but on starting the "Device Density Matrix Calculation", this error is thrown up. I'd appreciate any help with either what I'm trying to accomplish, or the error message. Thanks, Vit
« Last Edit: February 21, 2011, 11:58 by Anders Blom »

Offline Anders Blom

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 5418
  • Country: dk
  • Reputation: 89
    • View Profile
    • QuantumATK at Synopsys
Re: 'Physics Exception'
« Reply #1 on: February 18, 2011, 17:58 »
Odd, we'll look into it. What mesh cut-off did you use for the original calculation? Was it different than the default?

Offline Vit

  • Regular QuantumATK user
  • **
  • Posts: 6
  • Reputation: 0
    • View Profile
Re: 'Physics Exception'
« Reply #2 on: February 19, 2011, 09:24 »
The mesh cut-off was changed from the default 150 Rydberg to 125 Rydberg in the original calculation.

Offline Anders Blom

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 5418
  • Country: dk
  • Reputation: 89
    • View Profile
    • QuantumATK at Synopsys
Re: 'Physics Exception'
« Reply #3 on: February 19, 2011, 10:37 »
As I suspected. It would seem this is a bug that needs fixing, although I haven't verified it completely yet. For now, to avoid problems, I suggest you rerun the original high-T system with the default mesh (shouldn't make a big difference in time) OR experiment with
Code: python
NAP = NumericalAccuracyParameters(grid_mesh_cutoff=125.0*Rydberg,
    electron_temperature = 300.0*Kelvin)  

Offline Anders Blom

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 5418
  • Country: dk
  • Reputation: 89
    • View Profile
    • QuantumATK at Synopsys
Re: 'Physics Exception'
« Reply #4 on: February 21, 2011, 11:26 »
Turns out, it's not a bug, although even I was confused at first. The trick is to clone also the numerical accuracy parameters! Try this:
Code: python
# Load config and define: calc, NAP  
config = nlread('Mo2Cl9-S3-0.6V-hiT.nc', object_id='gID000')[0]  
calculator = config.calculator()

NAP = calculator.numericalAccuracyParameters()(electron_temperature = 300.0*Kelvin)
config.setCalculator(calculator(numerical_accuracy_parameters=NAP))

# Change temp  
config.setCalculator(calculator(numerical_accuracy_parameters = NAP))  
  
# Run SCF and save  
config.update()  
nlsave('Mo2Cl9-S3-0.6V-loT.nc')
« Last Edit: February 21, 2011, 11:58 by Anders Blom »

Offline Vit

  • Regular QuantumATK user
  • **
  • Posts: 6
  • Reputation: 0
    • View Profile
Re: 'Physics Exception'
« Reply #5 on: February 21, 2011, 15:18 »
Your cloning seems to have done the trick - the calculation is running. Thanks!

Offline Anders Blom

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 5418
  • Country: dk
  • Reputation: 89
    • View Profile
    • QuantumATK at Synopsys
Re: 'Physics Exception'
« Reply #6 on: February 21, 2011, 15:44 »
Good! Cloning is done when you say "c=calculator()" for example. This creates a new calculator, with all the same parameters - a cloned copy. If we only did
Code
c2 = config.calculator
we would have all the same methods and objects on "c2" as on "c", however "c2" would just be a pointer to the original object. Thus, if we modified "c2", we would also modify the calculator on "config", which may not be at all what you wanted. If we modify "c", nothing happens to "config". Note that this is nothing we invented (the pointer stuff), this is how Python works - and it can be rather dangerous sometimes. So, to be able to do make a real, new copy, we implemented the clone concept. The difference between my script and your original version is really only that my "NAP" is a clone of the original numerical accuracy parameters, and therefore it has the mesh cut-off that you specified for your high-T calculation (125 Ry), whereas in your case "NAP" was initialized with default parameters (150 Ry), which doesn't match the electrodes.
« Last Edit: February 21, 2011, 15:54 by Anders Blom »