set atlas_dir = ../.. if ( 2 < 2 ) then setenv AFNI_COMPRESSOR GZIP set dset = macaque1+orig. set base = ../../D99_template.nii.gz if ( 2 < 3 ) then set segset = else if ( 2 > = 4 ) then set rightseg = endif set finalmaster = macaque1+orig. set dsetprefix = `@GetAfniPrefix $dset` @GetAfniPrefix macaque1+orig. set origdsetprefix = macaque1 if ( != ) then @Align_Centers -base ../../D99_template.nii.gz -dset macaque1+orig. ++ 3dcopy: AFNI version=AFNI_16.2.12 (Aug 23 2016) [64-bit] ++ 3drefit: AFNI version=AFNI_16.2.12 (Aug 23 2016) [64-bit] ++ Authored by: RW Cox ++ Processing AFNI dataset ./macaque1_shft+orig ++ 3drefit processed 1 datasets set dset = macaque1_shft+orig set dsetprefix = `@GetAfniPrefix $dset` @GetAfniPrefix macaque1_shft+orig align_epi_anat.py -dset2 macaque1_shft+orig -dset1 ../../D99_template.nii.gz -overwrite -dset2to1 -giant_move -suffix _al2std -dset1_strip None -dset2_strip None #++ align_epi_anat version: 1.55 #++ turning off tshift, volume registration, resampling #++ turning off tshift, volume registration, resampling #Script is running (command trimmed): 3dAttribute DELTA ./macaque1_shft+orig #Script is running (command trimmed): 3dAttribute DELTA ./macaque1_shft+orig #Script is running: 3dAttribute DELTA /Users/glend/macaquetest/macaqueatlas_1.2b/D99_template.nii.gz #++ Multi-cost is lpa #++ Removing all the temporary files #Script is running: \rm -f ./__tt_macaque1_shft* #Script is running: \rm -f ./__tt_D99_template* #Script is running (command trimmed): 3dcopy /Users/glend/macaquetest/macaqueatlas_1.2b/D99_template.nii.gz ./__tt_D99_template+orig ++ 3dcopy: AFNI version=AFNI_16.2.12 (Aug 23 2016) [64-bit] #Script is running (command trimmed): 3dinfo ./__tt_D99_template+orig | \grep 'Data Axes Tilt:'|\grep 'Oblique' #++ Dataset /Users/glend/macaquetest/macaqueatlas_1.2b/AFNI_scripts/example_macaque/__tt_D99_template+orig is not oblique #Script is running (command trimmed): 3dinfo ./macaque1_shft+orig | \grep 'Data Axes Tilt:'|\grep 'Oblique' #++ Dataset /Users/glend/macaquetest/macaqueatlas_1.2b/AFNI_scripts/example_macaque/macaque1_shft+orig is not oblique #++ using 0th sub-brick because only one found #Script is running (command trimmed): 3dbucket -prefix ./__tt_macaque1_shft_ts ./macaque1_shft+orig'[0]' ++ 3dbucket: AFNI version=AFNI_16.2.12 (Aug 23 2016) [64-bit] #++ removing skull or area outside brain #++ Computing weight mask #Script is running (command trimmed): 3dBrickStat -automask -percentile 90.000000 1 90.000000 ./__tt_macaque1_shft_ts+orig #++ Applying threshold of 8095.000000 on /Users/glend/macaquetest/macaqueatlas_1.2b/AFNI_scripts/example_macaque/__tt_macaque1_shft_ts+orig #Script is running (command trimmed): 3dcalc -datum float -prefix ./__tt_macaque1_shft_ts_wt -a ./__tt_macaque1_shft_ts+orig -expr 'min(1,(a/8095.000000))' ++ 3dcalc: AFNI version=AFNI_16.2.12 (Aug 23 2016) [64-bit] ++ Authored by: A cast of thousands #++ Aligning dset1 data to dset2 data #Script is running (command trimmed): 3dAllineate -lpa -wtprefix ./__tt_D99_template_al2std_wtal -weight ./__tt_macaque1_shft_ts_wt+orig -source ./__tt_D99_template+orig -prefix ./__tt_D99_template_al2std -base ./__tt_macaque1_shft_ts+orig -cmass -1Dmatrix_save ./D99_template_al2std_mat.aff12.1D -master BASE -mast_dxyz 0.250000 -weight_frac 1.0 -maxrot 6 -maxshf 10 -VERB -warp aff -source_automask+4 -twobest 11 -twopass -VERB -maxrot 45 -maxshf 40 -fineblur 1 -source_automask+2 ++ 3dAllineate: AFNI version=AFNI_16.2.12 (Aug 23 2016) [64-bit] ++ Authored by: Zhark the Registrator *+ WARNING: Small value 0.25 after -mast_dxyz :-( ++ Source dataset: ./__tt_D99_template+orig.HEAD ++ Base dataset: ./__tt_macaque1_shft_ts+orig.HEAD ++ Loading datasets ++ 7006921 voxels in -source_automask+2 ++ Zero-pad: xbot=4 xtop=4 ++ Zero-pad: ybot=4 ytop=4 ++ Zero-pad: zbot=1 ztop=0 ++ 755712 voxels [84.2%] in weight mask ++ Number of points for matching = 755712 ++ NOTE: base and source coordinate systems have different handedness + Orientations: base=Left handed (LAI); source=Right handed (LPI) ++ Local correlation: blok type = 'RHDD(6.54321)' ++ base center of mass = 53.611 52.772 40.484 (index) + source center of mass = 136.500 147.653 125.509 (index) + source-target CM = 2.236 5.065 1.893 (xyz) + center of mass shifts = 2.236 5.065 1.893 ++ shift param auto-range: -30.8..35.3 -28.0..38.1 -24.4..28.2 + Range param#4 [z-angle] = -6.000000 .. 6.000000 + Range param#5 [x-angle] = -6.000000 .. 6.000000 + Range param#6 [y-angle] = -6.000000 .. 6.000000 + Range param#1 [x-shift] = -7.763577 .. 12.236423 + Range param#2 [y-shift] = -4.934971 .. 15.065029 + Range param#3 [z-shift] = -8.106821 .. 11.893179 + Range param#4 [z-angle] = -45.000000 .. 45.000000 + Range param#5 [x-angle] = -45.000000 .. 45.000000 + Range param#6 [y-angle] = -45.000000 .. 45.000000 + Range param#1 [x-shift] = -37.763577 .. 42.236423 + Range param#2 [y-shift] = -34.934971 .. 45.065029 + Range param#3 [z-shift] = -38.106819 .. 41.893181 + 12 free parameters ++ Normalized convergence radius = 0.000625 ++ changing output grid spacing to 0.2500 mm ++ OpenMP thread count = 8 ++ ======= Allineation of 1 sub-bricks using Local Pearson Correlation Abs ======= + source mask has 7006921 [out of 23379125] voxels + base mask has 263555 [out of 897728] voxels ++ ========== sub-brick #0 ========== [total CPU to here=4.9 s] ++ *** Coarse pass begins *** + * Enter alignment setup routine + - copying base image + - copying source image + - Smoothing base; radius=2.22 + - Smoothing source; radius=2.22 + !source mask fill: ubot=43 usiz=77 + - copying weight image + - using 98765 points from base image [use_all=0] + * Exit alignment setup routine + - Search for coarse starting parameters + 74071 total points stored in 533 'RHDD(6.9102)' bloks + - number of free params = 6 + - Testing (64+61)*64 params:#oo+o+..+++.ooo+.+-.o..oo+-.$o+ooo- + - best 23 costs found: 0 v= 0.914002: 2.24 5.07 1.89 0.00 0.00 0.00 [grid] 1 v= 0.917926: 6.32 -1.16 -5.90 -4.32 -22.85 18.95 [rand] 2 v= 0.927979: 6.32 -1.16 -5.90 4.32 -22.85 18.95 [rand] 3 v= 0.928632: -1.84 -1.16 -5.90 4.32 -22.85 -18.95 [rand] 4 v= 0.934573: 34.45 -23.98 -34.25 40.41 19.09 40.75 [rand] 5 v= 0.938235: 28.25 -25.21 17.61 5.50 -4.28 12.07 [rand] 6 v= 0.938878: 21.73 -11.61 -0.71 -30.54 -19.59 -20.03 [rand] 7 v= 0.939990: 15.57 31.73 15.23 -30.00 -30.00 -15.00 [grid] 8 v= 0.940112: 25.77 -3.48 17.86 -26.66 31.62 32.06 [rand] 9 v= 0.942257: -1.84 11.29 -5.90 -4.32 22.85 -18.95 [rand] 10 v= 0.942517: -1.84 -1.16 -5.90 -4.32 -22.85 -18.95 [rand] 11 v= 0.942626: 15.57 -8.27 -11.44 15.00 -15.00 -30.00 [grid] 12 v= 0.943178: 6.32 11.29 9.69 -4.32 22.85 -18.95 [rand] 13 v= 0.945597: -1.84 11.29 9.69 -4.32 22.85 18.95 [rand] 14 v= 0.945853: -24.43 31.73 15.23 -15.00 -15.00 -30.00 [grid] 15 v= 0.945875: -21.30 -3.48 17.86 26.66 31.62 -32.06 [rand] 16 v= 0.945882: -1.84 -1.16 9.69 -4.32 22.85 -18.95 [rand] 17 v= 0.946435: -11.10 -8.27 15.23 15.00 30.00 30.00 [grid] 18 v= 0.947345: -11.10 31.73 15.23 15.00 -30.00 15.00 [grid] 19 v= 0.947390: 28.90 31.73 28.56 -30.00 -30.00 -30.00 [grid] 20 v= 0.947760: 15.57 31.73 15.23 -15.00 15.00 -15.00 [grid] 21 v= 0.947809: 15.57 -21.60 -24.77 -15.00 -30.00 -30.00 [grid] 22 v= 0.948069: -11.10 31.73 -24.77 -30.00 -15.00 30.00 [grid] *[#8007=0.911321] *[#8009=0.880532] *[#8011=0.877848] *[#8054=0.877572] *[#8055=0.875821] *[#8062=0.874062] *[#8063=0.872918] *[#8079=0.865513] *[#8089=0.86406] *[#8090=0.846299] *[#8091=0.834429] *[#8094=0.826984] *[#8095=0.824293] *[#8096=0.822415] *[#8099=0.814098] *[#8100=0.802688] *[#8101=0.797328] *[#8104=0.793222] *[#8106=0.788744] *[#8107=0.777103] *[#8108=0.775542] *[#8111=0.763234] *[#8112=0.759795] *[#8114=0.759589] *[#8115=0.757751] *[#8120=0.753889] *[#8122=0.752662] *[#8123=0.752526] + - costs of the above after a little optimization: 0 v= 0.877848: 2.21 -0.87 2.38 0.00 0.00 0.00 [grid] 1 v= 0.872918: 5.79 -4.81 -4.55 -3.71 -21.56 17.95 [rand] * 2 v= 0.752526: 2.51 -3.71 -5.69 2.26 -20.41 5.75 [rand] 3 v= 0.867795: -0.14 -2.51 -7.75 3.40 -22.78 -12.03 [rand] 4 v= 0.891642: 34.61 -23.75 -37.91 37.79 19.00 40.19 [rand] 5 v= 0.931898: 28.72 -25.16 17.23 9.79 -4.39 11.06 [rand] 6 v= 0.930508: 21.71 -11.76 0.24 -30.54 -20.55 -19.70 [rand] 7 v= 0.939971: 15.59 31.78 14.89 -29.94 -30.02 -15.22 [grid] 8 v= 0.927383: 22.85 -2.74 18.65 -26.22 31.15 31.02 [rand] 9 v= 0.942134: -1.85 11.29 -5.88 -3.90 22.70 -18.99 [rand] 10 v= 0.891421: 1.47 -0.65 -6.11 -4.24 -21.76 -17.93 [rand] 11 v= 0.938545: 15.40 -7.91 -12.05 14.83 -15.45 -30.53 [grid] 12 v= 0.927418: 2.00 11.34 9.99 -4.37 23.65 -18.56 [rand] 13 v= 0.920104: 1.73 10.50 9.33 -4.50 22.68 18.52 [rand] 14 v= 0.931153: -20.47 31.76 14.94 -15.28 -14.98 -29.86 [grid] 15 v= 0.937153: -19.41 -3.55 15.79 27.16 32.21 -30.83 [rand] 16 v= 0.926254: -0.91 -5.50 5.87 -4.78 21.69 -19.70 [rand] 17 v= 0.933359: -11.24 -7.89 16.16 14.87 28.45 30.76 [grid] 18 v= 0.935161: -10.48 32.41 14.09 15.03 -28.83 15.29 [grid] 19 v= 0.934457: 29.09 31.71 28.27 -29.80 -30.35 -32.70 [grid] 20 v= 0.944691: 15.66 32.49 15.32 -14.60 15.08 -14.87 [grid] 21 v= 0.936165: 15.85 -21.42 -22.79 -14.62 -21.78 -30.57 [grid] 22 v= 0.939029: -9.48 31.80 -23.89 -30.19 -15.01 30.48 [grid] + - save # 2 for twobest + - save # 3 for twobest + - save # 1 for twobest + - save # 0 for twobest + - save #10 for twobest + - save # 4 for twobest + - save #13 for twobest + - save #16 for twobest + - save # 8 for twobest + - save #12 for twobest + - save # 6 for twobest + - Coarse startup search net CPU time = 46.5 s ++ Start refinement #1 on 12 coarse parameter sets + * Enter alignment setup routine + - Smoothing base; radius=1.73 + - Smoothing source; radius=1.73 + !source mask fill: ubot=43 usiz=77 + - retaining old weight image + - using 148147 points from base image [use_all=0] + * Exit alignment setup routine + 106097 total points stored in 674 'RHDD(6.76755)' bloks *[#8706=0.7218] *[#8718=0.620209] *[#8720=0.610506] *[#8724=0.607017] *[#8729=0.59958] *[#8741=0.59176] *[#8742=0.581493] *[#8745=0.578846] *[#8746=0.577554] *[#8752=0.570212] *[#8753=0.568333] *[#8754=0.565845] *[#8756=0.565077] *[#8757=0.562102] *[#8759=0.55701] *[#8760=0.553394] *[#8761=0.552345] *[#8762=0.54848] *[#8763=0.546136] *[#8764=0.544411] *[#8766=0.542211] *[#8769=0.54079] *[#8771=0.537242] *[#8772=0.535563] *[#8773=0.531786] *[#8774=0.524577] *[#8780=0.522729] *[#8781=0.521881] *[#8782=0.521676] *[#8787=0.517635] *[#8788=0.515561] *[#8790=0.509203] *[#8791=0.507756] *[#8792=0.505181] *[#8795=0.504632] *[#8798=0.50246] + - param set #1 has cost=0.502460 + -- Parameters = 2.1025 -3.5805 -5.1503 1.1757 -12.9363 1.3563 1.0006 1.0195 0.9876 -0.0023 0.0006 0.0104 + - param set #2 has cost=0.574908 + -- Parameters = 2.1969 -3.8722 -5.4413 1.5782 -14.2292 2.4581 0.9866 1.0135 1.0060 0.0068 0.0077 -0.0262 + - param set #3 has cost=0.884579 + -- Parameters = 4.9593 -4.6249 -4.1531 -2.9050 -20.6671 16.5078 1.0218 1.0089 1.0110 0.0045 0.0036 0.0042 + - param set #4 has cost=0.868910 + -- Parameters = 2.1577 -1.9228 1.7518 0.4482 -3.3189 -0.2892 0.9938 1.0015 1.0183 -0.0011 -0.0003 -0.0011 + - param set #5 has cost=0.899854 + -- Parameters = 2.2934 -1.2314 -6.2724 -4.7665 -21.6105 -14.0072 0.9989 0.9977 0.9973 -0.0016 -0.0001 -0.0013 + - param set #6 has cost=0.921129 + -- Parameters = 32.5424 -23.4122 -38.0418 37.9515 18.1239 42.8043 0.9979 0.9979 0.9948 0.0009 0.0002 -0.0011 + - param set #7 has cost=0.935307 + -- Parameters = 1.6333 10.6550 9.1980 0.1494 22.6754 19.2517 0.9990 1.0018 1.0019 0.0001 0.0011 0.0000 + - param set #8 has cost=0.924718 + -- Parameters = 1.6688 -6.4076 5.1046 -5.0822 21.3474 -19.3600 1.0025 1.0003 0.9986 0.0004 -0.0008 -0.0008 + - param set #9 has cost=0.931708 + -- Parameters = 22.5467 -2.7110 18.7235 -26.0803 34.6435 31.1326 0.9982 0.9979 0.9986 -0.0014 -0.0005 -0.0009 + - param set #10 has cost=0.943828 + -- Parameters = 1.9962 11.3434 6.4375 -4.3683 23.6463 -18.5565 1.0000 1.0000 1.0000 0.0000 0.0000 0.0000 + - param set #11 has cost=0.949015 + -- Parameters = 20.8843 -13.2472 1.0892 -31.2173 -21.8185 -20.8753 0.9992 1.0028 1.0004 0.0015 0.0014 -0.0014 + - param set #12 has cost=0.646514 + -- Parameters = 2.8325 -4.3956 -4.8079 0.0644 -9.5364 2.9162 0.9935 1.0007 0.9955 0.0102 0.0281 0.0065 + - sorting parameter sets by cost + -- scanning for distances from #1 + --- dist(#2,#1) = 0.165 + --- dist(#3,#1) = 0.124 + --- dist(#4,#1) = 0.107 + --- dist(#5,#1) = 0.168 + --- dist(#6,#1) = 0.171 + --- dist(#7,#1) = 0.461 + --- dist(#8,#1) = 0.381 + --- dist(#9,#1) = 0.529 + --- dist(#10,#1) = 0.396 + --- dist(#11,#1) = 0.406 + --- dist(#12,#1) = 0.36 ++ Start refinement #2 on 12 coarse parameter sets + * Enter alignment setup routine + - Smoothing base; radius=1.34 + - Smoothing source; radius=1.34 + !source mask fill: ubot=43 usiz=77 + - retaining old weight image + - using 222220 points from base image [use_all=0] + * Exit alignment setup routine + 199585 total points stored in 1176 'RHDD(6.6798)' bloks + - param set #1 has cost=0.560996 + -- Parameters = 2.2285 -3.9175 -5.1800 0.7464 -13.1062 1.4864 1.0205 1.0513 0.9831 -0.0025 -0.0041 0.0131 + - param set #2 has cost=0.604642 + -- Parameters = 2.2510 -3.5020 -5.3102 1.2585 -14.5661 1.8228 1.0362 1.0429 1.0043 0.0090 0.0004 -0.0242 + - param set #3 has cost=0.557918 + -- Parameters = 2.2200 -4.1599 -5.0689 1.0215 -12.8141 1.7166 1.0134 1.0669 0.9696 0.0167 0.0048 0.0239 + - param set #4 has cost=0.696195 + -- Parameters = 2.2028 -3.5672 -4.4287 -0.6834 -10.7694 -0.9251 0.9935 0.9992 0.9879 -0.0250 0.0332 0.0004 + - param set #5 has cost=0.736872 + -- Parameters = 4.1688 -3.0579 -5.6105 -2.3488 -15.1935 3.8181 1.0272 1.0052 1.0124 0.0201 0.0002 -0.0144 + - param set #6 has cost=0.669430 + -- Parameters = 1.4230 -2.8774 -5.6453 0.7112 -16.5770 -1.1432 0.9956 1.0479 0.9919 -0.0056 0.0271 -0.0054 + - param set #7 has cost=0.948243 + -- Parameters = 32.5745 -23.6715 -38.0159 37.8796 20.9486 42.6499 0.9976 0.9979 0.9947 0.0015 0.0000 -0.0011 + - param set #8 has cost=0.941151 + -- Parameters = 1.6267 -6.3270 5.1819 -4.8795 21.2342 -19.3623 1.0026 1.0004 0.9987 0.0007 -0.0013 0.0055 + - param set #9 has cost=0.955094 + -- Parameters = 22.5422 -2.7228 18.7140 -25.9200 34.6839 31.0776 1.0092 0.9982 0.9980 -0.0012 -0.0006 -0.0009 + - param set #10 has cost=0.931317 + -- Parameters = 2.2756 11.9175 8.7386 1.1998 16.9518 4.7808 0.9413 1.0087 1.0331 -0.0292 -0.0593 0.0315 + - param set #11 has cost=0.949278 + -- Parameters = 2.5660 11.3810 7.6991 1.5057 20.4405 -16.6285 0.9877 0.9970 0.9866 -0.0010 -0.0018 0.0133 + - param set #12 has cost=0.964850 + -- Parameters = 20.8424 -13.1850 1.1775 -31.1587 -21.8668 -20.7776 0.9992 1.0141 1.0002 0.0017 0.0019 -0.0015 + - sorting parameter sets by cost + -- scanning for distances from #1 + --- dist(#2,#1) = 0.0866 + --- dist(#3,#1) = 0.217 + --- dist(#4,#1) = 0.132 + --- dist(#5,#1) = 0.188 + --- dist(#6,#1) = 0.172 + --- dist(#7,#1) = 0.331 + --- dist(#8,#1) = 0.378 + --- dist(#9,#1) = 0.455 + --- dist(#10,#1) = 0.369 + --- dist(#11,#1) = 0.528 + --- dist(#12,#1) = 0.358 ++ Start refinement #3 on 12 coarse parameter sets + * Enter alignment setup routine + - Smoothing base; radius=1.05 + - Smoothing source; radius=1.05 + !source mask fill: ubot=43 usiz=77 + - retaining old weight image + - using 333330 points from base image [use_all=0] + * Exit alignment setup routine + 297819 total points stored in 1185 'RHDD(6.62616)' bloks + - param set #1 has cost=0.638249 + -- Parameters = 2.2848 -4.1954 -5.1489 0.8416 -12.9989 1.7058 1.0191 1.0759 0.9734 0.0114 0.0084 0.0249 + - param set #2 has cost=0.640910 + -- Parameters = 2.3280 -4.0751 -5.1610 0.7603 -13.1003 1.7336 1.0178 1.0656 0.9828 -0.0026 -0.0013 0.0155 + - param set #3 has cost=0.650391 + -- Parameters = 2.3306 -3.8059 -5.0671 0.9357 -14.8029 1.8059 1.0184 1.0761 0.9806 0.0108 0.0067 -0.0174 + - param set #4 has cost=0.660084 + -- Parameters = 2.3192 -3.7600 -5.2775 -0.1149 -14.7106 0.6788 1.0065 1.0726 0.9879 -0.0061 0.0278 -0.0045 + - param set #5 has cost=0.699587 + -- Parameters = 2.3148 -3.4699 -4.4023 -0.4120 -12.3500 0.8316 1.0155 1.0276 0.9537 -0.0111 0.0291 0.0118 + - param set #6 has cost=0.684876 + -- Parameters = 2.9748 -3.4109 -5.4953 -0.4187 -15.8127 2.3670 1.0479 1.0621 0.9989 0.0107 -0.0045 -0.0179 + - param set #7 has cost=0.947182 + -- Parameters = 2.2761 11.9169 8.7396 1.1999 16.9526 4.7785 0.9413 1.0162 1.0335 -0.0292 -0.0594 0.0315 + - param set #8 has cost=0.951830 + -- Parameters = 1.6659 -6.2340 5.4828 -4.8157 21.0642 -19.3565 0.9950 1.0010 0.9988 0.0004 -0.0016 0.0060 + - param set #9 has cost=0.951333 + -- Parameters = 32.5759 -23.7006 -38.0348 37.8579 20.8926 42.6493 0.9981 0.9977 0.9948 0.0059 -0.0000 -0.0012 + - param set #10 has cost=0.958701 + -- Parameters = 2.5587 11.6648 7.4328 1.0116 20.7364 -16.4871 0.9859 0.9969 0.9940 0.0002 -0.0020 0.0132 + - param set #11 has cost=0.962532 + -- Parameters = 22.7529 -2.6465 18.6307 -24.3052 34.6113 31.0896 1.0085 0.9981 0.9980 -0.0012 -0.0011 -0.0011 + - param set #12 has cost=0.972110 + -- Parameters = 20.8017 -13.1892 1.1675 -31.2481 -21.7911 -20.8959 0.9990 1.0219 0.9999 0.0017 0.0019 -0.0014 + - sorting parameter sets by cost + -- scanning for distances from #1 + --- dist(#2,#1) = 0.0633 + --- dist(#3,#1) = 0.19 + --- dist(#4,#1) = 0.132 + --- dist(#5,#1) = 0.192 + --- dist(#6,#1) = 0.131 + --- dist(#7,#1) = 0.333 + --- dist(#8,#1) = 0.455 + --- dist(#9,#1) = 0.378 + --- dist(#10,#1) = 0.375 + --- dist(#11,#1) = 0.529 + --- dist(#12,#1) = 0.357 + - Total coarse refinement net CPU time = 45.8 s; 2592 funcs ++ *** Fine pass begins *** + * Enter alignment setup routine + - Smoothing base; radius=1.00 + - Smoothing source; radius=1.00 + !source mask fill: ubot=43 usiz=77 + - retaining old weight image + - using 755712 points from base image [use_all=0] + * Exit alignment setup routine ++ Picking best parameter set out of 13 cases + 705086 total points stored in 1298 'RHDD(6.61918)' bloks + - cost(#1)=0.663055 * + -- Parameters = 2.2848 -4.1954 -5.1489 0.8416 -12.9989 1.7058 1.0191 1.0759 0.9734 0.0114 0.0084 0.0249 + - cost(#2)=0.663368 + -- Parameters = 2.3280 -4.0751 -5.1610 0.7603 -13.1003 1.7336 1.0178 1.0656 0.9828 -0.0026 -0.0013 0.0155 + - cost(#3)=0.673997 + -- Parameters = 2.3306 -3.8059 -5.0671 0.9357 -14.8029 1.8059 1.0184 1.0761 0.9806 0.0108 0.0067 -0.0174 + - cost(#4)=0.681957 + -- Parameters = 2.3192 -3.7600 -5.2775 -0.1149 -14.7106 0.6788 1.0065 1.0726 0.9879 -0.0061 0.0278 -0.0045 + - cost(#5)=0.701655 + -- Parameters = 2.9748 -3.4109 -5.4953 -0.4187 -15.8127 2.3670 1.0479 1.0621 0.9989 0.0107 -0.0045 -0.0179 + - cost(#6)=0.715429 + -- Parameters = 2.3148 -3.4699 -4.4023 -0.4120 -12.3500 0.8316 1.0155 1.0276 0.9537 -0.0111 0.0291 0.0118 + - cost(#7)=0.951052 + -- Parameters = 2.2761 11.9169 8.7396 1.1999 16.9526 4.7785 0.9413 1.0162 1.0335 -0.0292 -0.0594 0.0315 + - cost(#8)=0.961147 + -- Parameters = 32.5759 -23.7006 -38.0348 37.8579 20.8926 42.6493 0.9981 0.9977 0.9948 0.0059 -0.0000 -0.0012 + - cost(#9)=0.957512 + -- Parameters = 1.6659 -6.2340 5.4828 -4.8157 21.0642 -19.3565 0.9950 1.0010 0.9988 0.0004 -0.0016 0.0060 + - cost(#10)=0.962119 + -- Parameters = 2.5587 11.6648 7.4328 1.0116 20.7364 -16.4871 0.9859 0.9969 0.9940 0.0002 -0.0020 0.0132 + - cost(#11)=0.966499 + -- Parameters = 22.7529 -2.6465 18.6307 -24.3052 34.6113 31.0896 1.0085 0.9981 0.9980 -0.0012 -0.0011 -0.0011 + - cost(#12)=0.977529 + -- Parameters = 20.8017 -13.1892 1.1675 -31.2481 -21.7911 -20.8959 0.9990 1.0219 0.9999 0.0017 0.0019 -0.0014 + - cost(#13)=0.955775 + -- Parameters = 2.2364 5.0650 1.8932 0.0000 0.0000 0.0000 1.0000 1.0000 1.0000 0.0000 0.0000 0.0000 + -num_rtb 99 ==> refine all 13 cases + - cost(#1)=0.661808 * + -- Parameters = 2.2702 -4.2762 -5.1751 0.8509 -12.9492 1.7015 1.0195 1.0762 0.9740 0.0079 0.0079 0.0245 + - cost(#2)=0.661729 * + -- Parameters = 2.2874 -4.1028 -5.2074 0.8283 -13.1962 1.7246 1.0196 1.0691 0.9806 -0.0022 -0.0016 0.0157 + - cost(#3)=0.670704 + -- Parameters = 2.3000 -3.8438 -5.1589 0.9133 -14.8324 1.7123 1.0194 1.0766 0.9798 0.0109 0.0067 -0.0121 + - cost(#4)=0.670503 + -- Parameters = 2.3058 -3.8315 -5.1517 0.2526 -14.4069 0.9436 1.0139 1.0756 0.9762 -0.0063 0.0143 0.0000 + - cost(#5)=0.673938 + -- Parameters = 2.5760 -3.7245 -5.4334 0.1718 -14.7451 1.9002 1.0196 1.0669 0.9961 -0.0102 -0.0113 -0.0093 + - cost(#6)=0.669912 + -- Parameters = 2.2552 -4.1985 -5.1129 0.4945 -12.8107 1.0423 1.0048 1.0694 0.9782 -0.0011 0.0163 0.0178 + - cost(#7)=0.943982 + -- Parameters = 2.3952 9.0557 8.4875 1.5720 15.8538 2.2684 0.9451 1.0150 1.0308 -0.0281 -0.0623 0.0307 + - cost(#8)=0.956971 + -- Parameters = 32.8721 -23.8382 -37.9468 37.7257 19.0501 42.6269 0.9945 0.9993 0.9956 0.0058 -0.0003 -0.0016 + - cost(#9)=0.950813 + -- Parameters = 1.6136 -5.4327 5.3971 -1.1243 20.0081 -19.5996 0.9823 0.9859 0.9907 -0.0305 0.0047 0.0021 + - cost(#10)=0.960448 + -- Parameters = 2.6545 10.5714 7.2578 0.3854 21.0938 -16.1078 0.9828 1.0115 1.0047 -0.0002 -0.0066 0.0123 + - cost(#11)=0.965829 + -- Parameters = 22.7066 -2.6628 18.5450 -24.2576 34.5536 31.1357 1.0084 0.9984 0.9987 -0.0016 -0.0006 0.0029 + - cost(#12)=0.976635 + -- Parameters = 20.7675 -13.2476 2.5579 -31.3234 -21.7210 -20.7877 0.9988 1.0218 0.9997 0.0018 0.0018 -0.0017 + - cost(#13)=0.917756 + -- Parameters = 2.5073 -2.1012 1.6075 -0.3559 0.0739 0.5795 1.0027 0.9985 1.0039 0.0004 0.0009 -0.0012 + - case #2 is now the best + - Initial cost = 0.661729 + - Initial fine Parameters = 2.2874 -4.1028 -5.2074 0.8283 -13.1962 1.7246 1.0196 1.0691 0.9806 -0.0022 -0.0016 0.0157 + - Finalish cost = 0.661702 ; 82 funcs + - Final cost = 0.661554 ; 125 funcs + Final fine fit Parameters: x-shift= 2.2899 y-shift=-4.1139 z-shift=-5.2016 z-angle= 0.8108 x-angle=-13.1969 y-angle= 1.7822 x-scale= 1.0193 y-scale= 1.0693 z-scale= 0.9799 y/x-shear=-0.0046 z/x-shear=-0.0040 z/y-shear= 0.0158 + - Fine net CPU time = 57.3 s ++ Computing output image ++ image warp: parameters = 2.2899 -4.1139 -5.2016 0.8108 -13.1969 1.7822 1.0193 1.0693 0.9799 -0.0046 -0.0040 0.0158 ++ Wrote -1Dmatrix_save ./D99_template_al2std_mat.aff12.1D ++ 3dAllineate: total CPU time = 158.8 sec Elapsed = 51.5 ++ ########################################################### ++ ### Please check results visually for alignment quality ### ++ ########################################################### #++ Applying alignment for dset2 to dset1 #++ Inverting dset1 to dset2 matrix #Script is running (command trimmed): cat_matvec -ONELINE ./D99_template_al2std_mat.aff12.1D -I > ./macaque1_shft_al2std_mat.aff12.1D #++ Applying transformation of dset2 to dset1 #Script is running (command trimmed): 3dAllineate -base /Users/glend/macaquetest/macaqueatlas_1.2b/D99_template.nii.gz -1Dmatrix_apply ./macaque1_shft_al2std_mat.aff12.1D -prefix ./macaque1_shft_al2std -input ./macaque1_shft+orig -master BASE -mast_dxyz 1.000000 -weight_frac 1.0 -maxrot 6 -maxshf 10 -VERB -warp aff -source_automask+4 -twobest 11 -twopass -VERB -maxrot 45 -maxshf 40 -fineblur 1 -source_automask+2 ++ 3dAllineate: AFNI version=AFNI_16.2.12 (Aug 23 2016) [64-bit] ++ Authored by: Zhark the Registrator ++ Source dataset: ./macaque1_shft+orig.HEAD ++ Base dataset: /Users/glend/macaquetest/macaqueatlas_1.2b/D99_template.nii.gz ++ Loading datasets ++ NOTE: base and source coordinate systems have different handedness + Orientations: base=Right handed (LPI); source=Left handed (LAI) + Range param#4 [z-angle] = -6.000000 .. 6.000000 + Range param#5 [x-angle] = -6.000000 .. 6.000000 + Range param#6 [y-angle] = -6.000000 .. 6.000000 + Range param#1 [x-shift] = -10.000000 .. 10.000000 + Range param#2 [y-shift] = -10.000000 .. 10.000000 + Range param#3 [z-shift] = -10.000000 .. 10.000000 + Range param#4 [z-angle] = -45.000000 .. 45.000000 + Range param#5 [x-angle] = -45.000000 .. 45.000000 + Range param#6 [y-angle] = -45.000000 .. 45.000000 + Range param#1 [x-shift] = -40.000000 .. 40.000000 + Range param#2 [y-shift] = -40.000000 .. 40.000000 + Range param#3 [z-shift] = -40.000000 .. 40.000000 ++ changing output grid spacing to 1.0000 mm ++ OpenMP thread count = 8 ++ ========== Applying transformation to 1 sub-bricks ========== + base mask has 7006921 [out of 23379125] voxels ++ ========== sub-brick #0 ========== [total CPU to here=4.7 s] + * Enter alignment setup routine + - copying base image + - copying source image + - no weight image + - using 11 points from base image [use_all=0] + * Exit alignment setup routine ++ using -1Dmatrix_apply ++ Computing output image ++ image warp: parameters = 0.9806 -0.0133 -0.0284 17.7384 -0.0120 -0.9067 0.2333 84.9064 0.0268 0.2291 0.9931 2.7176 ++ 3dAllineate: total CPU time = 4.9 sec Elapsed = 5.2 ++ ########################################################### #++ Creating final output: dset2 data aligned to dset1 # copy is not necessary #++ Saving history #Script is running (command trimmed): 3dNotes -h "align_epi_anat.py -dset2 macaque1_shft+orig -dset1 \ ../../D99_template.nii.gz -overwrite -dset2to1 -giant_move -suffix \ _al2std -dset1_strip None -dset2_strip None" \ ./macaque1_shft_al2std+orig Error: Cannot open dataset #++ Removing all the temporary files #Script is running: \rm -f ./__tt_macaque1_shft* #Script is running: \rm -f ./__tt_D99_template* # Finished alignment successfully 3dAllineate -1Dmatrix_apply macaque1_shft_al2std_mat.aff12.1D -prefix macaque1_shft_aff -base ../../D99_template.nii.gz -master BASE -source macaque1_shft+orig -overwrite ++ 3dAllineate: AFNI version=AFNI_16.2.12 (Aug 23 2016) [64-bit] ++ Authored by: Zhark the Registrator ++ Source dataset: ./macaque1_shft+orig.HEAD ++ Base dataset: ../../D99_template.nii.gz ++ Loading datasets ++ NOTE: base and source coordinate systems have different handedness + Orientations: base=Right handed (LPI); source=Left handed (LAI) ++ OpenMP thread count = 8 ++ ========== Applying transformation to 1 sub-bricks ========== ++ ========== sub-brick #0 ========== [total CPU to here=4.3 s] ++ 3dAllineate: total CPU time = 8.3 sec Elapsed = 7.4 ++ ########################################################### rm -rf awpy_macaque1_shft auto_warp.py -base ../../D99_template.nii.gz -affine_input_xmat ID -qworkhard 0 2 -input macaque1_shft_aff+tlrc -overwrite -output_dir awpy_macaque1_shft #++ auto_warp.py version: 0.03 -- clearing AFNI_COMPRESSOR ... # Output directory /Users/glend/macaquetest/macaqueatlas_1.2b/AFNI_scripts/example_macaque/awpy_macaque1_shft/ #Script is running (command trimmed): mkdir ./awpy_macaque1_shft/ cd /Users/glend/macaquetest/macaqueatlas_1.2b/AFNI_scripts/example_macaque/awpy_macaque1_shft/ #Script is running (command trimmed): 3dcopy /Users/glend/macaquetest/macaqueatlas_1.2b/AFNI_scripts/example_macaque/macaque1_shft_aff+tlrc ./anat.nii ++ 3dcopy: AFNI version=AFNI_16.2.12 (Aug 23 2016) [64-bit] #Script is running (command trimmed): 3dUnifize -GM -input ./anat.nii -prefix ./anat.un.nii ++ 3dUnifize: AFNI version=AFNI_16.2.12 (Aug 23 2016) [64-bit] + Pre-processing: ADV.....................................UWG ++ Output dataset ./anat.un.nii ++ ===== CPU time = 307.4 sec Elapsed = 58.8 #Script is running (command trimmed): 3dcopy /Users/glend/macaquetest/macaqueatlas_1.2b/D99_template.nii.gz ./base.nii ++ 3dcopy: AFNI version=AFNI_16.2.12 (Aug 23 2016) [64-bit] #Script is running (command trimmed): 3dAttribute DELTA ./anat.un.nii #Script is running (command trimmed): 3dAttribute DELTA ./base.nii 0.250000 0.250000 #Script is running (command trimmed): 3dinfo -same_grid ./anat.un.nii ./base.nii #++ Aligning /Users/glend/macaquetest/macaqueatlas_1.2b/AFNI_scripts/example_macaque/awpy_macaque1_shft/base.nii data to /Users/glend/macaquetest/macaqueatlas_1.2b/AFNI_scripts/example_macaque/awpy_macaque1_shft/anat.un.nii data #Script is running (command trimmed): 3dQwarp -prefix ./anat.un.qw.nii -blur -3 -3 -workhard:0:2 -base ./base.nii -source ./anat.un.nii ++ OpenMP thread count = 8 ++ 3dQwarp: AFNI version=AFNI_16.2.12 (Aug 23 2016) [64-bit] ++ Authored by: Zhark the (Hermite) Cubically Warped ++ Dataset zero-pad: xbot=18 xtop=17 ybot=28 ytop=19 zbot=15 ztop=3 voxels ++ Weightizing the base image ++ +++++++++++ Begin warp optimization: base=./base.nii source=./anat.un.nii ++ AFNI warpomatic: 310 x 394 x 263 volume ; autobbox = 28..281 35..357 24..239 [clock= 17s 732ms] lev=0 0..309 0..393 0..262: [first cost=-0.67149] ... done [cost:-0.67149==>-0.76364] lev=1 patch=233x297x197 [clock= 18m 35s 153ms]........:[cost=-0.78254]:........ done [cost:-0.76364==>-0.78624 ; 16 patches optimized, 0 skipped] lev=2 patch=175x223x149 [clock= 33m 50s 458ms]....................:[cost=-0.86383]:.................... done [cost:-0.78624==>-0.87906 ; 40 patches optimized, 14 skipped] lev=3 patch=131x167x111 [clock= 52m 47s 512ms]............... done [cost:-0.87906==>-0.93218 ; 38 patches optimized, 26 skipped] lev=4 patch=99x125x83 [clock= 1h 2m 0s 891ms]....... done [cost:-0.93218==>-0.98055 ; 69 patches optimized, 56 skipped] lev=5 patch=73x93x63 [clock= 1h 9m 25s 867ms]................... done [cost:-0.98055==>-1.03876 ; 181 patches optimized, 162 skipped] lev=6 patch=55x71x47 [clock= 1h 17m 23s 973ms].......