-
Notifications
You must be signed in to change notification settings - Fork 0
Expand file tree
/
Copy pathmodprep.py
More file actions
29 lines (22 loc) · 834 Bytes
/
modprep.py
File metadata and controls
29 lines (22 loc) · 834 Bytes
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
import modeller
from modeller import automodel
import sys
def run_modeller(**kwargs):
"""
Refine protein structure using MODELLER
"""
default_stdout = sys.stdout
sys.stdout = open("pymodsim.log", "a")
if kwargs["mode"] == "run":
modeller.log.minimal()
env = modeller.Environ()
env.io.atom_files_directory = ['.', '../atom_files']
a = automodel.AutoModel(env,
alnfile = kwargs["alnfile"],
knowns = kwargs["knowns"],
sequence = 'refined')
a.starting_model= 1
a.ending_model = 1
a.md_level = None
a.make()
sys.stdout = default_stdout