Skip to content

Commit 7553b10

Browse files
authored
Merge pull request #326 from PNNL-CompBio/sarc_pdo
This built smoothly with no issues. Merging
2 parents a4ce8f2 + e2b199f commit 7553b10

17 files changed

+3471
-9
lines changed

build/build_all.py

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -40,7 +40,7 @@ def main():
4040
parser.add_argument('--figshare', action='store_true', help="Upload all local data to Figshare. FIGSHARE_TOKEN must be set in local environment.")
4141
parser.add_argument('--all',dest='all',default=False,action='store_true', help="Run all data build commands. This includes docker, samples, omics, drugs, exp arguments. This does not run the validate or figshare commands")
4242
parser.add_argument('--high_mem',dest='high_mem',default=False,action='store_true',help = "If you have 32 or more CPUs, this option is recommended. It will run many code portions in parallel. If you don't have enough memory, this will cause a run failure.")
43-
parser.add_argument('--dataset',dest='datasets',default='broad_sanger,hcmi,beataml,cptac,mpnst,mpnstpdx,pancpdo,bladderpdo',help='Datasets to process. Defaults to all available.')
43+
parser.add_argument('--dataset',dest='datasets',default='broad_sanger,hcmi,beataml,cptac,mpnst,mpnstpdx,pancpdo,bladderpdo,sarcpdo',help='Datasets to process. Defaults to all available.')
4444
parser.add_argument('--version', type=str, required=False, help='Version number for the Figshare upload title (e.g., "0.1.29"). This is required for Figshare upload. This must be a higher version than previously published versions.')
4545
parser.add_argument('--github-username', type=str, required=False, help='GitHub username for the repository.')
4646
parser.add_argument('--github-email', type=str, required=False, help='GitHub email for the repository.')
@@ -62,7 +62,7 @@ def run_docker_cmd(cmd_arr,filename):
6262
print('running...'+filename)
6363
env = os.environ.copy()
6464
if 'SYNAPSE_AUTH_TOKEN' not in env.keys():
65-
print('You need to set the SYNAPSE_AUTH_TOKEN to acess the MPNST and beatAML Datasets')
65+
print('You need to set the SYNAPSE_AUTH_TOKEN to acess the MPNST, beatAML, bladderpdo, pancpdo, or sarcpdo datasets')
6666
docker_run = ['docker','run','--rm','-v',env['PWD']+'/local/:/tmp/','--platform=linux/amd64']
6767
else:
6868
docker_run = ['docker','run','--rm','-v',env['PWD']+'/local/:/tmp/','-e','SYNAPSE_AUTH_TOKEN='+env['SYNAPSE_AUTH_TOKEN'],'--platform=linux/amd64']
@@ -122,6 +122,7 @@ def process_docker(datasets):
122122
'mpnstpdx': ['mpnstpdx'],
123123
'pancpdo': ['pancpdo'],
124124
'bladderpdo': ['bladderpdo'],
125+
'sarcpdo': ['sarcpdo'],
125126
'cptac': ['cptac'],
126127
'genes': ['genes'],
127128
'upload': ['upload']
@@ -329,9 +330,9 @@ def get_latest_commit_hash(owner, repo, branch='main'):
329330
# Error handling for required tokens
330331
if args.figshare and not figshare_token:
331332
raise ValueError("FIGSHARE_TOKEN environment variable is not set.")
332-
if any(dataset in args.datasets for dataset in ['beataml', 'mpnst', 'bladderpdo', 'pancpdo']) and not synapse_auth_token:
333+
if any(dataset in args.datasets for dataset in ['beataml', 'mpnst', 'bladderpdo', 'pancpdo','sarcpdo']) and not synapse_auth_token:
333334
if args.docker or args.samples or args.omics or args.drugs or args.exp or args.all: # Token only required if building data, not upload or validate.
334-
raise ValueError("SYNAPSE_AUTH_TOKEN is required for accessing MPNST and beatAML datasets.")
335+
raise ValueError("SYNAPSE_AUTH_TOKEN is required for accessing MPNST, beatAML, bladderpdo, pancpdo, or sarcpdo datasets.")
335336

