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
""" | |
AWS Batch wrapper for Luigi | |
From the AWS website: | |
AWS Batch enables you to run batch computing workloads on the AWS Cloud. | |
Batch computing is a common way for developers, scientists, and engineers | |
to access large amounts of compute resources, and AWS Batch removes the | |
undifferentiated heavy lifting of configuring and managing the required |
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
import os | |
from subprocess import check_output | |
from tempfile import mkstemp | |
import sys | |
import boto3 | |
import requests | |
s3 = boto3.client('s3') |
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
import time | |
import logging | |
import boto3 | |
import luigi | |
POLL_TIME = 2 | |
client = boto3.client('ecs') | |
logger = logging.getLogger('luigi-interface') |
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
import requests | |
import json | |
from os.path import join | |
CGHUB_API_ENDPOINT = 'https://cghub.ucsc.edu/cghub/metadata' | |
SAMPLE_MAPPING = {'tumor': ['0' + str(i) for i in range(1,10)], | |
'normal': ['1' + str(i) for i in range(5)]} | |
LIBRARY_MAPPING = {'dna': 'DNA-Seq', 'rna': 'RNA-Seq', 'mirna': 'miRNA-Seq'} | |
def cgquery(full_details=False, **query_dict): |