From 7585813ebd1e1f5e87c20b472a45e05e74a9dfca Mon Sep 17 00:00:00 2001 From: Matthias Bernt Date: Fri, 19 Feb 2021 19:41:33 +0100 Subject: [PATCH] fix PSMFeatureExtractor --- tools/openms/PSMFeatureExtractor.patch | 22 +++++++++++----------- tools/openms/PSMFeatureExtractor.xml | 9 ++++----- 2 files changed, 15 insertions(+), 16 deletions(-) diff --git a/tools/openms/PSMFeatureExtractor.patch b/tools/openms/PSMFeatureExtractor.patch index 4aca0a893..c66c5d52a 100644 --- a/tools/openms/PSMFeatureExtractor.patch +++ b/tools/openms/PSMFeatureExtractor.patch @@ -1,18 +1,19 @@ ---- PSMFeatureExtractor.xml.orig 2021-02-16 16:30:38.919393993 +0100 -+++ PSMFeatureExtractor.xml 2021-02-16 16:32:34.862390198 +0100 -@@ -17,6 +17,11 @@ +--- PSMFeatureExtractor.xml.orig 2021-02-19 19:18:58.635157367 +0100 ++++ PSMFeatureExtractor.xml 2021-02-19 19:23:28.943370062 +0100 +@@ -17,8 +17,12 @@ ## Preprocessing mkdir in && +#if $in -+${ ' '.join(["ln -s '%s' 'in/%s.%s' &&" % (_, re.sub('[^\w\-_]', '_', _.element_identifier), $gxy2omsext(_.ext)) for _ in $in if _]) } + mkdir ${' '.join(["'in/%s'" % (i) for i, f in enumerate($in) if f])} && + ${' '.join(["ln -s '%s' 'in/%s/%s.%s' && " % (f, i, re.sub('[^\w\-_]', '_', f.element_identifier), $gxy2omsext(f.ext)) for i, f in enumerate($in) if f])} +#else if $in_single +ln -s '$in_single' 'in/${re.sub("[^\w\-_]", "_", $in_single.element_identifier)}.$gxy2omsext($in_single.ext)' && +#end if - mkdir ${' '.join(["'in/%s'" % (i) for i, f in enumerate($in) if f])} && - ${' '.join(["ln -s '%s' 'in/%s/%s.%s' && " % (f, i, re.sub('[^\w\-_]', '_', f.element_identifier), $gxy2omsext(f.ext)) for i, f in enumerate($in) if f])} mkdir out && -@@ -28,7 +33,11 @@ + + ## Main program call +@@ -28,6 +32,10 @@ python3 '$__tool_directory__/fill_ctd.py' '@EXECUTABLE@.ctd' '$args_json' '$hardcoded_json' && @EXECUTABLE@ -ini @EXECUTABLE@.ctd -in @@ -23,14 +24,13 @@ +#end if -out 'out/output.${out_type}' - -@@ -42,7 +51,8 @@ +@@ -42,7 +50,8 @@ - -+ -+ ++ ++ diff --git a/tools/openms/PSMFeatureExtractor.xml b/tools/openms/PSMFeatureExtractor.xml index a6b1a9fd9..48a0a3cd8 100644 --- a/tools/openms/PSMFeatureExtractor.xml +++ b/tools/openms/PSMFeatureExtractor.xml @@ -18,12 +18,11 @@ ## Preprocessing mkdir in && #if $in -${ ' '.join(["ln -s '%s' 'in/%s.%s' &&" % (_, re.sub('[^\w\-_]', '_', _.element_identifier), $gxy2omsext(_.ext)) for _ in $in if _]) } +mkdir ${' '.join(["'in/%s'" % (i) for i, f in enumerate($in) if f])} && +${' '.join(["ln -s '%s' 'in/%s/%s.%s' && " % (f, i, re.sub('[^\w\-_]', '_', f.element_identifier), $gxy2omsext(f.ext)) for i, f in enumerate($in) if f])} #else if $in_single ln -s '$in_single' 'in/${re.sub("[^\w\-_]", "_", $in_single.element_identifier)}.$gxy2omsext($in_single.ext)' && #end if -mkdir ${' '.join(["'in/%s'" % (i) for i, f in enumerate($in) if f])} && -${' '.join(["ln -s '%s' 'in/%s/%s.%s' && " % (f, i, re.sub('[^\w\-_]', '_', f.element_identifier), $gxy2omsext(f.ext)) for i, f in enumerate($in) if f])} mkdir out && ## Main program call @@ -51,8 +50,8 @@ ${' '.join(["'in/%s/%s.%s'"%(i, re.sub('[^\w\-_]', '_', f.element_identifier), $ - - + +