Skip to content

Commit

Permalink
Add files via upload
Browse files Browse the repository at this point in the history
  • Loading branch information
dsvatunek authored Apr 27, 2020
1 parent 7ba7143 commit 2c595d0
Show file tree
Hide file tree
Showing 2 changed files with 9 additions and 6 deletions.
13 changes: 8 additions & 5 deletions DIAS_inputparser.py
Original file line number Diff line number Diff line change
Expand Up @@ -277,13 +277,16 @@ def get_irc(file):
structures.xyz.append(np.array([x.split()[3:] for x in raw_coordinates]))
structures.atoms = [x.split()[1] for x in raw_coordinates]
structures.atoms = [periodic_table[int(x)] for x in structures.atoms]
# find everything except the TS structure
regex = r'---------------------------------------------------------------------((?:(?!---------------------------------------------------------------------).)*?)---------------------------------------------------------------------(?:(?!---------------------------------------------------------------------).)*?Delta-x\ Convergence\ Met'
for match in re.finditer(regex, file_contents, re.IGNORECASE|re.DOTALL):
# find everything except the TS structure for normal run
regex2 = r'---------------------------------------------------------------------((?:(?!---------------------------------------------------------------------).)*?)---------------------------------------------------------------------(?:(?!---------------------------------------------------------------------).)*?Delta-x\ Convergence\ Met'
for match in re.finditer(regex2, file_contents, re.IGNORECASE|re.DOTALL):
raw_coordinates = match.group(1).strip().split("\n")
structures.xyz.append(np.array([x.split()[3:] for x in raw_coordinates]))


# find everything except the TS structure for #p
regex3 = r'(?:(CURRENT).+?)(?:---------------------------------------------------------------------)(?:.*?(---------------------------------------------------------------------))(.*?)(?:(---------------------------------------------------------------------))'
for match in re.finditer(regex3, file_contents, re.DOTALL):
raw_coordinates = match.group(3).strip().split("\n")
structures.xyz.append(np.array([x.split()[2:] for x in raw_coordinates]))
for i in range(len(structures.xyz)):
structures.xyz[i] = structures.xyz[i].astype(float)
structures.title = [str(x) for x in range(len(structures.xyz))]
Expand Down
2 changes: 1 addition & 1 deletion autoDIAS.py
Original file line number Diff line number Diff line change
Expand Up @@ -11,7 +11,7 @@
Download the newest version from:
https://github.com/dsvatunek/autoDIAS
Please cite. DOI: 10.26434/chemrxiv.7789940
Please cite. DOI: 10.1002/jcc.26023
*****************************************************************************************
Python wrapper for several computational chemistry software packages to automatically
Expand Down

0 comments on commit 2c595d0

Please sign in to comment.