phylip proml < input > screenoutHowever, this is ANNOYING to do with python's subprocess module. It can't deal with the redirections so you have to use the subprocess input/output:
if capture_output:
out = open('screenout', 'w')
else:
out = open(os.devnull, 'w')
inbuf = open('input','w')
args = shlex.split(cmd)
call(args, stdin = inbuf, stdout = out)
This is already in the code, just posting it here for reference
No comments:
Post a Comment