예제 #1
0
def run_subtool(parser, args):
    if args.command == 'combine':
        import combine as submodule
    elif args.command == 'events':
        import events as submodule
    elif args.command == 'fasta':
        import fasta as submodule
    elif args.command == 'fastq':
        import fastq as submodule
    elif args.command == 'hist':
        import hist as submodule
    elif args.command == 'nucdist':
        import nucdist as submodule
    elif args.command == 'occupancy':
        import occupancy as submodule
    elif args.command == 'qualdist':
        import qualdist as submodule
    elif args.command == 'readstats':
        import readstats as submodule
    elif args.command == 'stats':
        import stats as submodule
    elif args.command == 'tabular':
        import tabular as submodule
    elif args.command == 'times':
        import times as submodule
    elif args.command == 'squiggle':
        import squiggle as submodule
    elif args.command == 'winner':
        import winner as submodule
    elif args.command == 'yield_plot':
        import yield_plot as submodule

    # run the chosen submodule.
    submodule.run(parser, args)
예제 #2
0
def main():
    """
    Run program
    """
    cmn.make_dir(cmn.LOG_DIR)
    logging.basicConfig(
        # filename=os.path.join(cmn.LOG_DIR, cmn.LOG_FILE_NAME % time.strftime(cmn.LOG_FILE_NAME_TIME)),
        handlers=[
            logging.FileHandler(
                os.path.join(
                    cmn.LOG_DIR, cmn.LOG_FILE_NAME %
                    time.strftime(cmn.LOG_FILE_NAME_TIME))),
            logging.StreamHandler()
        ],
        level=cmn.LOG_LEVEL,
        format=cmn.LOG_MSG_FORMAT,
        datefmt=cmn.LOG_TIME_FORMAT)

    start_time = time.time()
    logging.info("Starting program ...\n")

    if "-hmo" in sys.argv:
        logging.info(
            "Detected 'heatmap only' command line argument, program will use pre-existing combined PTEN correlation file.\n"
        )
    else:
        combine.run()
    heatmap.run()

    logging.info("Finished running program.")
    run_time = time.time() - start_time
    logging.info("Total run time: %s.\n" %
                 time.strftime('%H:%M:%S', time.gmtime(run_time)))
예제 #3
0
def run_subtool(parser, args):
    if args.command == 'combine':
        import combine as submodule
    elif args.command == 'events':
        import events as submodule
    elif args.command == 'fasta':
        import fasta as submodule
    elif args.command == 'fastq':
        import fastq as submodule
    elif args.command == 'hist':
        import hist as submodule
    elif args.command == 'nucdist':
        import nucdist as submodule
    elif args.command == 'occupancy':
        import occupancy as submodule
    elif args.command == 'qualdist':
        import qualdist as submodule
    elif args.command == 'readstats':
        import readstats as submodule
    elif args.command == 'stats':
        import stats as submodule
    elif args.command == 'tabular':
        import tabular as submodule
    elif args.command == 'times':
        import times as submodule
    elif args.command == 'squiggle':
        import squiggle as submodule
    elif args.command == 'winner':
        import winner as submodule
    elif args.command == 'yield_plot':
        import yield_plot as submodule

    # run the chosen submodule.
    submodule.run(parser, args)
예제 #4
0
def run_combine():
    import combine
    file_list = []
    output_path = sys.argv[2]
    for i in range(3, len(sys.argv)):
        file_list.append(sys.argv[i])
    combine.run(output_path, file_list)
예제 #5
0
def run_combine(output_path, file_list):
    import combine
    combine.run(output_path, file_list)
예제 #6
0
 def run(self):
     combine_to = Path(self.output().path)
     combine_to.parent.mkdir(parents=True, exist_ok=True)
     combine.run(combine_to, [Path(input_.path) for input_ in self.input()])