diff options
author | hieuhoang1972 <hieuhoang1972@1f5c12ca-751b-0410-a591-d2e778427230> | 2011-10-10 08:28:55 +0400 |
---|---|---|
committer | hieuhoang1972 <hieuhoang1972@1f5c12ca-751b-0410-a591-d2e778427230> | 2011-10-10 08:28:55 +0400 |
commit | 235dda25e7eb5cb4619a8c2a88ada0cafcb8d13c (patch) | |
tree | 346ccb29f20ba922140f563a18c8f2dced45a5b7 /scripts/generic | |
parent | 71d0d389c5fd7f25b42c0ada827ada8dd800cfa4 (diff) |
extractor wrapper to make it work on SGE
git-svn-id: https://mosesdecoder.svn.sourceforge.net/svnroot/mosesdecoder/trunk@4315 1f5c12ca-751b-0410-a591-d2e778427230
Diffstat (limited to 'scripts/generic')
-rwxr-xr-x | scripts/generic/moses-parallel.pl | 4 | ||||
-rwxr-xr-x | scripts/generic/qsub-wrapper.pl | 4 |
2 files changed, 4 insertions, 4 deletions
diff --git a/scripts/generic/moses-parallel.pl b/scripts/generic/moses-parallel.pl index 3139be351..1e8d14eee 100755 --- a/scripts/generic/moses-parallel.pl +++ b/scripts/generic/moses-parallel.pl @@ -454,8 +454,8 @@ while ($robust && scalar @idx_todo) { open (IN,"${jobscript}${idx}.log") or die "Can't read id of job ${jobscript}${idx}.log"; chomp($res=<IN>); - split(/\s+/,$res); - $id=$_[2]; + my @arrayStr = split(/\s+/,$res); + $id=$arrayStr[2]; die "Failed to guess job id from $jobscript$idx.log, got: $res" if $id !~ /^[0-9]+$/; close(IN); diff --git a/scripts/generic/qsub-wrapper.pl b/scripts/generic/qsub-wrapper.pl index 2c90b73d7..65158c00f 100755 --- a/scripts/generic/qsub-wrapper.pl +++ b/scripts/generic/qsub-wrapper.pl @@ -148,8 +148,8 @@ safesystem($qsubcmd) or die; my $res; open (IN,"$jobscript.log") or die "Can't read main job id: $jobscript.log"; chomp($res=<IN>); -split(/\s+/,$res); -my $id=$_[2]; +my @arrayStr = split(/\s+/,$res); +my $id=$arrayStr[2]; die "Failed to get job id from $jobscript.log, got: $res" if $id !~ /^[0-9]+$/; close(IN); |