This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import os, sys, subprocess | |
def main(): | |
conda_base_path = os.path.dirname(os.path.dirname(__file__)) | |
path = sys.argv[1] | |
env = get_env() | |
gen_activate_script(path, env, conda_base_path) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python3 | |
import argparse, os, sys, gzip, shutil | |
parser = argparse.ArgumentParser(description="Reorders and extracts files downloaded using ncbi-genome-download run with the --human-readable option") | |
parser.add_argument("-o", "--output-directory", required=True, help="Path to the output directory. A directory will be created if one does not exist.", action="store", dest="outdir") | |
parser.add_argument("-g", "--group-directory", required=True, help="Path to the group (bacteria, viral, etc.) directory from the ncbi-genome-download human-readable output. If refseq genomes were downloaded from the bacteria group then the input should be <ncbi-genome-download-output>/human_readable/refseq/bacteria ", action="store", dest="group_dir") | |
parser.add_argument("-f", "--force", help="Overwrite files in the output directory.", action='store_true', default=False) | |
args = parser.parse_args() |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
import sys, os, re | |
from Bio import SeqIO | |
base_dir = sys.argv[1] | |
keyword = sys.argv[2] | |
outdir = sys.argv[3] | |
min_len = int(float(sys.argv[4])*1000000) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
from Bio import SeqIO, bgzf | |
import sys | |
from gzip import open as gzopen | |
infile = sys.argv[1] | |
outprefix = sys.argv[2] | |
print("Splitting reads...") |