예제 #1
0
파일: alignment.py 프로젝트: huang1990/Flye
def check_binaries():
    if not which(MINIMAP_BIN):
        raise AlignmentException("minimap2 is not installed")
    if not which(SAMTOOLS_BIN):
        raise AlignmentException("samtools is not installed")
    if not which("sort"):
        raise AlignmentException("UNIX sort utility is not available")
예제 #2
0
def check_binaries():
    if not which(REPEAT_BIN) or not which(CONTIGGER_BIN):
        raise RepeatException("Repeat/contigger binaries were not found. "
                              "Did you run 'make'?")
    try:
        devnull = open(os.devnull, "w")
        subprocess.check_call([REPEAT_BIN, "repeat", "-h"], stderr=devnull)
    except subprocess.CalledProcessError as e:
        raise RepeatException(str(e))
    except OSError as e:
        raise RepeatException(str(e))
예제 #3
0
def check_binaries():
    if not which(POLISH_BIN):
        raise PolishException("polishing binary was not found. "
                              "Did you run 'make'?")
    try:
        devnull = open(os.devnull, "w")
        subprocess.check_call([POLISH_BIN, "-h"], stderr=devnull)
    except subprocess.CalledProcessError as e:
        if e.returncode == -9:
            logger.error("Looks like the system ran out of memory")
        raise PolishException(str(e))
    except OSError as e:
        raise PolishException(str(e))