Skip to content

Commit

Permalink
Updated world.rank
Browse files Browse the repository at this point in the history
import rank is deprecated
Changed lines 10 and 614 to use world.rank "from ase.parallel import world"
  • Loading branch information
vladislavivanistsev committed May 23, 2022
1 parent cad8c5c commit d20ed80
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions catlearn/optimize/mlneb.py
Original file line number Diff line number Diff line change
Expand Up @@ -7,7 +7,7 @@
from ase.neb import NEBTools
from ase.io import read, write
from ase.optimize import MDMin
from ase.parallel import parprint, rank, parallel_function
from ase.parallel import parprint, world, parallel_function
from scipy.spatial import distance
import os
from catlearn.regression import GaussianProcess
Expand Down Expand Up @@ -611,7 +611,7 @@ def run(self, fmax=0.05, unc_convergence=0.050, steps=500,
parprint('The optimized predicted path can be found in: ',
trajectory)
# Clean up:
if rank == 0:
if world.rank == 0:
os.remove('./last_predicted_path.traj')
os.remove('./all_predicted_paths.traj')
break
Expand Down

0 comments on commit d20ed80

Please sign in to comment.