Skip to content

Commit

Permalink
modified: pyar/interface/mopac.py
Browse files Browse the repository at this point in the history
	modified:   requirements.txt
  • Loading branch information
anoopduk committed Jun 27, 2024
1 parent d825a17 commit f3ac6d6
Show file tree
Hide file tree
Showing 2 changed files with 5 additions and 6 deletions.
10 changes: 5 additions & 5 deletions pyar/interface/mopac.py
Original file line number Diff line number Diff line change
Expand Up @@ -59,13 +59,13 @@ def prepare_input(self, keyword=""):
"""
keyword_line = '-xkPM7' if not keyword else '-xk' + keyword
with open(self.inp_file, 'w') as fminp:
with open(self.inp_file, 'w') as fminp, open('tmp.log', 'w') as ferr:
out = subp.Popen(["obabel", "-ixyz", self.start_xyz_file, "-omop", keyword_line],
stdout=fminp)
output, error = out.communicate()
poll = out.poll()
stdout=fminp, stderr=ferr)
output, error = out.communicate()
exit_status = out.returncode
os.remove('tmp.log')
if exit_status == 0:
os.remove('tmp.log')
return exit_status

def optimize(self, max_cycles=350, gamma=0.0, restart=False, convergence='normal'):
Expand Down
1 change: 0 additions & 1 deletion requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -3,7 +3,6 @@ pandas>=1.0.5
scipy>=1.5.2
scikit-learn>=0.23.2
autograd>=1.3
mendeleev>=0.9.0
dscribe
ase
pyh5md
Expand Down

0 comments on commit f3ac6d6

Please sign in to comment.