Author Topic: Restart device optimization with trajectory  (Read 3446 times)

0 Members and 1 Guest are viewing this topic.

Offline ems032

  • New QuantumATK user
  • *
  • Posts: 2
  • Country: us
  • Reputation: 0
    • View Profile
Restart device optimization with trajectory
« on: March 7, 2016, 20:50 »
I am trying to restart a device optimization and I have a trajectory file for the first attempt. I read a similar topic at http://quantumwise.com/forum/index.php?topic=3805.msg17364#msg17364 , so I see how to obtain the last configuration from the trajectory, but I am unsure exactly how to implement this last configuration into the script to restart the optimization.

Any help will be much appreciated  :D

-Ethan


Offline Jess Wellendorff

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 933
  • Country: dk
  • Reputation: 29
    • View Profile
Re: Restart device optimization with trajectory
« Reply #1 on: March 8, 2016, 08:56 »
You simply replace the top part of the script that define the configuration with the two lines of code in the the post you refer to.
Code
# -------------------------------------------------------------
# Configuration from Trajectory
# -------------------------------------------------------------
trajectory = nlread('filename.nc', Trjaectory)[-1]
configuration = trajectory.lastImage()
# -------------------------------------------------------------
# Calculator
# -------------------------------------------------------------
.....
# -------------------------------------------------------------
# Optimize Geometry
# -------------------------------------------------------------
.....
Full example attached.

Offline ems032

  • New QuantumATK user
  • *
  • Posts: 2
  • Country: us
  • Reputation: 0
    • View Profile
Re: Restart device optimization with trajectory
« Reply #2 on: March 8, 2016, 19:13 »
Thanks for your help, Jess!

Offline Jess Wellendorff

  • QuantumATK Staff
  • Supreme QuantumATK Wizard
  • *****
  • Posts: 933
  • Country: dk
  • Reputation: 29
    • View Profile
Re: Restart device optimization with trajectory
« Reply #3 on: March 9, 2016, 10:32 »
There is an error in the code given above: It should be
Code
trajectory = nlread('filename.nc', Trajectory)[-1]
instead of
Code
trajectory = nlread('filename.nc', Trjaectory)[-1]