From: kinoshita-eos Date: Fri, 30 Jan 2015 04:48:21 +0000 (+0900) Subject: Modify: Bug-Fixed PIONE tutorial Advanced4 X-Git-Tag: v2.0.2p0099~1 X-Git-Url: http://git.sourceforge.jp/view?a=commitdiff_plain;h=c9c7cd903110da868fdd6763b910fed389c7d99a;p=eos%2Ftutorial.git Modify: Bug-Fixed PIONE tutorial Advanced4 modified: SampleCode/PIONE/Advanced4/Create_Sample3d.pione Add: PIONE tutorial to compare "each" with "all". new file: SampleCode/PIONE/Basic4/SizeOut1.pione new file: SampleCode/PIONE/Basic4/SizeOut2.pione new file: SampleCode/PIONE/Basic4/SizeOut3.pione new file: SampleCode/PIONE/Basic4/SizeOut4.pione --- diff --git a/SampleCode/PIONE/Advanced4/Create_Sample3d.pione b/SampleCode/PIONE/Advanced4/Create_Sample3d.pione index b48f599..2a96cb3 100644 --- a/SampleCode/PIONE/Advanced4/Create_Sample3d.pione +++ b/SampleCode/PIONE/Advanced4/Create_Sample3d.pione @@ -33,5 +33,5 @@ Action sampling_length=$(echo "scale=7; ${length} * ${ref_size} / ${image_size}" | bc) - mrcImageSamplingUnitChange -i {$I[1]} -o {$I[1][1]}.sample3d -m 2 -S ${sampling_length} ${sampling_length} ${sampling_length} + mrcImageSamplingUnitChange -i {$I[1]} -o {$O[1]} -m 2 -S ${sampling_length} ${sampling_length} ${sampling_length} End diff --git a/SampleCode/PIONE/Basic4/SizeOut1.pione b/SampleCode/PIONE/Basic4/SizeOut1.pione new file mode 100644 index 0000000..3cfc708 --- /dev/null +++ b/SampleCode/PIONE/Basic4/SizeOut1.pione @@ -0,0 +1,14 @@ +Rule Main + input '*.mrc' + output '*.txt'.all +Flow + rule SizeOut {val:1} +End + +Rule SizeOut + input '*.mrc' + output '{$I[1][1]}{$val}.txt' + param $val +Action + wc {$I[1]} > {$O[1]} +End \ No newline at end of file diff --git a/SampleCode/PIONE/Basic4/SizeOut2.pione b/SampleCode/PIONE/Basic4/SizeOut2.pione new file mode 100644 index 0000000..7baaf53 --- /dev/null +++ b/SampleCode/PIONE/Basic4/SizeOut2.pione @@ -0,0 +1,14 @@ +Rule Main + input 'A.mrc' + output '*.txt'.all +Flow + rule SizeOut {val:1.upto(5)} +End + +Rule SizeOut + input 'A.mrc' + output 'A{$val}.txt' + param $val +Action + wc {$I[1]} > {$O[1]} +End \ No newline at end of file diff --git a/SampleCode/PIONE/Basic4/SizeOut3.pione b/SampleCode/PIONE/Basic4/SizeOut3.pione new file mode 100644 index 0000000..ed8b99b --- /dev/null +++ b/SampleCode/PIONE/Basic4/SizeOut3.pione @@ -0,0 +1,16 @@ +Rule Main + input 'A.mrc' + output '*.txt'.all +Flow + rule SizeOut +End + +Rule SizeOut + input 'A.mrc' + output '*.txt'.all +Action + for (( i=1; i<6; i++ )) + do + wc {$I[1]} > "{$I[1][1]}$i.txt" + done +End \ No newline at end of file diff --git a/SampleCode/PIONE/Basic4/SizeOut4.pione b/SampleCode/PIONE/Basic4/SizeOut4.pione new file mode 100644 index 0000000..df5495a --- /dev/null +++ b/SampleCode/PIONE/Basic4/SizeOut4.pione @@ -0,0 +1,14 @@ +Rule Main + input 'A.mrc' + output '*.txt'.all +Flow + rule SizeOut {val:1.upto(5)} +End + +Rule SizeOut + input 'A.mrc' + output '{$I[1][1]}{$val}.txt' + param $val +Action + wc {$I[1]} > {$O[1]} +End \ No newline at end of file