Beispiel #1
0
 def test_is_ready_to_run(self):
     kdict=dict()
     kdict['mast_neb_settings']=dict()
     kdict['mast_neb_settings']['images']=3
     myvcneb=VaspNEBChecker(name="notready1",program_keys=kdict)
     self.assertFalse(myvcneb.is_ready_to_run())
     myvcneb=VaspNEBChecker(name="notready2",program_keys=kdict)
     self.assertFalse(myvcneb.is_ready_to_run())
     myvcneb=VaspNEBChecker(name="notready3",program_keys=kdict)
     self.assertFalse(myvcneb.is_ready_to_run())
     myvcneb=VaspNEBChecker(name="notready4",program_keys=kdict)
     self.assertFalse(myvcneb.is_ready_to_run())
     myvcneb=VaspNEBChecker(name="notready5",program_keys=kdict)
     self.assertFalse(myvcneb.is_ready_to_run())
     myvcneb=VaspNEBChecker(name="notready6",program_keys=kdict)
     self.assertFalse(myvcneb.is_ready_to_run())
     myvcneb=VaspNEBChecker(name="ready", program_keys=kdict)
     self.assertTrue(myvcneb.is_ready_to_run())
     myvcneb=VaspNEBChecker(name="started", program_keys=kdict)
     self.assertTrue(myvcneb.is_ready_to_run())
     myvcneb=VaspNEBChecker(name="done", program_keys=kdict)
     self.assertTrue(myvcneb.is_ready_to_run())
Beispiel #2
0
 def test_set_up_program_input(self):
     mystrs=list()
     pos=dict()
     for posstr in ['00','01','02','03','04']:
         pos[posstr] = pymatgen.io.vaspio.Poscar.from_file("structures/POSCAR_%s" % posstr)
         mystrs.append(pos[posstr].structure)
     kdict=dict()
     kdict['mast_kpoints']=[3,3,3,"G"]
     kdict['mast_xc']="pw91"
     kdict['mast_neb_settings']=dict()
     kdict['mast_neb_settings']['images']=3
     kdict['mast_neb_settings']['image_structures'] = mystrs
     myvcneb=VaspNEBChecker(name="childdir",program_keys=kdict)
     myvcneb.set_up_program_input()
     submitscript = MASTFile()
     submitscript.data="Submission script placeholder."
     submitscript.to_file("childdir/submit.sh")
     ozholder = MASTFile()
     ozholder.data="OSZICAR placeholder."
     submitscript.to_file("childdir/00/OSZICAR")
     submitscript.to_file("childdir/04/OSZICAR")
     self.assertTrue(myvcneb.is_ready_to_run())