336337
######
337338
### Begin Pipeline
@@ -408,7 +409,7 @@ def get_latest_commit_hash(owner, repo, branch='main'):
408409
# if args.figshare or args.validate:
409410
# FigShare File Prefixes:
410411

411-
prefixes = ['beataml', 'hcmi', 'cptac', 'mpnst', 'mpnstpdx', 'pancpdo', 'bladderpdo', 'genes', 'drugs']
412+
prefixes = ['beataml', 'hcmi', 'cptac', 'mpnst', 'mpnstpdx', 'pancpdo', 'bladderpdo','sarcpdo', 'genes', 'drugs']
412413
broad_sanger_datasets = ["ccle","ctrpv2","fimm","gdscv1","gdscv2","gcsi","prism","nci60"]
413414
if "broad_sanger" in datasets:
414415
prefixes.extend(broad_sanger_datasets)

build/build_dataset.py

Lines changed: 3 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -44,6 +44,7 @@ def process_docker(dataset,validate):
4444
'mpnstpdx': ['mpnstpdx'],
4545
'pancpdo': ['pancpdo'],
4646
'cptac': ['cptac'],
47+
'sarcpdo': ['sarcpdo'],
4748
'genes': ['genes'],
4849
'upload': ['upload'],
4950
'bladderpdo': ['bladderpdo']
@@ -125,8 +126,9 @@ def process_omics(executor, dataset, should_continue):
125126
'broad_sanger': ['copy_number', 'mutations', 'proteomics', 'transcriptomics'],
126127
'cptac': ['copy_number', 'mutations', 'proteomics', 'transcriptomics'],
127128
'hcmi': ['mutations', 'transcriptomics'],
129+
'mpnstpdx':['copy_number', 'mutations', 'proteomics', 'transcriptomics'],
130+
'sarcpdo': ['mutations', 'transcriptomics'],
128131
'pancpdo': ['transcriptomics'],
129-
'mpnstpdx':['copy_number', 'mutations', 'proteomics', 'transcriptomics'],
130132
'bladderpdo': ['copy_number', 'mutations', 'transcriptomics']
131133
}
132134

build/docker/Dockerfile.sarcpdo

Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
FROM python:3.9
2+
3+
WORKDIR /usr/src/app
4+
5+
6+
COPY build/sarcpdo/00_createSarcPDOSampleFile.py .
7+
COPY build/sarcpdo/01_createSarcPDOOmicsFiles.py .
8+
COPY build/sarcpdo/02_createSarcPDODrugsFile.py .
9+
COPY build/sarcpdo/03_createSarcPDOExperimentFile.py .
10+
COPY build/sarcpdo/requirements.txt .
11+
COPY build/sarcpdo/*sh ./
12+
COPY build/utils/* ./
13+
14+
# Set MPLCONFIGDIR to a writable directory
15+
ENV MPLCONFIGDIR=/app/tmp/matplotlib
16+
RUN mkdir -p /app/tmp/matplotlib
17+
18+
RUN pip install --no-cache-dir -r requirements.txt
19+
20+
VOLUME ['/tmp']
21+

build/docker/docker-compose.yml

Lines changed: 8 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,14 @@ services:
7070
HTTPS_PROXY: ${HTTPS_PROXY}
7171
platform: linux/amd64
7272
image: cptac:latest
73-
73+
sarcpdo:
74+
build:
75+
context: ../../
76+
dockerfile: build/docker/Dockerfile.sarcpdo
77+
args:
78+
HTTPS_PROXY: ${HTTPS_PROXY}
79+
platform: linux/amd64
80+
image: sarcpdo:latest
7481
bladderpdo:
7582
build:
7683
context: ../../

0 commit comments

Comments
 (0)