From b0a402b3ac0fcc42a2d3fa5ab7c1a2caef2825f4 Mon Sep 17 00:00:00 2001 From: Patrick Jentsch Date: Mon, 20 Jan 2020 15:09:38 +0100 Subject: [PATCH] Add zip creation --- Dockerfile | 1 + nlp | 14 ++++++++++++++ 2 files changed, 15 insertions(+) diff --git a/Dockerfile b/Dockerfile index 89f9cf2..1e8e748 100644 --- a/Dockerfile +++ b/Dockerfile @@ -14,6 +14,7 @@ RUN apt-get update \ python2.7 \ python3.5 \ python3-pip \ + zip \ && rm -rf /var/lib/apt/lists/* \ && pip3 install \ setuptools \ diff --git a/nlp b/nlp index 79af9af..7d6be3a 100755 --- a/nlp +++ b/nlp @@ -43,6 +43,7 @@ class NLPWorkflow(WorkflowRunner): self.jobs = analyze_jobs(args.input_dir, args.output_dir) self.lang = args.lang self.n_cores = args.n_cores + self.output_dir = args.output_dir def workflow(self): if len(self.jobs) == 0: @@ -90,6 +91,19 @@ class NLPWorkflow(WorkflowRunner): ) ) + vrt_zip_jobs = [] + vrt_zip_job_dependencies = nlp_jobs + cmd = 'cd "%s" && zip vrt.zip */*.vrt -x "pyflow.data*" && cd -' % ( + self.output_dir + ) + vrt_zip_jobs.append( + self.addTask( + command=cmd, + dependencies=vrt_zip_job_dependencies, + label='vrt_zip_job_-_%i' % (index) + ) + ) + def analyze_jobs(input_dir, output_dir): jobs = []