Open In Google Colab

AFNI Preprocessing and GLM#

Author: Monika Doerig

Citation:

Andy’s Brain Book:

Data from OpenNeuro: Flanker Dataset

  • Kelly AMC and Uddin LQ and Biswal BB and Castellanos FX and Milham MP (2018). Flanker task (event-related). OpenNeuro Dataset ds000102. [Dataset] doi: null

  • Kelly AM, Uddin LQ, Biswal BB, Castellanos FX, Milham MP. Competition between functional brain networks mediates behavioral variability. Neuroimage. 2008 Jan 1;39(1):527-37. doi: 10.1016/j.neuroimage.2007.08.008. Epub 2007 Aug 23. PMID: 17919929.

  • Mennes, M., Kelly, C., Zuo, X.N., Di Martino, A., Biswal, B.B., Castellanos, F.X., Milham, M.P. (2010). Inter-individual differences in resting-state functional connectivity predict task-induced BOLD activity. Neuroimage, 50(4):1690-701. doi: 10.1016/j.neuroimage.2010.01.002. Epub 2010 Jan 15. Erratum in: Neuroimage. 2011 Mar 1;55(1):434

  • Mennes, M., Zuo, X.N., Kelly, C., Di Martino, A., Zang, Y.F., Biswal, B., Castellanos, F.X., Milham, M.P. (2011). Linking inter-individual differences in neural activation and behavior to intrinsic brain dynamics. Neuroimage, 54(4):2950-9. doi: 10.1016/j.neuroimage.2010.10.046

Setup Neurodesk#

%%capture
import os
import sys
IN_COLAB = 'google.colab' in sys.modules

if IN_COLAB:
  os.environ["LD_PRELOAD"] = "";
  os.environ["APPTAINER_BINDPATH"] = "/content,/tmp,/cvmfs"
  os.environ["MPLCONFIGDIR"] = "/content/matplotlib-mpldir"
  os.environ["LMOD_CMD"] = "/usr/share/lmod/lmod/libexec/lmod"

  !curl -J -O https://raw.githubusercontent.com/NeuroDesk/neurocommand/main/googlecolab_setup.sh
  !chmod +x googlecolab_setup.sh
  !./googlecolab_setup.sh

  os.environ["MODULEPATH"] = ':'.join(map(str, list(map(lambda x: os.path.join(os.path.abspath('/cvmfs/neurodesk.ardc.edu.au/neurodesk-modules/'), x),os.listdir('/cvmfs/neurodesk.ardc.edu.au/neurodesk-modules/')))))
# Output CPU information:
!cat /proc/cpuinfo | grep 'vendor' | uniq
!cat /proc/cpuinfo | grep 'model name' | uniq
vendor_id	: GenuineIntel
model name	: Intel(R) Xeon(R) Gold 6126 CPU @ 2.60GHz

Load packages#

import lmod
await lmod.load('afni/21.2.00')
await lmod.list()
['afni/21.2.00']

Install tcsh#

%%capture
!sudo apt update; sudo apt install tcsh

Check the installation:

%%script tcsh
set var = "hello from tcsh"
echo $var
hello from tcsh

Import Python Modules#

import os
import nibabel as nib
import numpy as np
import matplotlib.pyplot as plt
import matplotlib
from IPython.display import display, Image
from nilearn import plotting
from scipy.stats import t

Data download#

PATTERN = "sub-08"
!datalad install https://github.com/OpenNeuroDatasets/ds000102.git
!cd ds000102 && datalad get $PATTERN
Cloning:   0%|                             | 0.00/2.00 [00:00<?, ? candidates/s]
Enumerating: 0.00 Objects [00:00, ? Objects/s]
                                              
Counting:   0%|                               | 0.00/27.0 [00:00<?, ? Objects/s]
                                                                                
Compressing:   0%|                            | 0.00/23.0 [00:00<?, ? Objects/s]
                                                                                
Receiving:   0%|                             | 0.00/2.15k [00:00<?, ? Objects/s]
                                                                                
Resolving:   0%|                                | 0.00/537 [00:00<?, ? Deltas/s]
[INFO   ] scanning for unlocked files (this may take some time)                 
[INFO   ] Remote origin not usable by git-annex; setting annex-ignore 
[INFO   ] access to 1 dataset sibling s3-PRIVATE not auto-enabled, enable with:
| 		datalad siblings -d "/home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/ds000102" enable -s s3-PRIVATE 
install(ok): /home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/ds000102 (dataset)
Total:   0%|                                   | 0.00/67.8M [00:00<?, ? Bytes/s]
Get sub-08/a .. 8_T1w.nii.gz:   0%|            | 0.00/10.6M [00:00<?, ? Bytes/s]
Get sub-08/a .. 8_T1w.nii.gz:   1%|     | 139k/10.6M [00:00<00:21, 481k Bytes/s]
Get sub-08/a .. 8_T1w.nii.gz:   4%|▏   | 416k/10.6M [00:00<00:08, 1.24M Bytes/s]
Get sub-08/a .. 8_T1w.nii.gz:   8%|▎   | 886k/10.6M [00:00<00:04, 2.35M Bytes/s]
Get sub-08/a .. 8_T1w.nii.gz:  14%|▍  | 1.48M/10.6M [00:00<00:02, 3.47M Bytes/s]
Get sub-08/a .. 8_T1w.nii.gz:  26%|▊  | 2.77M/10.6M [00:00<00:01, 6.38M Bytes/s]
Get sub-08/a .. 8_T1w.nii.gz:  39%|█▏ | 4.08M/10.6M [00:00<00:00, 8.44M Bytes/s]
Get sub-08/a .. 8_T1w.nii.gz:  63%|█▉ | 6.65M/10.6M [00:00<00:00, 13.7M Bytes/s]
Get sub-08/a .. 8_T1w.nii.gz:  80%|██▍| 8.42M/10.6M [00:00<00:00, 14.9M Bytes/s]
Total:  16%|████                      | 10.6M/67.8M [00:01<00:09, 5.99M Bytes/s]
Get sub-08/f .. _bold.nii.gz:   0%|            | 0.00/28.6M [00:00<?, ? Bytes/s]
Get sub-08/f .. _bold.nii.gz:  17%|▌  | 4.86M/28.6M [00:00<00:00, 24.3M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  32%|▉  | 9.24M/28.6M [00:00<00:00, 22.8M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  48%|█▍ | 13.8M/28.6M [00:00<00:00, 22.9M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  60%|█▊ | 17.1M/28.6M [00:00<00:00, 22.4M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  71%|██▏| 20.4M/28.6M [00:00<00:00, 22.4M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  80%|██▍| 23.0M/28.6M [00:01<00:00, 23.1M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  95%|██▊| 27.3M/28.6M [00:01<00:00, 22.6M Bytes/s]
Total:  58%|███████████████           | 39.2M/67.8M [00:03<00:02, 11.7M Bytes/s]
Get sub-08/f .. _bold.nii.gz:   0%|            | 0.00/28.6M [00:00<?, ? Bytes/s]
Get sub-08/f .. _bold.nii.gz:   6%|▏  | 1.71M/28.6M [00:00<00:01, 14.6M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  15%|▍  | 4.16M/28.6M [00:00<00:01, 15.0M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  24%|▋  | 6.87M/28.6M [00:00<00:01, 17.0M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  31%|▉  | 9.01M/28.6M [00:00<00:01, 18.4M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  39%|█▏ | 11.3M/28.6M [00:00<00:00, 19.7M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  48%|█▍ | 13.7M/28.6M [00:00<00:00, 21.0M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  56%|█▋ | 16.1M/28.6M [00:00<00:00, 21.8M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  71%|██▏| 20.4M/28.6M [00:01<00:00, 21.8M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  80%|██▍| 22.8M/28.6M [00:01<00:00, 22.3M Bytes/s]
Get sub-08/f .. _bold.nii.gz:  91%|██▋| 26.0M/28.6M [00:01<00:00, 21.5M Bytes/s]
get(ok): sub-08/anat/sub-08_T1w.nii.gz (file) [from s3-PUBLIC...]
get(ok): sub-08/func/sub-08_task-flanker_run-1_bold.nii.gz (file) [from s3-PUBLIC...]
get(ok): sub-08/func/sub-08_task-flanker_run-2_bold.nii.gz (file) [from s3-PUBLIC...]
get(ok): sub-08 (directory)
action summary:
  get (ok: 4)

The data is structured in BIDS format:

!tree -L 4 ds000102
ds000102
├── CHANGES
├── README
├── T1w.json
├── dataset_description.json
├── derivatives
│   └── mriqc
│       ├── aMRIQC.csv -> ../../.git/annex/objects/Q4/jv/MD5E-s14180--3addf0456b803b7c5ec5147481ecdd62.csv/MD5E-s14180--3addf0456b803b7c5ec5147481ecdd62.csv
│       ├── anatomical_group.pdf -> ../../.git/annex/objects/6m/q9/MD5E-s98927--d11151f65ae061833e7fd4373adfec3f.pdf/MD5E-s98927--d11151f65ae061833e7fd4373adfec3f.pdf
│       ├── anatomical_sub-01.pdf -> ../../.git/annex/objects/K3/7x/MD5E-s2747349--5d40f2a54fb4194ac4a79f0295ff51c0.pdf/MD5E-s2747349--5d40f2a54fb4194ac4a79f0295ff51c0.pdf
│       ├── anatomical_sub-02.pdf -> ../../.git/annex/objects/Kx/Kv/MD5E-s2803965--56f6b768362bd9b7f0ef501b8cb6dde6.pdf/MD5E-s2803965--56f6b768362bd9b7f0ef501b8cb6dde6.pdf
│       ├── anatomical_sub-03.pdf -> ../../.git/annex/objects/kx/g5/MD5E-s2809843--e90d7a4859ed4be986b55e23f93ca89d.pdf/MD5E-s2809843--e90d7a4859ed4be986b55e23f93ca89d.pdf
│       ├── anatomical_sub-04.pdf -> ../../.git/annex/objects/JK/Zm/MD5E-s2846770--4869146771178dbb01ac79b95b35a8a1.pdf/MD5E-s2846770--4869146771178dbb01ac79b95b35a8a1.pdf
│       ├── anatomical_sub-05.pdf -> ../../.git/annex/objects/zm/FG/MD5E-s2824086--fda634d34556c83005a5eb2ca8c498dd.pdf/MD5E-s2824086--fda634d34556c83005a5eb2ca8c498dd.pdf
│       ├── anatomical_sub-06.pdf -> ../../.git/annex/objects/92/q0/MD5E-s2798058--fdddf0aff1eca8f61ed7c8b04ada9735.pdf/MD5E-s2798058--fdddf0aff1eca8f61ed7c8b04ada9735.pdf
│       ├── anatomical_sub-07.pdf -> ../../.git/annex/objects/39/3K/MD5E-s2795270--29ce2e2352596df940e5f3fae45b5a38.pdf/MD5E-s2795270--29ce2e2352596df940e5f3fae45b5a38.pdf
│       ├── anatomical_sub-08.pdf -> ../../.git/annex/objects/Fx/F4/MD5E-s2727492--b55dad8ffe22fc035110ecf4119d2960.pdf/MD5E-s2727492--b55dad8ffe22fc035110ecf4119d2960.pdf
│       ├── anatomical_sub-09.pdf -> ../../.git/annex/objects/4M/pz/MD5E-s2887144--28ea830af2a4d741147d18ea9c7fda84.pdf/MD5E-s2887144--28ea830af2a4d741147d18ea9c7fda84.pdf
│       ├── anatomical_sub-10.pdf -> ../../.git/annex/objects/0z/Vw/MD5E-s2874045--6542a57a9fc58f97f2a03c2384663c62.pdf/MD5E-s2874045--6542a57a9fc58f97f2a03c2384663c62.pdf
│       ├── anatomical_sub-11.pdf -> ../../.git/annex/objects/wm/76/MD5E-s2781221--1071b83e3c1b4532879521c37c3329da.pdf/MD5E-s2781221--1071b83e3c1b4532879521c37c3329da.pdf
│       ├── anatomical_sub-12.pdf -> ../../.git/annex/objects/GF/19/MD5E-s2817233--bfd24ca3274fa5efd654e2afd927f9ef.pdf/MD5E-s2817233--bfd24ca3274fa5efd654e2afd927f9ef.pdf
│       ├── anatomical_sub-13.pdf -> ../../.git/annex/objects/9Q/X2/MD5E-s2796088--ed299ab7e1662cb03aa01299eed2602b.pdf/MD5E-s2796088--ed299ab7e1662cb03aa01299eed2602b.pdf
│       ├── anatomical_sub-14.pdf -> ../../.git/annex/objects/Wg/55/MD5E-s2558074--cadc9bd81856dcd02677de84e7e6ca90.pdf/MD5E-s2558074--cadc9bd81856dcd02677de84e7e6ca90.pdf
│       ├── anatomical_sub-15.pdf -> ../../.git/annex/objects/43/Q3/MD5E-s2847293--0c678a4b309d055ad9ba4ba25b77351b.pdf/MD5E-s2847293--0c678a4b309d055ad9ba4ba25b77351b.pdf
│       ├── anatomical_sub-16.pdf -> ../../.git/annex/objects/xq/qj/MD5E-s2890454--87c62253c1711f30d53c41b3ac38dc66.pdf/MD5E-s2890454--87c62253c1711f30d53c41b3ac38dc66.pdf
│       ├── anatomical_sub-17.pdf -> ../../.git/annex/objects/zK/M1/MD5E-s2825765--0a91015e22836a3076641b963e1ccfc6.pdf/MD5E-s2825765--0a91015e22836a3076641b963e1ccfc6.pdf
│       ├── anatomical_sub-18.pdf -> ../../.git/annex/objects/w2/Vk/MD5E-s2821624--1d9a3f0b21ce1f9a3b490d44d36f1f11.pdf/MD5E-s2821624--1d9a3f0b21ce1f9a3b490d44d36f1f11.pdf
│       ├── anatomical_sub-19.pdf -> ../../.git/annex/objects/J2/Jq/MD5E-s2453814--533411f3353cb3fa0264485e81f3fcf6.pdf/MD5E-s2453814--533411f3353cb3fa0264485e81f3fcf6.pdf
│       ├── anatomical_sub-20.pdf -> ../../.git/annex/objects/MF/9X/MD5E-s2881144--176c560778c55db87e8468b3246d373c.pdf/MD5E-s2881144--176c560778c55db87e8468b3246d373c.pdf
│       ├── anatomical_sub-21.pdf -> ../../.git/annex/objects/XQ/p1/MD5E-s2330589--b7546dfe5fb43a974cd23111b860c493.pdf/MD5E-s2330589--b7546dfe5fb43a974cd23111b860c493.pdf
│       ├── anatomical_sub-22.pdf -> ../../.git/annex/objects/Fx/k8/MD5E-s2505165--55f0661ad209b742c517cc5b5469436a.pdf/MD5E-s2505165--55f0661ad209b742c517cc5b5469436a.pdf
│       ├── anatomical_sub-23.pdf -> ../../.git/annex/objects/qj/8K/MD5E-s2784018--7e8697a7d4601547a899a27af132166d.pdf/MD5E-s2784018--7e8697a7d4601547a899a27af132166d.pdf
│       ├── anatomical_sub-24.pdf -> ../../.git/annex/objects/G8/Kw/MD5E-s2828817--e86be931adef2a7b0297d557d827d629.pdf/MD5E-s2828817--e86be931adef2a7b0297d557d827d629.pdf
│       ├── anatomical_sub-25.pdf -> ../../.git/annex/objects/XG/kg/MD5E-s2447908--3d392b9d27929dc4146d2b47be16e8dc.pdf/MD5E-s2447908--3d392b9d27929dc4146d2b47be16e8dc.pdf
│       ├── anatomical_sub-26.pdf -> ../../.git/annex/objects/8P/42/MD5E-s2850007--6d2f87a305b30d5704aaf4be9b8ff1e6.pdf/MD5E-s2850007--6d2f87a305b30d5704aaf4be9b8ff1e6.pdf
│       ├── fMRIQC.csv -> ../../.git/annex/objects/2Z/Ff/MD5E-s21038--cbe73db3db1beb0a1977583cff2a724b.csv/MD5E-s21038--cbe73db3db1beb0a1977583cff2a724b.csv
│       ├── functional_group.pdf -> ../../.git/annex/objects/Kq/xg/MD5E-s90712--7058c3db328fecb86303bc27a9ef0110.pdf/MD5E-s90712--7058c3db328fecb86303bc27a9ef0110.pdf
│       ├── functional_sub-01.pdf -> ../../.git/annex/objects/k2/vQ/MD5E-s1157925--e055f942b72b9aabad7a5e3d7b25b201.pdf/MD5E-s1157925--e055f942b72b9aabad7a5e3d7b25b201.pdf
│       ├── functional_sub-02.pdf -> ../../.git/annex/objects/X3/X6/MD5E-s1235840--cb32b7f8f1274af250b4f0fc15dacecb.pdf/MD5E-s1235840--cb32b7f8f1274af250b4f0fc15dacecb.pdf
│       ├── functional_sub-03.pdf -> ../../.git/annex/objects/Vp/0x/MD5E-s1228507--73ab1cc4cb27712892fcb10a0853ba7c.pdf/MD5E-s1228507--73ab1cc4cb27712892fcb10a0853ba7c.pdf
│       ├── functional_sub-04.pdf -> ../../.git/annex/objects/xk/jz/MD5E-s1252659--8ae6d1b02767c1ddb72dd7e6afefe696.pdf/MD5E-s1252659--8ae6d1b02767c1ddb72dd7e6afefe696.pdf
│       ├── functional_sub-05.pdf -> ../../.git/annex/objects/Zm/VJ/MD5E-s1258815--dd043691d548a501dd63d1aaf420e43c.pdf/MD5E-s1258815--dd043691d548a501dd63d1aaf420e43c.pdf
│       ├── functional_sub-06.pdf -> ../../.git/annex/objects/M5/gq/MD5E-s1247345--9c06bc69792b812ab8deffb01c6656c2.pdf/MD5E-s1247345--9c06bc69792b812ab8deffb01c6656c2.pdf
│       ├── functional_sub-07.pdf -> ../../.git/annex/objects/25/35/MD5E-s1229731--99cc64e99df0025ccb0341cd0dcf688b.pdf/MD5E-s1229731--99cc64e99df0025ccb0341cd0dcf688b.pdf
│       ├── functional_sub-08.pdf -> ../../.git/annex/objects/MX/vQ/MD5E-s1222308--e13c56f17109d3f142c9c4db60fea674.pdf/MD5E-s1222308--e13c56f17109d3f142c9c4db60fea674.pdf
│       ├── functional_sub-09.pdf -> ../../.git/annex/objects/90/0F/MD5E-s1265097--41a69211a0569413917ce3825eac95d6.pdf/MD5E-s1265097--41a69211a0569413917ce3825eac95d6.pdf
│       ├── functional_sub-10.pdf -> ../../.git/annex/objects/FZ/gq/MD5E-s1299358--12ccfc4a5f52b077b99481fe25aa8ef1.pdf/MD5E-s1299358--12ccfc4a5f52b077b99481fe25aa8ef1.pdf
│       ├── functional_sub-11.pdf -> ../../.git/annex/objects/MJ/mQ/MD5E-s1166014--3465ef6b18514d3cd361c0bffe2b73fc.pdf/MD5E-s1166014--3465ef6b18514d3cd361c0bffe2b73fc.pdf
│       ├── functional_sub-12.pdf -> ../../.git/annex/objects/xp/1f/MD5E-s1177325--6fe4937d5aa567fb5b3c3977362fc9af.pdf/MD5E-s1177325--6fe4937d5aa567fb5b3c3977362fc9af.pdf
│       ├── functional_sub-13.pdf -> ../../.git/annex/objects/4g/vW/MD5E-s1178873--96f341322d21e2bdeb709edc5b047df0.pdf/MD5E-s1178873--96f341322d21e2bdeb709edc5b047df0.pdf
│       ├── functional_sub-14.pdf -> ../../.git/annex/objects/5p/6X/MD5E-s1206987--729f64cf514c9103556c53ccb5430bc4.pdf/MD5E-s1206987--729f64cf514c9103556c53ccb5430bc4.pdf
│       ├── functional_sub-15.pdf -> ../../.git/annex/objects/m1/k9/MD5E-s1223617--9239a1c2d968ed18093b69d28fd9e654.pdf/MD5E-s1223617--9239a1c2d968ed18093b69d28fd9e654.pdf
│       ├── functional_sub-16.pdf -> ../../.git/annex/objects/jq/wP/MD5E-s1294856--5eb7ec97924a22c7e68fd95373694e7e.pdf/MD5E-s1294856--5eb7ec97924a22c7e68fd95373694e7e.pdf
│       ├── functional_sub-17.pdf -> ../../.git/annex/objects/0m/3Q/MD5E-s1238563--129db424a50b7889278024828c08c736.pdf/MD5E-s1238563--129db424a50b7889278024828c08c736.pdf
│       ├── functional_sub-18.pdf -> ../../.git/annex/objects/VF/Fm/MD5E-s1197868--3b23e8d53b11d98d49b1adf62ff559df.pdf/MD5E-s1197868--3b23e8d53b11d98d49b1adf62ff559df.pdf
│       ├── functional_sub-19.pdf -> ../../.git/annex/objects/Jj/m8/MD5E-s1164028--aea7dfa78e9be2e83a9b313f2ebdc4bd.pdf/MD5E-s1164028--aea7dfa78e9be2e83a9b313f2ebdc4bd.pdf
│       ├── functional_sub-20.pdf -> ../../.git/annex/objects/x1/ZQ/MD5E-s1292308--8869b1b640797a2be2aa03be69b89840.pdf/MD5E-s1292308--8869b1b640797a2be2aa03be69b89840.pdf
│       ├── functional_sub-21.pdf -> ../../.git/annex/objects/MG/zW/MD5E-s1216271--3d5c5ca0f8f4ba06b3289e197a40defd.pdf/MD5E-s1216271--3d5c5ca0f8f4ba06b3289e197a40defd.pdf
│       ├── functional_sub-22.pdf -> ../../.git/annex/objects/5m/pj/MD5E-s1142289--4f9e57d8bfe3d39881c43b959189d69f.pdf/MD5E-s1142289--4f9e57d8bfe3d39881c43b959189d69f.pdf
│       ├── functional_sub-23.pdf -> ../../.git/annex/objects/m7/Z2/MD5E-s1233046--7758914aecbf2b5d01cd0825952609be.pdf/MD5E-s1233046--7758914aecbf2b5d01cd0825952609be.pdf
│       ├── functional_sub-24.pdf -> ../../.git/annex/objects/mz/5m/MD5E-s1265224--c188bd88fc1c99308389f528ea4df71e.pdf/MD5E-s1265224--c188bd88fc1c99308389f528ea4df71e.pdf
│       ├── functional_sub-25.pdf -> ../../.git/annex/objects/Mk/G6/MD5E-s1260984--1b16abcbbf55ccc7763f1d704d76628f.pdf/MD5E-s1260984--1b16abcbbf55ccc7763f1d704d76628f.pdf
│       └── functional_sub-26.pdf -> ../../.git/annex/objects/1m/zq/MD5E-s1285726--6838f727d5c4b5593a7b5e0e6b20483a.pdf/MD5E-s1285726--6838f727d5c4b5593a7b5e0e6b20483a.pdf
├── participants.tsv
├── sub-01
│   ├── anat
│   │   └── sub-01_T1w.nii.gz -> ../../.git/annex/objects/Pf/6k/MD5E-s10581116--757e697a01eeea5c97a7d6fbc7153373.nii.gz/MD5E-s10581116--757e697a01eeea5c97a7d6fbc7153373.nii.gz
│   └── func
│       ├── sub-01_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/5m/w9/MD5E-s28061534--8e8c44ff53f9b5d46f2caae5916fa4ef.nii.gz/MD5E-s28061534--8e8c44ff53f9b5d46f2caae5916fa4ef.nii.gz
│       ├── sub-01_task-flanker_run-1_events.tsv
│       ├── sub-01_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/2F/58/MD5E-s28143286--f0bcf782c3688e2cf7149b4665949484.nii.gz/MD5E-s28143286--f0bcf782c3688e2cf7149b4665949484.nii.gz
│       └── sub-01_task-flanker_run-2_events.tsv
├── sub-02
│   ├── anat
│   │   └── sub-02_T1w.nii.gz -> ../../.git/annex/objects/3m/FF/MD5E-s10737123--cbd4181ee26559e8ec0a441fa2f834a7.nii.gz/MD5E-s10737123--cbd4181ee26559e8ec0a441fa2f834a7.nii.gz
│   └── func
│       ├── sub-02_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/8v/2j/MD5E-s29188378--80050f0deb13562c24f2fc23f8d095bd.nii.gz/MD5E-s29188378--80050f0deb13562c24f2fc23f8d095bd.nii.gz
│       ├── sub-02_task-flanker_run-1_events.tsv
│       ├── sub-02_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/fM/Kw/MD5E-s29193540--cc013f2d7d148b448edca8aada349d02.nii.gz/MD5E-s29193540--cc013f2d7d148b448edca8aada349d02.nii.gz
│       └── sub-02_task-flanker_run-2_events.tsv
├── sub-03
│   ├── anat
│   │   └── sub-03_T1w.nii.gz -> ../../.git/annex/objects/7W/9z/MD5E-s10707026--8f1858934cc7c7457e3a4a71cc2131fc.nii.gz/MD5E-s10707026--8f1858934cc7c7457e3a4a71cc2131fc.nii.gz
│   └── func
│       ├── sub-03_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/q6/kF/MD5E-s28755729--b19466702eee6b9385bd6e19e362f94c.nii.gz/MD5E-s28755729--b19466702eee6b9385bd6e19e362f94c.nii.gz
│       ├── sub-03_task-flanker_run-1_events.tsv
│       ├── sub-03_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/zV/K1/MD5E-s28782544--8d9700a435d08c90f0c1d534efdc8b69.nii.gz/MD5E-s28782544--8d9700a435d08c90f0c1d534efdc8b69.nii.gz
│       └── sub-03_task-flanker_run-2_events.tsv
├── sub-04
│   ├── anat
│   │   └── sub-04_T1w.nii.gz -> ../../.git/annex/objects/FW/14/MD5E-s10738444--2a9a2ba4ea7d2324c84bf5a2882f196c.nii.gz/MD5E-s10738444--2a9a2ba4ea7d2324c84bf5a2882f196c.nii.gz
│   └── func
│       ├── sub-04_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/9Z/0Q/MD5E-s29062799--27171406951ea275cb5857ea0dc32345.nii.gz/MD5E-s29062799--27171406951ea275cb5857ea0dc32345.nii.gz
│       ├── sub-04_task-flanker_run-1_events.tsv
│       ├── sub-04_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/FW/FZ/MD5E-s29071279--f89b61fe3ebab26df1374f2564bd95c2.nii.gz/MD5E-s29071279--f89b61fe3ebab26df1374f2564bd95c2.nii.gz
│       └── sub-04_task-flanker_run-2_events.tsv
├── sub-05
│   ├── anat
│   │   └── sub-05_T1w.nii.gz -> ../../.git/annex/objects/k2/Kj/MD5E-s10753867--c4b5788da5f4c627f0f5862da5f46c35.nii.gz/MD5E-s10753867--c4b5788da5f4c627f0f5862da5f46c35.nii.gz
│   └── func
│       ├── sub-05_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/VZ/z5/MD5E-s29667270--0ce9ac78b6aa9a77fc94c655a6ff5a06.nii.gz/MD5E-s29667270--0ce9ac78b6aa9a77fc94c655a6ff5a06.nii.gz
│       ├── sub-05_task-flanker_run-1_events.tsv
│       ├── sub-05_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/z7/MP/MD5E-s29660544--752750dabb21e2cf28e87d1d550a71b9.nii.gz/MD5E-s29660544--752750dabb21e2cf28e87d1d550a71b9.nii.gz
│       └── sub-05_task-flanker_run-2_events.tsv
├── sub-06
│   ├── anat
│   │   └── sub-06_T1w.nii.gz -> ../../.git/annex/objects/5w/G0/MD5E-s10620585--1132eab3830fe59b8a10b6582bb49004.nii.gz/MD5E-s10620585--1132eab3830fe59b8a10b6582bb49004.nii.gz
│   └── func
│       ├── sub-06_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/3x/qj/MD5E-s29386982--e671c0c647ce7d0d4596e35b702ee970.nii.gz/MD5E-s29386982--e671c0c647ce7d0d4596e35b702ee970.nii.gz
│       ├── sub-06_task-flanker_run-1_events.tsv
│       ├── sub-06_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/9j/6P/MD5E-s29379265--e513a2746d2b5c603f96044cf48c557c.nii.gz/MD5E-s29379265--e513a2746d2b5c603f96044cf48c557c.nii.gz
│       └── sub-06_task-flanker_run-2_events.tsv
├── sub-07
│   ├── anat
│   │   └── sub-07_T1w.nii.gz -> ../../.git/annex/objects/08/fF/MD5E-s10718092--38481fbc489dfb1ec4b174b57591a074.nii.gz/MD5E-s10718092--38481fbc489dfb1ec4b174b57591a074.nii.gz
│   └── func
│       ├── sub-07_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/z1/7W/MD5E-s28946009--5baf7a314874b280543fc0f91f2731af.nii.gz/MD5E-s28946009--5baf7a314874b280543fc0f91f2731af.nii.gz
│       ├── sub-07_task-flanker_run-1_events.tsv
│       ├── sub-07_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/Jf/W7/MD5E-s28960603--682e13963bfc49cc6ae05e9ba5c62619.nii.gz/MD5E-s28960603--682e13963bfc49cc6ae05e9ba5c62619.nii.gz
│       └── sub-07_task-flanker_run-2_events.tsv
├── sub-08
│   ├── anat
│   │   └── sub-08_T1w.nii.gz -> ../../.git/annex/objects/mw/MM/MD5E-s10561256--b94dddd8dc1c146aa8cd97f8d9994146.nii.gz/MD5E-s10561256--b94dddd8dc1c146aa8cd97f8d9994146.nii.gz
│   └── func
│       ├── sub-08_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/zX/v9/MD5E-s28641609--47314e6d1a14b8545686110b5b67f8b8.nii.gz/MD5E-s28641609--47314e6d1a14b8545686110b5b67f8b8.nii.gz
│       ├── sub-08_task-flanker_run-1_events.tsv
│       ├── sub-08_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/WZ/F0/MD5E-s28636310--4535bf26281e1c5556ad0d3468e7fe4e.nii.gz/MD5E-s28636310--4535bf26281e1c5556ad0d3468e7fe4e.nii.gz
│       └── sub-08_task-flanker_run-2_events.tsv
├── sub-09
│   ├── anat
│   │   └── sub-09_T1w.nii.gz -> ../../.git/annex/objects/QJ/ZZ/MD5E-s10775967--e6a18e64bc0a6b17254a9564cf9b8f82.nii.gz/MD5E-s10775967--e6a18e64bc0a6b17254a9564cf9b8f82.nii.gz
│   └── func
│       ├── sub-09_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/k9/1X/MD5E-s29200533--59e86a903e0ab3d1d320c794ba1f0777.nii.gz/MD5E-s29200533--59e86a903e0ab3d1d320c794ba1f0777.nii.gz
│       ├── sub-09_task-flanker_run-1_events.tsv
│       ├── sub-09_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/W3/94/MD5E-s29223017--7f3fb9e260d3bd28e29b0b586ce4c344.nii.gz/MD5E-s29223017--7f3fb9e260d3bd28e29b0b586ce4c344.nii.gz
│       └── sub-09_task-flanker_run-2_events.tsv
├── sub-10
│   ├── anat
│   │   └── sub-10_T1w.nii.gz -> ../../.git/annex/objects/5F/3f/MD5E-s10750712--bde2309077bffe22cb65e42ebdce5bfa.nii.gz/MD5E-s10750712--bde2309077bffe22cb65e42ebdce5bfa.nii.gz
│   └── func
│       ├── sub-10_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/3p/qp/MD5E-s29732696--339715d5cec387f4d44dfe94f304a429.nii.gz/MD5E-s29732696--339715d5cec387f4d44dfe94f304a429.nii.gz
│       ├── sub-10_task-flanker_run-1_events.tsv
│       ├── sub-10_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/11/Zx/MD5E-s29724034--16f2bf452524a315182f188becc1866d.nii.gz/MD5E-s29724034--16f2bf452524a315182f188becc1866d.nii.gz
│       └── sub-10_task-flanker_run-2_events.tsv
├── sub-11
│   ├── anat
│   │   └── sub-11_T1w.nii.gz -> ../../.git/annex/objects/kj/xX/MD5E-s10534963--9e5bff7ec0b5df2850e1d05b1af281ba.nii.gz/MD5E-s10534963--9e5bff7ec0b5df2850e1d05b1af281ba.nii.gz
│   └── func
│       ├── sub-11_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/35/fk/MD5E-s28226875--d5012074c2c7a0a394861b010bcf9a8f.nii.gz/MD5E-s28226875--d5012074c2c7a0a394861b010bcf9a8f.nii.gz
│       ├── sub-11_task-flanker_run-1_events.tsv
│       ├── sub-11_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/j7/ff/MD5E-s28198976--c0a64e3b549568c44bb40b1588027c9a.nii.gz/MD5E-s28198976--c0a64e3b549568c44bb40b1588027c9a.nii.gz
│       └── sub-11_task-flanker_run-2_events.tsv
├── sub-12
│   ├── anat
│   │   └── sub-12_T1w.nii.gz -> ../../.git/annex/objects/kx/2F/MD5E-s10550168--a7f651adc817b6678148b575654532a4.nii.gz/MD5E-s10550168--a7f651adc817b6678148b575654532a4.nii.gz
│   └── func
│       ├── sub-12_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/M0/fX/MD5E-s28403807--f1c3eb2e519020f4315a696ea845fc01.nii.gz/MD5E-s28403807--f1c3eb2e519020f4315a696ea845fc01.nii.gz
│       ├── sub-12_task-flanker_run-1_events.tsv
│       ├── sub-12_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/vW/V0/MD5E-s28424992--8740628349be3c056a0411bf4a852b25.nii.gz/MD5E-s28424992--8740628349be3c056a0411bf4a852b25.nii.gz
│       └── sub-12_task-flanker_run-2_events.tsv
├── sub-13
│   ├── anat
│   │   └── sub-13_T1w.nii.gz -> ../../.git/annex/objects/wM/Xw/MD5E-s10609761--440413c3251d182086105649164222c6.nii.gz/MD5E-s10609761--440413c3251d182086105649164222c6.nii.gz
│   └── func
│       ├── sub-13_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/mf/M4/MD5E-s28180916--aa35f4ad0cf630d6396a8a2dd1f3dda6.nii.gz/MD5E-s28180916--aa35f4ad0cf630d6396a8a2dd1f3dda6.nii.gz
│       ├── sub-13_task-flanker_run-1_events.tsv
│       ├── sub-13_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/XP/76/MD5E-s28202786--8caf1ac548c87b2b35f85e8ae2bf72c1.nii.gz/MD5E-s28202786--8caf1ac548c87b2b35f85e8ae2bf72c1.nii.gz
│       └── sub-13_task-flanker_run-2_events.tsv
├── sub-14
│   ├── anat
│   │   └── sub-14_T1w.nii.gz -> ../../.git/annex/objects/Zw/0z/MD5E-s9223596--33abfb5da565f3487e3a7aebc15f940c.nii.gz/MD5E-s9223596--33abfb5da565f3487e3a7aebc15f940c.nii.gz
│   └── func
│       ├── sub-14_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/Jp/29/MD5E-s29001492--250f1e4daa9be1d95e06af0d56629cc9.nii.gz/MD5E-s29001492--250f1e4daa9be1d95e06af0d56629cc9.nii.gz
│       ├── sub-14_task-flanker_run-1_events.tsv
│       ├── sub-14_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/PK/V2/MD5E-s29068193--5621a3b0af8132c509420b4ad9aaf8fb.nii.gz/MD5E-s29068193--5621a3b0af8132c509420b4ad9aaf8fb.nii.gz
│       └── sub-14_task-flanker_run-2_events.tsv
├── sub-15
│   ├── anat
│   │   └── sub-15_T1w.nii.gz -> ../../.git/annex/objects/Mz/qq/MD5E-s10752891--ddd2622f115ec0d29a0c7ab2366f6f95.nii.gz/MD5E-s10752891--ddd2622f115ec0d29a0c7ab2366f6f95.nii.gz
│   └── func
│       ├── sub-15_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/08/JJ/MD5E-s28285239--feda22c4526af1910fcee58d4c42f07e.nii.gz/MD5E-s28285239--feda22c4526af1910fcee58d4c42f07e.nii.gz
│       ├── sub-15_task-flanker_run-1_events.tsv
│       ├── sub-15_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/9f/0W/MD5E-s28289760--433000a1def662e72d8433dba151c61b.nii.gz/MD5E-s28289760--433000a1def662e72d8433dba151c61b.nii.gz
│       └── sub-15_task-flanker_run-2_events.tsv
├── sub-16
│   ├── anat
│   │   └── sub-16_T1w.nii.gz -> ../../.git/annex/objects/4g/8k/MD5E-s10927450--a196f7075c793328dd6ff3cebf36ea6b.nii.gz/MD5E-s10927450--a196f7075c793328dd6ff3cebf36ea6b.nii.gz
│   └── func
│       ├── sub-16_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/9z/g2/MD5E-s29757991--1a1648b2fa6cc74e31c94f109d8137ba.nii.gz/MD5E-s29757991--1a1648b2fa6cc74e31c94f109d8137ba.nii.gz
│       ├── sub-16_task-flanker_run-1_events.tsv
│       ├── sub-16_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/k8/4F/MD5E-s29773832--fe08739ea816254395b985ee704aaa99.nii.gz/MD5E-s29773832--fe08739ea816254395b985ee704aaa99.nii.gz
│       └── sub-16_task-flanker_run-2_events.tsv
├── sub-17
│   ├── anat
│   │   └── sub-17_T1w.nii.gz -> ../../.git/annex/objects/jQ/MQ/MD5E-s10826014--8e2a6b062df4d1c4327802f2b905ef36.nii.gz/MD5E-s10826014--8e2a6b062df4d1c4327802f2b905ef36.nii.gz
│   └── func
│       ├── sub-17_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/Wz/2P/MD5E-s28991563--9845f461a017a39d1f6e18baaa0c9c41.nii.gz/MD5E-s28991563--9845f461a017a39d1f6e18baaa0c9c41.nii.gz
│       ├── sub-17_task-flanker_run-1_events.tsv
│       ├── sub-17_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/jF/3m/MD5E-s29057821--84ccc041163bcc5b3a9443951e2a5a78.nii.gz/MD5E-s29057821--84ccc041163bcc5b3a9443951e2a5a78.nii.gz
│       └── sub-17_task-flanker_run-2_events.tsv
├── sub-18
│   ├── anat
│   │   └── sub-18_T1w.nii.gz -> ../../.git/annex/objects/3v/pK/MD5E-s10571510--6fc4b5792bc50ea4d14eb5247676fafe.nii.gz/MD5E-s10571510--6fc4b5792bc50ea4d14eb5247676fafe.nii.gz
│   └── func
│       ├── sub-18_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/94/P2/MD5E-s28185776--5b3879ec6fc4bbe1e48efc64984f88cf.nii.gz/MD5E-s28185776--5b3879ec6fc4bbe1e48efc64984f88cf.nii.gz
│       ├── sub-18_task-flanker_run-1_events.tsv
│       ├── sub-18_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/qp/6K/MD5E-s28234699--58019d798a133e5d7806569374dd8160.nii.gz/MD5E-s28234699--58019d798a133e5d7806569374dd8160.nii.gz
│       └── sub-18_task-flanker_run-2_events.tsv
├── sub-19
│   ├── anat
│   │   └── sub-19_T1w.nii.gz -> ../../.git/annex/objects/Zw/p8/MD5E-s8861893--d338005753d8af3f3d7bd8dc293e2a97.nii.gz/MD5E-s8861893--d338005753d8af3f3d7bd8dc293e2a97.nii.gz
│   └── func
│       ├── sub-19_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/04/k6/MD5E-s28178448--3874e748258cf19aa69a05a7c37ad137.nii.gz/MD5E-s28178448--3874e748258cf19aa69a05a7c37ad137.nii.gz
│       ├── sub-19_task-flanker_run-1_events.tsv
│       ├── sub-19_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/mz/P4/MD5E-s28190932--91e6b3e4318ca28f01de8cb967cf8421.nii.gz/MD5E-s28190932--91e6b3e4318ca28f01de8cb967cf8421.nii.gz
│       └── sub-19_task-flanker_run-2_events.tsv
├── sub-20
│   ├── anat
│   │   └── sub-20_T1w.nii.gz -> ../../.git/annex/objects/g1/FF/MD5E-s11025608--5929806a7aa5720fc755687e1450b06c.nii.gz/MD5E-s11025608--5929806a7aa5720fc755687e1450b06c.nii.gz
│   └── func
│       ├── sub-20_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/v5/ZJ/MD5E-s29931631--bf9abb057367ce66961f0b7913e8e707.nii.gz/MD5E-s29931631--bf9abb057367ce66961f0b7913e8e707.nii.gz
│       ├── sub-20_task-flanker_run-1_events.tsv
│       ├── sub-20_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/J3/KW/MD5E-s29945590--96cfd5b77cd096f6c6a3530015fea32d.nii.gz/MD5E-s29945590--96cfd5b77cd096f6c6a3530015fea32d.nii.gz
│       └── sub-20_task-flanker_run-2_events.tsv
├── sub-21
│   ├── anat
│   │   └── sub-21_T1w.nii.gz -> ../../.git/annex/objects/K6/6K/MD5E-s8662805--77b262ddd929fa08d78591bfbe558ac6.nii.gz/MD5E-s8662805--77b262ddd929fa08d78591bfbe558ac6.nii.gz
│   └── func
│       ├── sub-21_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/Wz/p9/MD5E-s28756041--9ae556d4e3042532d25af5dc4ab31840.nii.gz/MD5E-s28756041--9ae556d4e3042532d25af5dc4ab31840.nii.gz
│       ├── sub-21_task-flanker_run-1_events.tsv
│       ├── sub-21_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/xF/M3/MD5E-s28758438--81866411fc6b6333ec382a20ff0be718.nii.gz/MD5E-s28758438--81866411fc6b6333ec382a20ff0be718.nii.gz
│       └── sub-21_task-flanker_run-2_events.tsv
├── sub-22
│   ├── anat
│   │   └── sub-22_T1w.nii.gz -> ../../.git/annex/objects/JG/ZV/MD5E-s9282392--9e7296a6a5b68df46b77836182b6681a.nii.gz/MD5E-s9282392--9e7296a6a5b68df46b77836182b6681a.nii.gz
│   └── func
│       ├── sub-22_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/qW/Gw/MD5E-s28002098--c6bea10177a38667ceea3261a642b3c6.nii.gz/MD5E-s28002098--c6bea10177a38667ceea3261a642b3c6.nii.gz
│       ├── sub-22_task-flanker_run-1_events.tsv
│       ├── sub-22_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/VX/Zj/MD5E-s28027568--b34d0df9ad62485aba25296939429885.nii.gz/MD5E-s28027568--b34d0df9ad62485aba25296939429885.nii.gz
│       └── sub-22_task-flanker_run-2_events.tsv
├── sub-23
│   ├── anat
│   │   └── sub-23_T1w.nii.gz -> ../../.git/annex/objects/4Z/4x/MD5E-s10626062--db5a6ba6730b319c6425f2e847ce9b14.nii.gz/MD5E-s10626062--db5a6ba6730b319c6425f2e847ce9b14.nii.gz
│   └── func
│       ├── sub-23_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/VK/8F/MD5E-s28965005--4a9a96d9322563510ca14439e7fd6cea.nii.gz/MD5E-s28965005--4a9a96d9322563510ca14439e7fd6cea.nii.gz
│       ├── sub-23_task-flanker_run-1_events.tsv
│       ├── sub-23_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/56/20/MD5E-s29050413--753b0d2c23c4af6592501219c2e2c6bd.nii.gz/MD5E-s29050413--753b0d2c23c4af6592501219c2e2c6bd.nii.gz
│       └── sub-23_task-flanker_run-2_events.tsv
├── sub-24
│   ├── anat
│   │   └── sub-24_T1w.nii.gz -> ../../.git/annex/objects/jQ/fV/MD5E-s10739691--458f0046eff18ee8c43456637766a819.nii.gz/MD5E-s10739691--458f0046eff18ee8c43456637766a819.nii.gz
│   └── func
│       ├── sub-24_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/km/fV/MD5E-s29354610--29ebfa60e52d49f7dac6814cb5fdc2bc.nii.gz/MD5E-s29354610--29ebfa60e52d49f7dac6814cb5fdc2bc.nii.gz
│       ├── sub-24_task-flanker_run-1_events.tsv
│       ├── sub-24_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/Wj/KK/MD5E-s29423307--fedaa1d7c6e34420735bb3bbe5a2fe38.nii.gz/MD5E-s29423307--fedaa1d7c6e34420735bb3bbe5a2fe38.nii.gz
│       └── sub-24_task-flanker_run-2_events.tsv
├── sub-25
│   ├── anat
│   │   └── sub-25_T1w.nii.gz -> ../../.git/annex/objects/Gk/FQ/MD5E-s8998578--f560d832f13e757b485c16d570bf6ebc.nii.gz/MD5E-s8998578--f560d832f13e757b485c16d570bf6ebc.nii.gz
│   └── func
│       ├── sub-25_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/XW/1v/MD5E-s29473003--49b04e7e4b450ec5ef93ff02d4158775.nii.gz/MD5E-s29473003--49b04e7e4b450ec5ef93ff02d4158775.nii.gz
│       ├── sub-25_task-flanker_run-1_events.tsv
│       ├── sub-25_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/Qm/M7/MD5E-s29460132--b0e9039e9f33510631f229c8c2193285.nii.gz/MD5E-s29460132--b0e9039e9f33510631f229c8c2193285.nii.gz
│       └── sub-25_task-flanker_run-2_events.tsv
├── sub-26
│   ├── anat
│   │   └── sub-26_T1w.nii.gz -> ../../.git/annex/objects/kf/9F/MD5E-s10850250--5f103b2660f488e4afa193f9307c1291.nii.gz/MD5E-s10850250--5f103b2660f488e4afa193f9307c1291.nii.gz
│   └── func
│       ├── sub-26_task-flanker_run-1_bold.nii.gz -> ../../.git/annex/objects/QV/10/MD5E-s30127491--8e30aa4bbfcc461bac8598bf621283c5.nii.gz/MD5E-s30127491--8e30aa4bbfcc461bac8598bf621283c5.nii.gz
│       ├── sub-26_task-flanker_run-1_events.tsv
│       ├── sub-26_task-flanker_run-2_bold.nii.gz -> ../../.git/annex/objects/3G/Q6/MD5E-s30162480--80fd132e7cb1600ab248249e78f6f1aa.nii.gz/MD5E-s30162480--80fd132e7cb1600ab248249e78f6f1aa.nii.gz
│       └── sub-26_task-flanker_run-2_events.tsv
└── task-flanker_bold.json

80 directories, 192 files

Create timing files#

To model brain activity during different conditions of the Flanker task, we first need to create timing files based on the experimental events. These files capture when each trial occurred, how long it lasted, and whether any parametric modulation should be applied. This information is stored in each subject’s events.tsv file. We will extract the relevant details—condition name, onset, and duration—and convert them into AFNI’s timing file format. For each condition (congruent and incongruent), we will generate timing files for both runs, then combine them into condition-specific .1D files. These timing files will later be used in the GLM (general linear model) to estimate brain responses to each condition.

To automate this process, we will download a Bash script called make_Timings.sh from Andy’s AFNI_Scripts repository. This script should be placed in the experimental folder containing the subject directories (in our case, the ds000102/ folder).

!wget -O ds000102/make_Timings.sh https://raw.githubusercontent.com/andrewjahn/AFNI_Scripts/master/make_Timings.sh
--2025-05-01 05:26:07--  https://raw.githubusercontent.com/andrewjahn/AFNI_Scripts/master/make_Timings.sh
Resolving raw.githubusercontent.com (raw.githubusercontent.com)... 185.199.109.133, 185.199.110.133, 185.199.108.133, ...
Connecting to raw.githubusercontent.com (raw.githubusercontent.com)|185.199.109.133|:443... connected.
HTTP request sent, awaiting response... 200 OK
Length: 953 [text/plain]
Saving to: ‘ds000102/make_Timings.sh’

ds000102/make_Timin 100%[===================>]     953  --.-KB/s    in 0s      

2025-05-01 05:26:07 (70.9 MB/s) - ‘ds000102/make_Timings.sh’ saved [953/953]

#

Once the script is downloaded into the ds000102/ folder, we can execute it directly from the notebook. The command below does three things:

  1. cd ds000102 changes into the experimental directory that contains the subject folders.

  2. chmod +x make_Timings.sh makes the script executable.

  3. bash make_Timings.sh runs the script.

After running this command, you should see new timing files (e.g., congruent.1D, incongruent.1D) inside each subject’s func/ directory. These files are now ready to be used in the first-level GLM analysis.

! Note:

You may see a SyntaxWarning from AFNI’s internal Python scripts when running this command — this can be safely ignored and does not affect the output.

!cd ds000102 && chmod +x make_Timings.sh && bash make_Timings.sh
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \

Check the output:

!cat ds000102/sub-08/func/incongruent.1D
0 10 20 52 88 130 144 174 248 260 274 
0 10 52 64 88 150 164 174 196 232 260

Running Preprocessing and First Level Analysis for sub-08#

All of the preprocessing steps (from setup through scaling) for subject sub-08 were introduced and explained in the example notebook about Preprocessing with AFNI- which is highly inspired by Andy’s Brain Book’s excellent AFNI tutorial. There, it is covered how to useafni_proc.py to generate an automated pipeline, and how to interpret each preprocessing block. In this section, we extend that workflow by adding a regress block to model task-related brain activity using a general linear model (GLM):

Preprocessing and GLM Workflow:

➡️ setup ➡️ tcat ➡️ align ➡️ tlrc ➡️ volreg ➡️ blur ➡️ mask ➡️ scale ➡️ regress 🧠

outputs: includes fitted time series, beta weights, and statistical maps from the GLM.

🧾 regress step: Incorporates timing files, HRF modeling (GAM), symbolic GLTs, and executes 3dREMLfit for improved autocorrelation modeling.

!afni_proc.py                                                                                               \
    -subj_id                     sub_08                                                                    \
    -script                      proc.sub_08                                                               \
    -scr_overwrite                                                                                         \
    -out_dir                     ./afni_pro_glm/sub_08.results                                             \
    -blocks                      align tlrc volreg blur mask scale regress                                 \
    -copy_anat                   ./ds000102/sub-08/anat/sub-08_T1w.nii.gz                                  \
    -dsets                                                                                                 \
                                 ./ds000102/sub-08/func/sub-08_task-flanker_run-1_bold.nii.gz              \
                                 ./ds000102/sub-08/func/sub-08_task-flanker_run-2_bold.nii.gz              \
    -tcat_remove_first_trs       0                                                                         \
    -align_opts_aea              -giant_move                                                               \
    -tlrc_base                   MNI_avg152T1+tlrc                                                         \
    -volreg_align_to             MIN_OUTLIER                                                               \
    -volreg_align_e2a                                                                                      \
    -volreg_tlrc_warp                                                                                      \
    -blur_size                   4.0                                                                       \
    -regress_stim_times          ./ds000102/sub-08/func/congruent.1D ./ds000102/sub-08/func/incongruent.1D \
    -regress_stim_labels         congruent incongruent                                                     \
    -regress_stim_types          times times                                                               \
    -regress_basis               GAM                                                                       \
    -regress_opts_3dD                                                                                      \
        -gltsym 'SYM: +incongruent -congruent' -glt_label 1 incongruent-congruent                          \
        -gltsym 'SYM: +congruent -incongruent' -glt_label 2 congruent-incongruent                          \
        -jobs 8                                                                                            \
        -GOFORIT 0                                                                                         \
    -regress_no_motion_deriv                                                                               \
    -regress_run_clustsim         no                                                                       \
    -regress_reml_exec                                                                                     \
    -html_review_style        pythonic
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
-- applying input view as +orig
-- will use min outlier volume as motion base
-- tcat: reps is now 146
++ updating polort to 2, from run len 292.0 s
-- volreg: using base dset vr_base_min_outlier+orig
++ volreg: applying volreg/epi2anat/tlrc xforms to isotropic 3 mm tlrc voxels
-- applying anat warps to 1 dataset(s): sub-08_T1w
-- masking: group anat = 'MNI_avg152T1+tlrc', exists = 1
-- have 1 ROI dict entries ...
-- no 3dClustSim (since no blur estimation)
** failed to load module matplotlib.pyplot
** warning: -html_review_style pythonic: missing matplotlib library
-- using default: will not apply EPI Automask
   (see 'MASKING NOTE' from the -help for details)

--> script is file: proc.sub_08

    to execute via tcsh:
         tcsh -xef proc.sub_08 |& tee output.proc.sub_08

    to execute via bash:
         tcsh -xef proc.sub_08 2>&1 | tee output.proc.sub_08

Below is a brief explanation of the key options added to afni_proc.py:

-blocks ... regress: Adds the GLM regression step to the processing pipeline, so we can estimate condition-specific brain activity.

-regress_stim_times: Points to the timing .1D files (e.g., congruent.1D, incongruent.1D) we created earlier. These specify when each condition occurred during the experiment.

-regress_stim_labels: Assigns labels to the timing files. These labels are used internally in AFNI (and in our symbolic GLTs) to refer to each condition.

-regress_basis GAM: Applies the canonical hemodynamic response function (HRF) using a Gamma function, which models the typical shape of neural activation over time in response to a stimulus.

-regress_stim_types: times - indicates that the stimulus timing files list event onsets in seconds.

-regress_opts_3dD: Passes additional options to the 3dDeconvolve command that runs the regression. In this case:

-gltsym 'SYM: +incongruent -congruent': Defines a contrast comparing incongruent > congruent.

-gltsym 'SYM: +congruent -incongruent': Defines the reverse contrast, congruent > incongruent.

-glt_label: Assigns human-readable labels to each contrast.

-jobs 8: Specifies using 8 CPU threads for faster computation.

-GOFORIT 0: Prevents the script from overriding collinearity warnings in the design matrix. Useful for debugging.

-regress_no_motion_deriv: Omits the temporal derivatives of the motion parameters from the regression model. These derivatives can help account for rapid or complex head motion, but may be unnecessary if the data is relatively clean or if simpler motion correction is sufficient.

-regress_run_clustsim no: Disables real-time cluster-level threshold simulations, since we’re not doing single-subject inference.

-regress_reml_exec: Tells AFNI to run 3dREMLfit, which uses a more sophisticated model of temporal autocorrelation. This is typically more accurate than the default 3dDeconvolve and recommended for group-level analysis later.

-html_review_style pythonic: Generates a user-friendly HTML summary of the analysis, styled with Python tools.

Correcting the Script

Before running the preprocessing script, we need to make a small manual adjustment. AFNI’s @auto_tlrc command, which handles nonlinear alignment to template space, sometimes fails if the anatomical image is far from the template origin. To prevent this, we insert the -init_xform AUTO_CENTER option into the generated script. This centers the anatomical image before alignment, helping ensure the normalization step runs smoothly. The following code snippet does this automatically by editing the proc.sub_08 script before execution. This step was also discussed in the example notebook Preprocessing with AFNI, where we walked through this corrrection in more detail.

# Edit proc.sub_08
with open('./proc.sub_08', 'r') as file:
    lines = file.readlines()

# Insert "-init_xform AUTO_CENTER" into the @auto_tlrc command
for idx, line in enumerate(lines):
    if line.strip().startswith('@auto_tlrc'):
        lines[idx] = line.strip() + ' -init_xform AUTO_CENTER\n'

# Save it back
with open('proc.sub_08', 'w') as file:
    file.writelines(lines)

Runing the Preprocessing and GLM Script

With the script proc.sub_08 prepared, we’re ready to run it. This will carry out all preprocessing steps followed by the GLM analysis and and logs the full output to output.proc.sub_08, allowing to review everything that happened during processing:

! tcsh -xef proc.sub_08 |& tee output.proc.sub_08
echo auto-generated by afni_proc.py, Thu May  1 05:26:23 2025
auto-generated by afni_proc.py, Thu May  1 05:26:23 2025
echo (version 7.16, May 19, 2021)
(version 7.16, May 19, 2021)
echo execution started: `date`
date
execution started: Thu May  1 05:26:24 UTC 2025
afni -ver
Precompiled binary linux_openmp_64: Jul  8 2021 (Version AFNI_21.2.00 'Nerva')
afni_history -check_date 27 Jun 2019
-- is current: afni_history as new as: 27 Jun 2019
               most recent entry is:   30 Jun 2021
if ( 0 ) then
if ( 0 > 0 ) then
set subj = sub_08
endif
set output_dir = ./afni_pro_glm/sub_08.results
if ( -d ./afni_pro_glm/sub_08.results ) then
set runs = ( `count -digits 2 1 2` )
count -digits 2 1 2
mkdir -p ./afni_pro_glm/sub_08.results
mkdir ./afni_pro_glm/sub_08.results/stimuli
cp ./ds000102/sub-08/func/congruent.1D ./ds000102/sub-08/func/incongruent.1D ./afni_pro_glm/sub_08.results/stimuli
3dcopy ds000102/sub-08/anat/sub-08_T1w.nii.gz ./afni_pro_glm/sub_08.results/sub-08_T1w
++ 3dcopy: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
3dTcat -prefix ./afni_pro_glm/sub_08.results/pb00.sub_08.r01.tcat ds000102/sub-08/func/sub-08_task-flanker_run-1_bold.nii.gz[0..$]
++ 3dTcat: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ elapsed time = 0.7 s
3dTcat -prefix ./afni_pro_glm/sub_08.results/pb00.sub_08.r02.tcat ds000102/sub-08/func/sub-08_task-flanker_run-2_bold.nii.gz[0..$]
++ 3dTcat: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ elapsed time = 0.7 s
set tr_counts = ( 146 146 )
cd ./afni_pro_glm/sub_08.results
touch out.pre_ss_warn.txt
foreach run ( 01 02 )
3dToutcount -automask -fraction -polort 2 -legendre pb00.sub_08.r01.tcat+orig
++ 3dToutcount: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ 38915 voxels passed mask/clip
if ( `1deval -a outcount.r$run.1D"{0}" -expr "step(a-0.4)"` ) then
1deval -a outcount.r01.1D{0} -expr step(a-0.4)
end
3dToutcount -automask -fraction -polort 2 -legendre pb00.sub_08.r02.tcat+orig
++ 3dToutcount: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ 38896 voxels passed mask/clip
if ( `1deval -a outcount.r$run.1D"{0}" -expr "step(a-0.4)"` ) then
1deval -a outcount.r02.1D{0} -expr step(a-0.4)
end
cat outcount.r01.1D outcount.r02.1D
set minindex = `3dTstat -argmin -prefix - outcount_rall.1D\'`
3dTstat -argmin -prefix - outcount_rall.1D'
++ 3dTstat: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: KR Hammett & RW Cox
*+ WARNING: Input dataset is not 3D+time; assuming TR=1.0
set ovals = ( `1d_tool.py -set_run_lengths $tr_counts                       
                          -index_to_run_tr $minindex` )
1d_tool.py -set_run_lengths 146 146 -index_to_run_tr 28
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
set minoutrun = 01
set minouttr = 28
echo min outlier: run 01, TR 28
tee out.min_outlier.txt
min outlier: run 01, TR 28
3dbucket -prefix vr_base_min_outlier pb00.sub_08.r01.tcat+orig[28]
++ 3dbucket: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
align_epi_anat.py -anat2epi -anat sub-08_T1w+orig -save_skullstrip -suffix _al_junk -epi vr_base_min_outlier+orig -epi_base 0 -epi_strip 3dAutomask -giant_move -volreg off -tshift off
#++ align_epi_anat version: 1.62
#++ turning off volume registration
#Script is running (command trimmed):
  3dAttribute DELTA ./vr_base_min_outlier+orig
#Script is running (command trimmed):
  3dAttribute DELTA ./vr_base_min_outlier+orig
#Script is running (command trimmed):
  3dAttribute DELTA ./sub-08_T1w+orig
#++ Multi-cost is lpc
#++ Removing all the temporary files
#Script is running:
  \rm -f ./__tt_vr_base_min_outlier*
#Script is running:
  \rm -f ./__tt_sub-08_T1w*
#Script is running (command trimmed):
  3dcopy ./sub-08_T1w+orig ./__tt_sub-08_T1w+orig
++ 3dcopy: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
#++ Removing skull from anat data
#Script is running (command trimmed):
  3dSkullStrip -orig_vol -input ./__tt_sub-08_T1w+orig -prefix ./__tt_sub-08_T1w_ns
#Script is running (command trimmed):
  3dinfo ./__tt_sub-08_T1w_ns+orig | \grep 'Data Axes Tilt:'|\grep 'Oblique'
#++ Dataset /home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/afni_pro_glm/sub_08.results/__tt_sub-08_T1w_ns+orig is not oblique
#Script is running (command trimmed):
  3dinfo ./vr_base_min_outlier+orig | \grep 'Data Axes Tilt:'|\grep 'Oblique'
#++ Dataset /home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/afni_pro_glm/sub_08.results/vr_base_min_outlier+orig is not oblique
#++ using 0th sub-brick because only one found
#Script is running (command trimmed):
  3dbucket -prefix ./__tt_vr_base_min_outlier_ts ./vr_base_min_outlier+orig'[0]'
++ 3dbucket: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
#++ removing skull or area outside brain
#Script is running (command trimmed):
  3dAutomask -apply_prefix ./__tt_vr_base_min_outlier_ts_ns ./__tt_vr_base_min_outlier_ts+orig
++ 3dAutomask: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Emperor Zhark
++ Loading dataset ./__tt_vr_base_min_outlier_ts+orig
++ Forming automask
 + Fixed clip level = 345.050415
 + Used gradual clip level = 330.013794 .. 365.519012
 + Number voxels above clip level = 39471
 + Clustering voxels ...
 + Largest cluster has 38949 voxels
 + Clustering voxels ...
 + Largest cluster has 38549 voxels
 + Filled   354 voxels in small holes; now have 38903 voxels
 + Filled     3 voxels in large holes; now have 38906 voxels
 + Clustering voxels ...
 + Largest cluster has 38906 voxels
 + Clustering non-brain voxels ...
 + Clustering voxels ...
 + Largest cluster has 124934 voxels
 + Mask now has 38906 voxels
++ 38906 voxels in the mask [out of 163840: 23.75%]
++ first  11 x-planes are zero [from L]
++ last   11 x-planes are zero [from R]
++ first   0 y-planes are zero [from P]
++ last    5 y-planes are zero [from A]
++ first   1 z-planes are zero [from I]
++ last    3 z-planes are zero [from S]
++ applying mask to original data
++ Writing masked data
++ Output dataset ./__tt_vr_base_min_outlier_ts_ns+orig.BRIK
++ CPU time = 0.000000 sec
#++ Computing weight mask
#Script is running (command trimmed):
  3dBrickStat -automask -percentile 90.000000 1 90.000000 ./__tt_vr_base_min_outlier_ts_ns+orig
#++ Applying threshold of 819.000000 on /home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/afni_pro_glm/sub_08.results/__tt_vr_base_min_outlier_ts_ns+orig
#Script is running (command trimmed):
  3dcalc -datum float -prefix ./__tt_vr_base_min_outlier_ts_ns_wt -a ./__tt_vr_base_min_outlier_ts_ns+orig -expr 'min(1,(a/819.000000))'
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ././__tt_vr_base_min_outlier_ts_ns_wt+orig.BRIK
#++ Aligning anat data to epi data
#Script is running (command trimmed):
  3dAllineate -lpc -wtprefix ./__tt_sub-08_T1w_ns_al_junk_wtal -weight ./__tt_vr_base_min_outlier_ts_ns_wt+orig -source ./__tt_sub-08_T1w_ns+orig -prefix ./sub-08_T1w_al_junk -base ./__tt_vr_base_min_outlier_ts_ns+orig -cmass -1Dmatrix_save ./sub-08_T1w_al_junk_mat.aff12.1D -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_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Zhark the Registrator
++ Option '-cmass' enables center-of-mass code = 7 = +xyz
++ Source dataset: ./__tt_sub-08_T1w_ns+orig.HEAD
++ Base dataset:   ./__tt_vr_base_min_outlier_ts_ns+orig.HEAD
++ Loading datasets into memory
++ 1583872 voxels in -source_automask+2
++ largeness ==> set -twobest 29
++ Zero-pad: ybot=8 ytop=3
++ Zero-pad: zbot=7 ztop=5
++ 38906 voxels [15.6%] in weight mask
++ Output dataset ./__tt_sub-08_T1w_ns_al_junk_wtal+orig.BRIK
++ Number of points for matching = 38906
++ NOTE: base and source coordinate systems have different handedness
 +       Orientations: base=Right handed (LPI); source=Left handed (RPI)
 +     - It is nothing to worry about: 3dAllineate aligns based on coordinates.
 +     - But it is always important to check the alignment visually to be sure.
++ Local correlation: blok type = 'TOHD(17.0941)'
++ base center of mass = 31.963 35.048 27.741 (index)
 + source center of mass = 84.800 114.693 116.298 (index)
 + source-target CM = 86.190 -3.441 -1.709 (xyz)
 + estimated center of mass shifts = 86.190 -3.441 -1.709
++ shift param auto-range: 25.5..146.9 -74.7..67.8 -67.2..63.8
 + Range param#4 [z-angle] = -6.000000 .. 6.000000  center = 0.000000
 + Range param#5 [x-angle] = -6.000000 .. 6.000000  center = 0.000000
 + Range param#6 [y-angle] = -6.000000 .. 6.000000  center = 0.000000
 + Range param#1 [x-shift] = 76.190132 .. 96.190132  center = 86.190132
 + Range param#2 [y-shift] = -13.440697 .. 6.559303  center = -3.440697
 + Range param#3 [z-shift] = -11.708786 .. 8.291214  center = -1.708786
 + Range param#4 [z-angle] = -45.000000 .. 45.000000  center = 0.000000
 + Range param#5 [x-angle] = -45.000000 .. 45.000000  center = 0.000000
 + Range param#6 [y-angle] = -45.000000 .. 45.000000  center = 0.000000
 + Range param#1 [x-shift] = 46.190132 .. 126.190132  center = 86.190132
 + Range param#2 [y-shift] = -43.440697 .. 36.559303  center = -3.440697
 + Range param#3 [z-shift] = -41.708786 .. 38.291214  center = -1.708786
 + 12 free parameters
++ Normalized (unitless) convergence radius = 0.0000088
++ Final parameter search ranges:
 +       x-shift =   46.190 ..  126.190
 +       y-shift =  -43.441 ..   36.559
 +       z-shift =  -41.709 ..   38.291
 +       z-angle =  -45.000 ..   45.000
 +       x-angle =  -45.000 ..   45.000
 +       y-angle =  -45.000 ..   45.000
 +       x-scale =    0.711 ..    1.406
 +       y-scale =    0.711 ..    1.406
 +       z-scale =    0.711 ..    1.406
 +     y/x-shear =   -0.111 ..    0.111
 +     z/x-shear =   -0.111 ..    0.111
 +     z/y-shear =   -0.111 ..    0.111
++ changing output grid spacing to 1.0000 mm
++ OpenMP thread count = 15
++ ======= Allineation of 1 sub-bricks using Local Pearson Correlation Signed =======
 + source mask has 1583872 [out of 11534336] voxels
 + base mask has 52253 [out of 249600] voxels
++ ========== sub-brick #0 ========== [total CPU to here=0.0 s]
++ *** Coarse pass begins ***
 + * Enter alignment setup routine
 + - copying base image
 + - copying source image
 + - Smoothing base; radius=4.00
 + - Smoothing source; radius=4.00
 + !source mask fill: ubot=64 usiz=159.5
 + - copying weight image
 + - using 38906 points from base image [use_all=2]
 + * Exit alignment setup routine
 + - Search for coarse starting parameters
 + 32391 total points stored in 63 'TOHD(17.5558)' bloks (0 duplicates)
 + - number of free params = 6
 + - Test (64+191)*64 params [top5=*o+-.]:#o+o-.+.o--.--+oo-.++-.o-+-.+o+o---+.--.oo.+++o+$+.--.+..o.o + - best 88 costs found:
   o= 0 v=-0.078395:  86.19  -3.44  -1.71   0.00   0.00   0.00  [grid]
   o= 1 v=-0.024170:  91.62   4.15  28.38 -38.19  22.74 -41.67  [rand]
   o= 2 v=-0.022830:  100.19 -18.97  33.97 -14.61 -39.00 -28.71  [rand]
   o= 3 v=-0.022358:  92.86 -30.11  24.96   7.50 -30.00 -30.00  [grid]
   o= 4 v=-0.022101:  121.80  -7.85 -38.58 -37.76  24.22   3.86  [rand]
   o= 5 v=-0.021851:  97.68 -19.75 -35.46 -19.17  13.96   2.56  [rand]
   o= 6 v=-0.021730:  122.84 -20.67  20.55   5.26 -41.39 -40.03  [rand]
   o= 7 v=-0.021515:  101.83 -12.20 -35.54 -23.16  17.17  -3.59  [rand]
   o= 8 v=-0.021205:  91.12  -0.47  27.39 -40.99  18.21 -33.12  [rand]
   o= 9 v=-0.020806:  121.80  -7.85 -38.58 -37.76  24.22  -3.86  [rand]
   o=10 v=-0.020703:  97.68 -19.75 -35.46 -19.17  13.96  -2.56  [rand]
   o=11 v=-0.020229:  121.80   0.97  35.16  37.76 -24.22  -3.86  [rand]
   o=12 v=-0.020075:  90.34  20.37  30.18  31.52 -11.26 -33.63  [rand]
   o=13 v=-0.019908:  100.19 -18.97  33.97  14.61 -39.00 -28.71  [rand]
   o=14 v=-0.019694:  120.99 -17.22 -35.72  10.62  -7.10 -10.42  [rand]
   o=15 v=-0.019540:  119.22   1.58 -38.52 -11.98   4.28 -19.20  [rand]
   o=16 v=-0.019170:  88.48 -10.62 -33.40 -10.97  18.37   5.04  [rand]
   o=17 v=-0.018913:  121.80   0.97 -38.58 -37.76  24.22   3.86  [rand]
   o=18 v=-0.018894:  96.65 -30.71  19.79 -34.95  -5.03 -42.69  [rand]
   o=19 v=-0.018891:  115.81  31.17  35.11  24.31 -11.89  -2.84  [rand]
   o=20 v=-0.018703:  92.86 -30.11  24.96  -7.50 -30.00 -30.00  [grid]
   o=21 v=-0.018636:  115.81  31.17  35.11  24.31 -11.89   2.84  [rand]
   o=22 v=-0.018271:  74.70  12.87 -35.46  19.17  13.96   2.56  [rand]
   o=23 v=-0.018249:  83.90 -10.62 -33.40 -10.97  18.37   5.04  [rand]
   o=24 v=-0.018182:  119.22  -8.46 -38.52 -11.98   4.28 -19.20  [rand]
   o=25 v=-0.018157:  112.86   3.23 -28.38 -30.00   7.50   7.50  [grid]
   o=26 v=-0.018092:  113.03 -16.54 -34.29 -39.07  28.37   8.01  [rand]
   o=27 v=-0.018024:  121.80  -7.85  35.16  37.76 -24.22  -3.86  [rand]
   o=28 v=-0.017957:  91.12  -6.41  27.39 -40.99  18.21 -33.12  [rand]
   o=29 v=-0.017956:  101.83 -12.20 -35.54 -23.16  17.17   3.59  [rand]
   o=30 v=-0.017508:  120.99 -17.22 -35.72 -10.62  -7.10 -10.42  [rand]
   o=31 v=-0.017362:  74.70  12.87 -35.46  19.17  13.96  -2.56  [rand]
   o=32 v=-0.017349:  120.99 -17.22 -35.72 -10.62   7.10 -10.42  [rand]
   o=33 v=-0.016693:  105.31  19.97 -35.01 -37.88  13.88  18.42  [rand]
   o=34 v=-0.016675:  102.99  15.02  30.65  10.10 -16.32 -39.31  [rand]
   o=35 v=-0.016669:  105.31  19.97 -35.01 -37.88  13.88 -18.42  [rand]
   o=36 v=-0.016632:  120.99 -17.22 -35.72  10.62   7.10 -10.42  [rand]
   o=37 v=-0.016450:  99.53 -27.69  29.08   6.84 -32.76 -20.90  [rand]
   o=38 v=-0.016261:  79.52 -30.11  24.96 -30.00  -7.50 -30.00  [grid]
   o=39 v=-0.016134:  99.35  34.44  35.49  14.03  -8.39 -25.20  [rand]
   o=40 v=-0.016094:  79.78  30.50 -38.28 -19.28  27.13  15.13  [rand]
   o=41 v=-0.015858:  95.39 -15.21 -23.44  -6.82  34.51  24.39  [rand]
   o=42 v=-0.015801:  120.99 -17.22 -35.72  10.62  -7.10  10.42  [rand]
   o=43 v=-0.015734:  70.55   5.32 -35.54  23.16  17.17  -3.59  [rand]
   o=44 v=-0.015723:  67.07  19.97 -35.01  37.88  13.88 -18.42  [rand]
   o=45 v=-0.015700:  92.86  23.23  24.96  30.00  -7.50 -30.00  [grid]
   o=46 v=-0.015623:  113.12 -31.58 -39.65  15.05   4.71 -12.78  [rand]
   o=47 v=-0.015567:  92.86 -10.11 -28.38  -7.50   7.50  30.00  [grid]
   o=48 v=-0.015330:  88.48 -10.62 -33.40 -10.97  18.37  -5.04  [rand]
   o=49 v=-0.015192:  92.03 -32.53  20.97  30.43 -41.57 -36.66  [rand]
   o=50 v=-0.015111:  103.24 -26.13  22.54 -12.15 -12.44 -39.75  [rand]
   o=51 v=-0.015075:  122.78 -30.74  29.53 -25.97 -37.53 -40.21  [rand]
   o=52 v=-0.014925:  92.86 -10.11 -28.38  -7.50  30.00  30.00  [grid]
   o=53 v=-0.014904:  121.80   0.97 -38.58 -37.76  24.22  -3.86  [rand]
   o=54 v=-0.014835:  102.99 -21.90  30.65 -10.10 -16.32 -39.31  [rand]
   o=55 v=-0.014711:  102.99  15.02 -34.07 -10.10 -16.32  39.31  [rand]
   o=56 v=-0.014651:  119.22  -8.46 -38.52 -11.98  -4.28 -19.20  [rand]
   o=57 v=-0.014527:  99.35 -41.33 -38.90  14.03   8.39 -25.20  [rand]
   o=58 v=-0.014469:  70.55 -12.20 -35.54  23.16  17.17   3.59  [rand]
   o=59 v=-0.014214:  121.80  -7.85  35.16  37.76 -24.22   3.86  [rand]
   o=60 v=-0.014171:  70.55 -12.20 -35.54  23.16  17.17  -3.59  [rand]
   o=61 v=-0.014132:  94.85 -27.60  34.86  27.41 -42.10 -24.35  [rand]
   o=62 v=-0.014108:  92.86 -10.11 -28.38  30.00   7.50   7.50  [grid]
   o=63 v=-0.013985:  92.61 -37.38 -38.28  19.28  27.13 -15.13  [rand]
   o=64 v=-0.013771:  56.91 -19.20  28.15  13.45 -19.96  14.96  [rand]
   o=65 v=-0.013738:  104.93 -39.84 -34.76  24.90   4.74 -17.23  [rand]
   o=66 v=-0.013600:  92.86   3.23 -28.38  -7.50  30.00  30.00  [grid]
   o=67 v=-0.013545:  102.99  15.02 -34.07  10.10 -16.32  39.31  [rand]
   o=68 v=-0.013506:  97.68  12.87 -35.46 -19.17  13.96  -2.56  [rand]
   o=69 v=-0.013420:  92.86   3.23  24.96  30.00 -30.00 -30.00  [grid]
   o=70 v=-0.013384:  83.90 -10.62 -33.40 -10.97  18.37  -5.04  [rand]
   o=71 v=-0.013341:  115.81 -38.05 -38.52  24.31 -11.89  -2.84  [rand]
   o=72 v=-0.013295:  59.26 -31.58  36.24  15.05  -4.71  12.78  [rand]
   o=73 v=-0.013221:  79.78  30.50 -38.28  19.28  27.13  15.13  [rand]
   o=74 v=-0.013191:  59.35   9.66 -34.29  39.07  28.37  -8.01  [rand]
   o=75 v=-0.013149:  118.40 -32.49  34.43 -40.41 -19.09 -40.75  [rand]
   o=76 v=-0.013072:  70.55   5.32 -35.54  23.16  17.17   3.59  [rand]
   o=77 v=-0.013043:  65.94  23.84 -36.19  37.90   5.03   3.08  [rand]
   o=78 v=-0.012929:  92.86 -10.11 -28.38   7.50   7.50   7.50  [grid]
   o=79 v=-0.012857:  60.67 -34.78  32.57  42.46 -41.07  35.63  [rand]
   o=80 v=-0.012789:  99.35 -41.33  35.49  14.03  -8.39 -25.20  [rand]
   o=81 v=-0.012665:  97.68  12.87 -35.46 -19.17  13.96   2.56  [rand]
   o=82 v=-0.012652:  112.86 -30.11 -28.38  30.00   7.50   7.50  [grid]
   o=83 v=-0.012596:  104.93 -39.84  31.34 -24.90  -4.74 -17.23  [rand]
   o=84 v=-0.012570:  83.90 -10.62 -33.40  10.97  18.37  -5.04  [rand]
   o=85 v=-0.012553:  92.86 -10.11 -28.38  -7.50  30.00   7.50  [grid]
   o=86 v=-0.012529:  92.86 -10.11  24.96  -7.50  -7.50 -30.00  [grid]
   o=87 v=-0.012519:  80.37  10.75  27.93  38.21 -15.41 -13.51  [rand]
 + - A little optimization:*[#16335=-0.0833147] *[#16338=-0.0996876] *[#16339=-0.122258] *[#16342=-0.125257] *[#16344=-0.126031] *[#16346=-0.127847] *[#16349=-0.129014] *[#16352=-0.129155] *[#16355=-0.129328] *[#16356=-0.129367] *[#16360=-0.12939] *[#16362=-0.129425] *[#16363=-0.129437] *[#16366=-0.129478] ........................................................................................
 + - costs of the above after a little optimization:
  *o= 0 v=-0.129478:  86.56  -2.92   0.24  -1.17   0.39   0.22  [grid]  [f=50]
   o= 1 v=-0.025208:  91.85   3.62  28.37 -37.98  22.65 -41.84  [rand]  [f=41]
   o= 2 v=-0.037638:  97.07 -22.70  36.86 -10.25 -41.88 -25.72  [rand]  [f=62]
   o= 3 v=-0.026228:  94.01 -30.11  26.00   6.89 -35.26 -29.95  [grid]  [f=67]
   o= 4 v=-0.025109:  122.87  -3.88 -38.32 -37.64  24.31   3.06  [rand]  [f=61]
   o= 5 v=-0.023467:  97.59 -19.20 -35.11 -18.55  14.45   2.78  [rand]  [f=47]
   o= 6 v=-0.032558:  124.34 -28.56  20.34   5.63 -41.94 -44.51  [rand]  [f=52]
   o= 7 v=-0.024558:  103.87 -12.91 -36.21 -26.12  14.64  -5.56  [rand]  [f=68]
   o= 8 v=-0.026595:  92.49   0.17  27.38 -37.57  16.88 -34.60  [rand]  [f=47]
   o= 9 v=-0.025748:  122.87  -7.62 -36.96 -38.73  25.59   5.74  [rand]  [f=37]
   o=10 v=-0.023050:  97.81 -19.65 -34.79 -19.15  13.89   2.05  [rand]  [f=36]
   o=11 v=-0.034817:  125.56   3.51  37.77  32.42 -27.27  -8.86  [rand]  [f=47]
   o=12 v=-0.026636:  90.62  19.43  30.46  30.75 -11.47 -27.04  [rand]  [f=54]
   o=13 v=-0.029615:  95.65 -16.42  33.99  15.06 -38.94 -27.36  [rand]  [f=44]
   o=14 v=-0.025724:  121.05 -17.94 -34.73  10.44  -8.00  -4.28  [rand]  [f=40]
   o=15 v=-0.027042:  119.10   0.10 -39.89 -13.81  11.33 -14.01  [rand]  [f=42]
   o=16 v=-0.029803:  88.38 -15.30 -33.36 -10.38  12.73   4.37  [rand]  [f=58]
   o=17 v=-0.025471:  120.77  -7.35 -37.30 -34.55  25.97   6.34  [rand]  [f=51]
   o=18 v=-0.021813:  96.06 -31.35  20.30 -37.16  -7.69 -44.56  [rand]  [f=37]
   o=19 v=-0.039610:  120.38  31.62  37.96  31.21 -11.89  -1.49  [rand]  [f=60]
   o=20 v=-0.030208:  99.98 -30.12  26.92  -4.50 -28.25 -34.17  [grid]  [f=62]
   o=21 v=-0.033973:  115.95  30.51  37.09  27.08  -7.23   4.45  [rand]  [f=45]
   o=22 v=-0.024448:  68.66  12.44 -38.44  19.11  14.37   2.63  [rand]  [f=52]
   o=23 v=-0.030816:  88.36 -12.05 -34.28 -12.31  11.56   5.36  [rand]  [f=57]
   o=24 v=-0.026831:  119.70  -7.09 -37.52 -10.99   4.50 -13.47  [rand]  [f=43]
   o=25 v=-0.021834:  110.54   4.11 -28.89 -31.19   6.72   7.75  [grid]  [f=46]
   o=26 v=-0.029659:  112.69 -13.96 -35.31 -28.09  23.99   4.39  [rand]  [f=64]
   o=27 v=-0.036380:  124.25 -11.62  38.17  33.28 -31.14  -4.50  [rand]  [f=57]
   o=28 v=-0.026330:  92.18   1.00  27.77 -39.33  18.23 -32.61  [rand]  [f=51]
   o=29 v=-0.022613:  102.63 -11.90 -37.10 -25.08  13.86  -0.27  [rand]  [f=35]
   o=30 v=-0.023502:  119.40 -16.34 -38.41  -9.52  -2.70 -13.24  [rand]  [f=49]
   o=31 v=-0.024601:  69.46  14.02 -37.34  19.44  12.69  -2.24  [rand]  [f=44]
   o=32 v=-0.025824:  119.43  -8.11 -37.98  -7.01  10.78 -13.52  [rand]  [f=83]
   o=33 v=-0.028485:  111.32  17.78 -33.51 -44.98  10.27  21.60  [rand]  [f=50]
   o=34 v=-0.021606:  103.05  11.34  30.91  10.44 -16.63 -39.34  [rand]  [f=54]
   o=35 v=-0.025812:  105.92  18.80 -34.03 -38.48  13.27 -12.88  [rand]  [f=49]
   o=36 v=-0.023639:  120.56 -21.02 -38.02   5.46   4.63 -15.69  [rand]  [f=51]
   o=37 v=-0.022421:  96.59 -28.00  29.09   6.71 -31.63 -25.55  [rand]  [f=39]
   o=38 v=-0.020190:  79.59 -26.31  24.88 -29.92  -8.68 -28.78  [grid]  [f=49]
   o=39 v=-0.021749:  96.94  33.57  35.86  11.35  -6.94 -19.87  [rand]  [f=66]
   o=40 v=-0.019895:  82.95  28.96 -37.93 -17.75  28.76  13.02  [rand]  [f=37]
   o=41 v=-0.021356:  91.66 -14.96 -22.76  -7.10  34.58  24.82  [rand]  [f=46]
   o=42 v=-0.027107:  124.49 -20.18 -32.05  10.69  -7.44   9.91  [rand]  [f=45]
   o=43 v=-0.026319:  68.91  11.17 -38.05  20.29  19.40  -6.43  [rand]  [f=56]
   o=44 v=-0.024913:  67.84  15.42 -35.49  37.39  14.37 -18.96  [rand]  [f=37]
   o=45 v=-0.023354:  93.76  23.30  27.77  29.47  -7.75 -31.27  [grid]  [f=40]
   o=46 v=-0.019407:  109.48 -31.82 -39.14  15.51   4.62 -13.43  [rand]  [f=46]
   o=47 v=-0.022879:  92.79 -14.50 -30.57  -6.67   8.67  35.86  [grid]  [f=59]
   o=48 v=-0.028698:  88.61 -13.59 -36.48 -10.26  12.62   0.84  [rand]  [f=53]
   o=49 v=-0.019705:  92.37 -28.32  21.44  30.84 -39.72 -37.84  [rand]  [f=65]
   o=50 v=-0.022741:  99.40 -24.95  21.80 -13.00 -13.24 -40.83  [rand]  [f=46]
   o=51 v=-0.025023:  125.97 -26.96  37.93 -27.17 -36.78 -38.74  [rand]  [f=57]
   o=52 v=-0.018040:  92.91  -9.23 -27.61  -8.65  30.90  29.96  [grid]  [f=65]
   o=53 v=-0.026083:  119.13  -8.06 -39.09 -31.95  24.41  -0.92  [rand]  [f=47]
   o=54 v=-0.021481:  97.21 -15.76  28.19  -9.68 -14.20 -39.20  [rand]  [f=52]
   o=55 v=-0.029622:  102.22  23.54 -40.40  -8.51 -15.66  40.94  [rand]  [f=57]
   o=56 v=-0.024318:  119.26 -12.01 -40.99  -6.33  -3.92 -15.68  [rand]  [f=67]
   o=57 v=-0.016309:  99.90 -40.50 -41.08  13.83   7.03 -28.14  [rand]  [f=41]
   o=58 v=-0.020067:  70.82  -7.68 -36.96  23.60  18.14   3.28  [rand]  [f=53]
   o=59 v=-0.029083:  122.02  -8.54  38.29  35.74 -24.75   2.19  [rand]  [f=40]
   o=60 v=-0.018760:  69.81 -16.27 -37.23  22.97  16.08  -3.59  [rand]  [f=33]
   o=61 v=-0.027637:  95.70 -14.89  33.59  24.68 -37.62 -25.78  [rand]  [f=55]
   o=62 v=-0.021869:  90.87  -7.14 -30.34  27.19   5.03   7.77  [grid]  [f=44]
   o=63 v=-0.016562:  93.04 -33.28 -38.26  19.24  27.71 -15.44  [rand]  [f=35]
   o=64 v=-0.017593:  53.52 -19.20  30.34  13.28 -18.83  16.03  [rand]  [f=60]
   o=65 v=-0.020603:  105.13 -39.25 -35.37  22.69  13.32 -21.57  [rand]  [f=50]
   o=66 v=-0.022279:  93.18   9.76 -30.87  -8.28  32.53  27.85  [grid]  [f=76]
   o=67 v=-0.023893:  102.80  20.21 -36.92   8.62 -14.85  40.53  [rand]  [f=50]
   o=68 v=-0.030230:  94.78  11.44 -41.70 -27.01  18.02 -15.08  [rand]  [f=53]
   o=69 v=-0.025604:  92.34   2.49  30.25  29.16 -28.24 -27.67  [grid]  [f=63]
   o=70 v=-0.028099:  84.44 -14.51 -37.03  -5.85  10.74   5.83  [rand]  [f=62]
   o=71 v=-0.024499:  117.76 -30.97 -33.13  30.69 -12.85  -3.72  [rand]  [f=61]
   o=72 v=-0.017104:  59.48 -35.24  36.02  15.19  -4.00  12.18  [rand]  [f=44]
   o=73 v=-0.020121:  78.49  34.05 -38.37  19.48  26.09  14.47  [rand]  [f=43]
   o=74 v=-0.027725:  66.37  14.95 -34.10  33.91  20.53 -10.37  [rand]  [f=70]
   o=75 v=-0.021457:  118.15 -34.24  32.27 -35.98 -26.19 -42.12  [rand]  [f=53]
   o=76 v=-0.033583:  84.74   5.08 -40.21  22.43  10.74   3.93  [rand]  [f=82]
   o=77 v=-0.022471:  66.16  19.67 -38.88  38.58   4.87  -0.04  [rand]  [f=62]
   o=78 v=-0.022165:  93.72  -7.71 -26.28  17.15   7.89   8.13  [grid]  [f=39]
   o=79 v=-0.019392:  56.80 -35.73  32.75  42.93 -41.01  35.05  [rand]  [f=40]
   o=80 v=-0.024286:  99.09 -41.34  36.23  14.84 -11.57 -20.31  [rand]  [f=40]
   o=81 v=-0.027989:  100.32  13.71 -36.07 -26.64   6.16  -4.67  [rand]  [f=61]
   o=82 v=-0.018578:  114.04 -25.07 -27.78  31.22   5.83   3.98  [grid]  [f=41]
   o=83 v=-0.020005:  108.98 -40.26  31.30 -22.78  -4.31 -16.42  [rand]  [f=52]
   o=84 v=-0.022922:  85.64 -10.65 -38.37   5.12  14.67  -7.14  [rand]  [f=60]
   o=85 v=-0.022479:  89.13 -11.37 -28.03  -5.87  37.76   7.84  [grid]  [f=59]
   o=86 v=-0.019822:  93.58  -9.73  28.66  -9.65 -11.27 -31.86  [grid]  [f=57]
   o=87 v=-0.031659:  80.56  10.85  31.85  39.61 -23.66 -12.54  [rand]  [f=68]
 + - saving # 0 for use with twobest
 + - saving #19 for use with twobest
 + - saving # 2 for use with twobest
 + - saving #27 for use with twobest
 + - saving #11 for use with twobest
 + - saving #21 for use with twobest
 + - saving #76 for use with twobest
 + - saving # 6 for use with twobest
 + - saving #87 for use with twobest
 + - saving #23 for use with twobest
 + - saving #68 for use with twobest
 + - saving #20 for use with twobest
 + - skip #16 for twobest: too close to set #23
 + - saving #26 for use with twobest
 + - saving #55 for use with twobest
 + - saving #13 for use with twobest
 + - saving #59 for use with twobest
 + - skip #48 for twobest: too close to set #16
 + - saving #33 for use with twobest
 + - saving #70 for use with twobest
 + - saving #81 for use with twobest
 + - saving #74 for use with twobest
 + - saving #61 for use with twobest
 + - saving #42 for use with twobest
 + - saving #15 for use with twobest
 + - saving #24 for use with twobest
 + - saving #12 for use with twobest
 + - saving # 8 for use with twobest
 + - skip #28 for twobest: too close to set # 8
 + - saving #43 for use with twobest
 + - saving # 3 for use with twobest
 + - saving #53 for use with twobest
 + - Coarse startup search net CPU time = 0.0 s
++ Start refinement #1 on 30 coarse parameter sets
 + * Enter alignment setup routine
 + - Smoothing base; radius=3.11
 + - Smoothing source; radius=3.11
 + !source mask fill: ubot=64 usiz=159.5
 + - retaining old weight image
 + - using 38906 points from base image [use_all=2]
 + * Exit alignment setup routine
 + 31909 total points stored in 63 'TOHD(17.3748)' bloks (0 duplicates)
*[#20978=-0.169331] *[#20986=-0.170313] *[#21000=-0.170526] *[#21001=-0.172023] *[#21005=-0.172274] *[#21008=-0.173681] *[#21009=-0.1739] *[#21013=-0.174339] *[#21016=-0.175108] *[#21017=-0.176175] *[#21018=-0.176452] *[#21019=-0.176809] *[#21021=-0.177261] *[#21024=-0.17761] *[#21026=-0.178186] *[#21027=-0.178833] *[#21028=-0.179343] *[#21031=-0.179472] *[#21040=-0.180395] *[#21043=-0.180428] *[#21045=-0.180429] *[#21047=-0.180514] *[#21048=-0.180599] *[#21049=-0.180672] *[#21051=-0.180752] *[#21052=-0.180786] *[#21053=-0.180808] *[#21054=-0.18082] *[#21055=-0.180832] *[#21056=-0.180858] *[#21057=-0.180864] *[#21059=-0.180909] *[#21060=-0.180915] *[#21061=-0.180934] *[#21062=-0.181065] *[#21063=-0.181087] *[#21064=-0.181114] *[#21065=-0.181253] *[#21068=-0.181324] *[#21069=-0.181432] *[#21070=-0.18147] *[#21073=-0.181504] *[#21074=-0.18155] *[#21075=-0.181565] 
 + - param set #1 has cost=-0.181565 [o=0 t=0]
 + -- Parameters = 86.2417 -3.0340 0.1839 -0.7927 0.0198 0.1572 0.9849 1.0186 0.9937 -0.0067 -0.0009 -0.0030
 + - param set #2 has cost=-0.029599 [o=19 t=1]
 + -- Parameters = 120.3747 31.4269 37.8606 31.0260 -11.8449 -1.1094 1.0067 0.9979 0.9877 -0.0009 0.0021 -0.0001
 + - param set #3 has cost=-0.032947 [o=2 t=2]
 + -- Parameters = 97.1422 -22.9068 36.7125 -10.4271 -42.0244 -25.8414 0.9953 0.9994 0.9958 -0.0016 0.0013 -0.0002
 + - param set #4 has cost=-0.025913 [o=27 t=3]
 + -- Parameters = 124.2213 -11.7386 37.9231 33.3757 -31.0928 -4.5253 1.0015 1.0012 0.9970 0.0002 0.0015 0.0004
 + - param set #5 has cost=-0.028112 [o=11 t=4]
 + -- Parameters = 122.3987 3.2658 37.8554 32.0364 -27.2812 -8.8197 0.9993 1.0000 0.9989 -0.0002 -0.0001 -0.0002
 + - param set #6 has cost=-0.027098 [o=21 t=5]
 + -- Parameters = 115.6655 30.6513 37.9152 27.7891 -10.1989 1.4674 0.9984 0.9912 0.9884 0.0004 -0.0012 0.0008
 + - param set #7 has cost=-0.025330 [o=76 t=6]
 + -- Parameters = 84.5296 4.8670 -40.1157 22.4018 10.4986 3.9660 1.0038 0.9999 1.0018 -0.0005 -0.0003 0.0016
 + - param set #8 has cost=-0.027671 [o=6 t=7]
 + -- Parameters = 124.4184 -28.3909 20.3705 5.2792 -41.8702 -44.1177 1.0047 0.9790 1.0062 -0.0035 -0.0002 -0.0054
 + - param set #9 has cost=-0.026880 [o=87 t=8]
 + -- Parameters = 80.6211 10.7956 31.8627 39.3826 -23.6462 -12.7049 0.9977 1.0051 0.9899 -0.0002 0.0006 -0.0006
 + - param set #10 has cost=-0.025438 [o=23 t=9]
 + -- Parameters = 88.5119 -12.3057 -34.5255 -12.2625 11.3388 4.8335 1.0036 0.9951 0.9911 0.0147 -0.0003 -0.0010
 + - param set #11 has cost=-0.025056 [o=68 t=10]
 + -- Parameters = 95.0321 11.2848 -41.6982 -27.1384 18.0539 -14.7625 0.9967 0.9975 1.0046 0.0010 -0.0017 -0.0002
 + - param set #12 has cost=-0.026301 [o=20 t=11]
 + -- Parameters = 99.7295 -29.7606 26.8107 -4.8322 -28.5727 -34.7626 1.0025 0.9939 1.0000 0.0001 -0.0010 0.0011
 + - param set #13 has cost=-0.024785 [o=26 t=12]
 + -- Parameters = 112.7484 -13.9672 -35.1899 -28.0512 24.1536 4.0959 0.9974 1.0021 1.0031 -0.0009 0.0004 -0.0004
 + - param set #14 has cost=-0.023818 [o=55 t=13]
 + -- Parameters = 102.3059 23.5118 -40.3609 -8.3749 -15.9182 41.1731 0.9987 1.0004 1.0059 0.0001 -0.0012 -0.0005
 + - param set #15 has cost=-0.025346 [o=13 t=14]
 + -- Parameters = 95.5049 -16.5664 34.3042 14.7561 -38.9196 -27.3528 1.0042 1.0061 0.9993 0.0005 -0.0002 -0.0014
 + - param set #16 has cost=-0.028890 [o=59 t=15]
 + -- Parameters = 121.0495 -8.3479 38.2577 35.4740 -28.4600 -2.1114 0.9475 0.9673 0.9742 0.0001 -0.0099 0.0125
 + - param set #17 has cost=-0.022857 [o=33 t=16]
 + -- Parameters = 111.2125 17.7604 -33.8452 -44.8026 10.9680 21.5318 0.9972 1.0001 1.0062 -0.0000 0.0110 -0.0001
 + - param set #18 has cost=-0.024121 [o=70 t=17]
 + -- Parameters = 84.6139 -14.8654 -35.5807 -6.2385 9.4374 4.5597 0.9971 1.0019 0.9957 -0.0008 0.0001 -0.0020
 + - param set #19 has cost=-0.026862 [o=81 t=18]
 + -- Parameters = 100.4019 15.0228 -35.6483 -31.5537 6.5158 -4.5506 0.9870 0.9952 0.9971 0.0007 0.0006 0.0008
 + - param set #20 has cost=-0.019718 [o=74 t=19]
 + -- Parameters = 66.3511 14.9204 -34.0041 33.9302 20.6377 -10.4785 0.9995 1.0003 0.9990 0.0002 -0.0001 -0.0002
 + - param set #21 has cost=-0.024596 [o=61 t=20]
 + -- Parameters = 94.9530 -15.7971 34.3648 21.1914 -38.2038 -26.5993 0.9967 1.0153 0.9925 0.0030 0.0004 -0.0029
 + - param set #22 has cost=-0.030211 [o=42 t=21]
 + -- Parameters = 125.4314 -20.5678 -30.0616 11.1232 -9.1532 7.8234 0.9842 0.9823 0.9478 -0.0144 -0.0209 0.0117
 + - param set #23 has cost=-0.022798 [o=15 t=22]
 + -- Parameters = 119.2795 0.0863 -39.9379 -13.8465 11.2937 -14.2121 0.9972 0.9982 1.0023 0.0015 -0.0005 -0.0005
 + - param set #24 has cost=-0.022617 [o=24 t=23]
 + -- Parameters = 119.5177 -7.0698 -37.4677 -10.8037 4.7487 -13.3916 1.0004 1.0044 0.9954 0.0003 -0.0039 -0.0012
 + - param set #25 has cost=-0.025054 [o=12 t=24]
 + -- Parameters = 90.2415 19.2854 31.2812 30.8214 -12.2280 -26.6292 0.9929 0.9856 0.9532 -0.0054 0.0058 -0.0182
 + - param set #26 has cost=-0.022589 [o=8 t=25]
 + -- Parameters = 92.2565 -0.3541 27.7222 -37.8739 16.7082 -34.1457 1.0015 0.9972 0.9965 0.0001 0.0001 -0.0009
 + - param set #27 has cost=-0.023658 [o=43 t=26]
 + -- Parameters = 67.8001 10.6026 -38.1869 20.2024 17.6918 -6.5006 0.9989 0.9962 0.9715 0.0005 -0.0034 0.0218
 + - param set #28 has cost=-0.023512 [o=3 t=27]
 + -- Parameters = 93.6271 -30.3348 25.2672 6.4093 -34.2989 -30.7456 1.0028 0.9979 1.0102 0.0018 0.0004 -0.0028
 + - param set #29 has cost=-0.022179 [o=53 t=28]
 + -- Parameters = 119.1053 -8.1075 -39.0073 -32.2735 24.1427 -0.5844 0.9994 1.0016 1.0011 -0.0012 0.0000 0.0001
*[#23803=-0.181994] *[#23804=-0.182059] *[#23808=-0.182443] *[#23813=-0.182802] *[#23817=-0.182824] *[#23821=-0.183125] 
 + - param set #30 has cost=-0.183125 [o=-1 t=-1]
 + -- Parameters = 86.2790 -2.9386 0.2322 -0.5467 -0.0139 0.1276 0.9790 1.0183 0.9889 0.0075 0.0058 -0.0075
 + - sorting parameter sets by cost
 + - scanning for distances from #1
 + --- dist(#2,#1) = 0.0636 
 + --- dist(#3,#1) = 0.467 
 + --- dist(#4,#1) = 0.489 
 + --- dist(#5,#1) = 0.47 
 + --- dist(#6,#1) = 0.475 
 + --- dist(#7,#1) = 0.47 
 + --- dist(#8,#1) = 0.492 
 + --- dist(#9,#1) = 0.471 
 + --- dist(#10,#1) = 0.444 
 + --- dist(#11,#1) = 0.449 
 + --- dist(#12,#1) = 0.388 
 + --- dist(#13,#1) = 0.474 
 + --- dist(#14,#1) = 0.434 
 + --- dist(#15,#1) = 0.432 
 + --- dist(#16,#1) = 0.504 
 + --- dist(#17,#1) = 0.524 
 + --- dist(#18,#1) = 0.388 
 + --- dist(#19,#1) = 0.443 
 + --- dist(#20,#1) = 0.427 
 + --- dist(#21,#1) = 0.448 
 + --- dist(#22,#1) = 0.507 
 + --- dist(#23,#1) = 0.48 
 + --- dist(#24,#1) = 0.381 
 + --- dist(#25,#1) = 0.492 
 + --- dist(#26,#1) = 0.502 
 + --- dist(#27,#1) = 0.471 
 + --- dist(#28,#1) = 0.415 
 + --- dist(#29,#1) = 0.49 
 + --- dist(#30,#1) = 0.428 
++ Start refinement #2 on 30 coarse parameter sets
 + * Enter alignment setup routine
 + - Smoothing base; radius=2.42
 + - Smoothing source; radius=2.42
 + !source mask fill: ubot=64 usiz=159.5
 + - retaining old weight image
 + - using 38906 points from base image [use_all=2]
 + * Exit alignment setup routine
 + 31999 total points stored in 64 'TOHD(17.2644)' bloks (0 duplicates)
*[#23823=-0.208583] *[#23853=-0.209083] *[#23856=-0.209692] *[#23857=-0.21004] *[#23858=-0.210473] *[#23859=-0.210652] *[#23861=-0.210912] *[#23862=-0.21108] *[#23863=-0.211096] *[#23864=-0.211318] *[#23865=-0.211465] *[#23868=-0.211558] *[#23871=-0.211598] *[#23874=-0.211605] *[#23876=-0.211804] *[#23880=-0.211892] *[#23883=-0.212487] *[#23884=-0.212638] *[#23887=-0.212807] *[#23889=-0.212858] *[#23890=-0.212946] *[#23891=-0.213045] *[#23892=-0.213054] *[#23893=-0.213085] *[#23896=-0.213618] *[#23897=-0.214048] *[#23898=-0.2143] *[#23899=-0.214697] *[#23902=-0.214782] *[#23904=-0.215131] *[#23907=-0.215508] *[#23908=-0.21602] *[#23909=-0.21655] *[#23910=-0.216938] *[#23911=-0.21729] *[#23912=-0.217316] *[#23913=-0.217499] *[#23914=-0.217762] *[#23915=-0.217858] *[#23920=-0.218401] *[#23921=-0.218462] *[#23922=-0.218657] *[#23925=-0.219463] *[#23926=-0.219544] *[#23927=-0.219959] *[#23928=-0.220151] *[#23931=-0.220227] 
 + - param set #1 has cost=-0.220227 [o=-1 t=-1]
 + -- Parameters = 86.5690 -3.1646 -0.1381 -0.8542 -1.9133 -0.7763 0.9848 1.0171 0.9535 -0.0108 0.0209 -0.0382
 + - param set #2 has cost=-0.216445 [o=0 t=0]
 + -- Parameters = 86.4148 -3.1639 -0.1179 -0.8652 -0.7590 -0.0405 0.9867 1.0242 0.9680 -0.0151 0.0021 -0.0159
 + - param set #3 has cost=-0.027810 [o=2 t=2]
 + -- Parameters = 97.2032 -22.9052 36.6921 -10.4554 -42.1013 -25.7685 0.9914 0.9972 0.9931 -0.0021 0.0004 0.0019
 + - param set #4 has cost=-0.030534 [o=42 t=21]
 + -- Parameters = 124.9320 -22.0031 -26.3056 8.7231 -2.9528 10.9929 0.9078 0.9429 0.9127 -0.0312 -0.0436 -0.0116
 + - param set #5 has cost=-0.024661 [o=19 t=1]
 + -- Parameters = 120.2512 31.5807 37.8833 31.4755 -11.7813 -0.9877 1.0280 0.9922 0.9858 -0.0015 0.0013 0.0011
 + - param set #6 has cost=-0.022586 [o=59 t=15]
 + -- Parameters = 121.0138 -8.5765 38.2813 35.5698 -28.5095 -2.1222 0.9444 0.9668 0.9787 0.0009 -0.0099 0.0127
 + - param set #7 has cost=-0.024438 [o=11 t=4]
 + -- Parameters = 122.3828 3.2625 37.8905 32.0936 -27.2969 -8.9957 0.9996 1.0008 0.9996 -0.0003 -0.0004 0.0002
 + - param set #8 has cost=-0.022973 [o=6 t=7]
 + -- Parameters = 124.5990 -28.5221 20.3574 5.1992 -41.4910 -44.5459 1.0133 0.9665 0.9986 -0.0044 -0.0021 -0.0082
 + - param set #9 has cost=-0.023141 [o=21 t=5]
 + -- Parameters = 115.3082 31.2509 37.9653 28.2268 -10.2700 2.1299 0.9881 0.9725 1.0137 0.0031 -0.0002 -0.0013
 + - param set #10 has cost=-0.020712 [o=87 t=8]
 + -- Parameters = 80.6871 10.7820 31.8608 39.2432 -23.8256 -12.8107 0.9960 1.0010 0.9862 0.0001 -0.0012 -0.0004
 + - param set #11 has cost=-0.023867 [o=81 t=18]
 + -- Parameters = 100.9144 15.5630 -35.5687 -30.9887 7.2817 -4.8546 0.9920 1.0234 0.9953 -0.0013 0.0007 -0.0033
 + - param set #12 has cost=-0.022773 [o=20 t=11]
 + -- Parameters = 99.3746 -29.8610 26.9858 -5.3618 -28.5046 -34.3145 1.0066 0.9859 1.0136 -0.0014 0.0000 0.0010
 + - param set #13 has cost=-0.021875 [o=27 t=3]
 + -- Parameters = 124.5604 -15.0908 37.9811 33.1165 -31.3178 -4.2711 1.0069 1.0029 0.9948 0.0004 0.0007 0.0018
 + - param set #14 has cost=-0.018972 [o=23 t=9]
 + -- Parameters = 88.7944 -12.1116 -34.5232 -12.0411 11.5798 4.8169 1.0017 0.9955 0.9899 0.0150 0.0007 -0.0000
 + - param set #15 has cost=-0.022093 [o=13 t=14]
 + -- Parameters = 94.6722 -16.0639 34.9181 15.7936 -38.3548 -28.1825 0.9908 0.9977 0.9904 -0.0019 -0.0004 -0.0028
 + - param set #16 has cost=-0.019604 [o=76 t=6]
 + -- Parameters = 84.2874 4.5998 -40.1267 21.8844 10.7009 4.2715 1.0055 0.9996 1.0026 -0.0011 -0.0010 0.0040
 + - param set #17 has cost=-0.018545 [o=68 t=10]
 + -- Parameters = 94.9844 11.4663 -41.6971 -27.1688 18.1245 -14.7945 0.9941 1.0035 1.0045 0.0090 -0.0015 -0.0008
 + - param set #18 has cost=-0.022035 [o=12 t=24]
 + -- Parameters = 90.4553 19.1335 31.0461 30.9460 -12.3561 -27.0333 0.9931 0.9841 0.9491 -0.0063 0.0070 -0.0183
 + - param set #19 has cost=-0.017809 [o=26 t=12]
 + -- Parameters = 112.7930 -14.0675 -34.9825 -28.0190 24.1066 3.9824 0.9955 1.0005 1.0055 -0.0008 0.0082 -0.0007
 + - param set #20 has cost=-0.022233 [o=61 t=20]
 + -- Parameters = 94.9835 -15.7922 34.2528 21.3591 -38.3023 -26.6743 0.9942 1.0155 0.9949 0.0025 0.0007 -0.0032
 + - param set #21 has cost=-0.021028 [o=70 t=17]
 + -- Parameters = 86.4718 -14.4547 -34.6323 -6.2583 9.6649 3.7010 0.9942 0.9844 0.9884 0.0090 0.0005 -0.0028
 + - param set #22 has cost=-0.017872 [o=55 t=13]
 + -- Parameters = 102.4708 23.5267 -40.2705 -8.5359 -16.0124 41.0981 1.0009 0.9972 1.0084 -0.0001 -0.0017 -0.0010
 + - param set #23 has cost=-0.017721 [o=43 t=26]
 + -- Parameters = 67.4275 10.6734 -38.2748 20.0915 17.9131 -6.3259 0.9971 0.9935 0.9725 0.0008 0.0052 0.0220
 + - param set #24 has cost=-0.020349 [o=3 t=27]
 + -- Parameters = 92.5580 -30.5120 25.0446 5.9667 -33.9224 -32.3783 0.9901 0.9827 0.9962 0.0134 0.0054 -0.0044
 + - param set #25 has cost=-0.018272 [o=33 t=16]
 + -- Parameters = 110.7879 17.5217 -34.1652 -44.9186 11.3923 22.6426 0.9815 0.9941 0.9763 -0.0011 0.0224 -0.0024
 + - param set #26 has cost=-0.016165 [o=15 t=22]
 + -- Parameters = 119.3371 0.1366 -40.0015 -13.9032 11.2916 -14.2405 0.9960 0.9969 1.0033 0.0023 -0.0007 -0.0005
 + - param set #27 has cost=-0.017790 [o=24 t=23]
 + -- Parameters = 119.5484 -7.0770 -37.5706 -10.9167 4.8044 -13.1528 1.0001 1.0034 0.9886 -0.0026 0.0023 -0.0026
 + - param set #28 has cost=-0.021054 [o=8 t=25]
 + -- Parameters = 92.1249 -0.7941 28.1167 -37.9315 16.4735 -34.0354 0.9818 0.9814 0.9791 -0.0018 -0.0013 -0.0009
 + - param set #29 has cost=-0.015293 [o=53 t=28]
 + -- Parameters = 119.0922 -8.1040 -38.9836 -32.2314 24.1018 -0.5725 1.0000 1.0027 1.0031 -0.0012 0.0001 0.0002
 + - param set #30 has cost=-0.014662 [o=74 t=19]
 + -- Parameters = 66.4003 14.9545 -34.0002 33.9259 20.6687 -10.5010 0.9998 1.0006 0.9992 0.0001 -0.0000 0.0007
 + - sorting parameter sets by cost
 + - scanning for distances from #1
 + --- dist(#2,#1) = 0.1 
 + --- dist(#3,#1) = 0.48 
 + --- dist(#4,#1) = 0.46 
 + --- dist(#5,#1) = 0.475 
 + --- dist(#6,#1) = 0.475 
 + --- dist(#7,#1) = 0.443 
 + --- dist(#8,#1) = 0.476 
 + --- dist(#9,#1) = 0.486 
 + --- dist(#10,#1) = 0.373 
 + --- dist(#11,#1) = 0.48 
 + --- dist(#12,#1) = 0.43 
 + --- dist(#13,#1) = 0.438 
 + --- dist(#14,#1) = 0.39 
 + --- dist(#15,#1) = 0.476 
 + --- dist(#16,#1) = 0.412 
 + --- dist(#17,#1) = 0.431 
 + --- dist(#18,#1) = 0.446 
 + --- dist(#19,#1) = 0.356 
 + --- dist(#20,#1) = 0.5 
 + --- dist(#21,#1) = 0.43 
 + --- dist(#22,#1) = 0.519 
 + --- dist(#23,#1) = 0.49 
 + --- dist(#24,#1) = 0.502 
 + --- dist(#25,#1) = 0.436 
 + --- dist(#26,#1) = 0.468 
 + --- dist(#27,#1) = 0.477 
 + --- dist(#28,#1) = 0.498 
 + --- dist(#29,#1) = 0.486 
 + --- dist(#30,#1) = 0.423 
++ Start refinement #3 on 30 coarse parameter sets
 + * Enter alignment setup routine
 + - Smoothing base; radius=1.88
 + - Smoothing source; radius=1.88
 + !source mask fill: ubot=64 usiz=159.5
 + - retaining old weight image
 + - using 38906 points from base image [use_all=2]
 + * Exit alignment setup routine
 + 32677 total points stored in 67 'TOHD(17.1973)' bloks (0 duplicates)
*[#26935=-0.23117] *[#26944=-0.232084] *[#26959=-0.2323] *[#26962=-0.232318] *[#26964=-0.232417] *[#26965=-0.232543] *[#26966=-0.232579] *[#26967=-0.232897] *[#26968=-0.233239] *[#26970=-0.233374] *[#26971=-0.233673] *[#26972=-0.233862] *[#26973=-0.234107] *[#26976=-0.234183] *[#26979=-0.234351] *[#26982=-0.234738] *[#26989=-0.234754] *[#26991=-0.234778] *[#26993=-0.234835] *[#26994=-0.234875] *[#26995=-0.23489] *[#26998=-0.234922] *[#27003=-0.234952] *[#27008=-0.23499] *[#27022=-0.235079] *[#27024=-0.235114] *[#27025=-0.235125] *[#27026=-0.235141] *[#27029=-0.235189] *[#27030=-0.235209] *[#27033=-0.235232] *[#27034=-0.235249] *[#27037=-0.235325] *[#27038=-0.235358] *[#27039=-0.235442] *[#27044=-0.235475] *[#27045=-0.235495] *[#27046=-0.235521] *[#27047=-0.235525] *[#27049=-0.235599] *[#27050=-0.235614] *[#27052=-0.235647] *[#27054=-0.235672] 
 + - param set #1 has cost=-0.235672 [o=-1 t=-1]
 + -- Parameters = 86.4793 -3.3380 0.0217 -0.7549 -2.1405 -0.4338 0.9891 1.0267 0.9753 -0.0112 0.0131 -0.0443
 + - param set #2 has cost=-0.234666 [o=0 t=0]
 + -- Parameters = 86.4372 -3.2322 -0.0269 -0.6424 -1.6709 -0.2772 0.9885 1.0248 0.9691 -0.0071 0.0076 -0.0358
 + - param set #3 has cost=-0.025822 [o=42 t=21]
 + -- Parameters = 124.8635 -21.9185 -26.3384 8.9122 -2.8957 11.2486 0.9066 0.9500 0.9146 -0.0262 -0.0428 -0.0111
 + - param set #4 has cost=-0.024015 [o=2 t=2]
 + -- Parameters = 96.9853 -22.6084 36.5331 -10.5646 -42.3502 -25.8919 0.9936 0.9938 0.9909 -0.0015 0.0015 0.0018
 + - param set #5 has cost=-0.020677 [o=19 t=1]
 + -- Parameters = 120.2836 31.7782 37.8573 31.4903 -11.7839 -1.0432 1.0280 0.9925 0.9857 -0.0018 0.0016 0.0008
 + - param set #6 has cost=-0.021109 [o=11 t=4]
 + -- Parameters = 122.3854 3.2395 37.8890 32.1032 -27.2846 -8.9726 0.9996 1.0025 0.9997 -0.0002 -0.0004 0.0002
 + - param set #7 has cost=-0.021742 [o=81 t=18]
 + -- Parameters = 100.8685 15.8940 -35.1960 -31.0087 7.4956 -4.8791 0.9890 1.0230 0.9984 -0.0014 0.0064 -0.0026
 + - param set #8 has cost=-0.019976 [o=21 t=5]
 + -- Parameters = 115.3360 31.3654 37.9305 28.3074 -10.2193 2.1137 0.9882 0.9720 1.0138 0.0030 0.0001 -0.0012
 + - param set #9 has cost=-0.019055 [o=6 t=7]
 + -- Parameters = 124.6007 -28.5691 20.2957 5.1816 -41.5171 -44.5870 1.0131 0.9665 0.9992 -0.0041 -0.0017 -0.0082
 + - param set #10 has cost=-0.019574 [o=20 t=11]
 + -- Parameters = 99.3866 -29.8615 26.9020 -5.3338 -28.4230 -34.3867 1.0113 0.9855 1.0194 -0.0030 -0.0004 0.0010
 + - param set #11 has cost=-0.019180 [o=59 t=15]
 + -- Parameters = 120.9740 -8.5507 38.2855 35.6054 -28.5926 -2.1032 0.9445 0.9658 0.9799 0.0065 -0.0097 0.0127
 + - param set #12 has cost=-0.018566 [o=61 t=20]
 + -- Parameters = 95.1214 -16.0331 34.2759 18.9140 -38.5791 -27.1663 0.9916 1.0140 0.9960 0.0012 0.0011 -0.0035
 + - param set #13 has cost=-0.018186 [o=13 t=14]
 + -- Parameters = 94.6948 -15.8655 35.0391 15.9754 -38.3484 -28.1206 0.9895 1.0072 0.9927 -0.0019 0.0009 -0.0027
 + - param set #14 has cost=-0.018618 [o=12 t=24]
 + -- Parameters = 90.7229 19.1250 31.4046 30.8607 -12.3845 -26.7735 0.9996 0.9886 0.9229 -0.0090 0.0068 -0.0166
 + - param set #15 has cost=-0.018967 [o=27 t=3]
 + -- Parameters = 124.5882 -14.9891 37.9295 33.0540 -31.2298 -4.2381 1.0065 1.0007 0.9931 -0.0009 0.0053 0.0016
 + - param set #16 has cost=-0.017468 [o=8 t=25]
 + -- Parameters = 92.1824 -0.8246 28.2401 -37.9242 16.3884 -33.9570 0.9830 0.9798 0.9728 -0.0014 -0.0014 -0.0006
 + - param set #17 has cost=-0.018075 [o=70 t=17]
 + -- Parameters = 86.9585 -14.1999 -34.6419 -5.8658 10.1152 3.4199 0.9923 0.9807 0.9588 0.0087 0.0037 -0.0025
 + - param set #18 has cost=-0.016481 [o=87 t=8]
 + -- Parameters = 80.8196 10.8792 31.9415 39.1021 -23.3509 -12.5253 0.9963 0.9912 0.9875 -0.0009 -0.0018 0.0008
 + - param set #19 has cost=-0.017711 [o=3 t=27]
 + -- Parameters = 92.2159 -30.5634 24.8590 5.7157 -33.5922 -32.8620 0.9876 0.9841 0.9895 0.0194 0.0052 -0.0038
 + - param set #20 has cost=-0.021740 [o=76 t=6]
 + -- Parameters = 83.8861 4.6151 -39.5617 21.7046 10.7784 4.3335 1.0048 1.0034 1.0216 -0.0014 -0.0017 0.0062
 + - param set #21 has cost=-0.015678 [o=23 t=9]
 + -- Parameters = 88.9620 -11.8477 -34.5045 -12.1120 11.6847 4.7198 0.9995 0.9920 0.9895 0.0145 0.0006 -0.0002
 + - param set #22 has cost=-0.016589 [o=68 t=10]
 + -- Parameters = 94.9995 11.4811 -41.7072 -27.1686 18.0982 -14.7609 0.9953 1.0045 1.0033 0.0090 -0.0015 -0.0005
 + - param set #23 has cost=-0.016828 [o=33 t=16]
 + -- Parameters = 110.5268 17.5289 -34.6249 -44.8163 11.5456 22.9792 0.9797 1.0014 0.9661 -0.0008 0.0213 0.0032
 + - param set #24 has cost=-0.016103 [o=55 t=13]
 + -- Parameters = 101.9900 23.5558 -40.5738 -5.7638 -15.8114 40.9105 1.0031 0.9992 1.0094 0.0007 -0.0004 -0.0003
 + - param set #25 has cost=-0.014262 [o=26 t=12]
 + -- Parameters = 112.7557 -14.0757 -34.9144 -28.0999 24.1661 4.0230 0.9951 1.0018 1.0066 0.0048 0.0082 -0.0003
 + - param set #26 has cost=-0.012861 [o=24 t=23]
 + -- Parameters = 119.4894 -7.0076 -37.7482 -11.0534 5.0314 -12.8294 0.9963 1.0036 0.9832 -0.0072 0.0027 -0.0031
 + - param set #27 has cost=-0.017379 [o=43 t=26]
 + -- Parameters = 66.9122 8.7775 -38.5261 20.0114 18.3468 -6.1556 0.9969 0.9943 0.9711 0.0009 0.0066 0.0213
 + - param set #28 has cost=-0.012238 [o=15 t=22]
 + -- Parameters = 119.3286 0.1633 -40.0271 -13.9141 11.3075 -14.2199 0.9960 0.9968 1.0031 0.0023 -0.0007 -0.0006
 + - param set #29 has cost=-0.013300 [o=53 t=28]
 + -- Parameters = 118.9961 -8.2432 -38.8829 -34.5285 24.2673 -0.6308 1.0005 1.0040 1.0051 -0.0013 0.0007 0.0002
 + - param set #30 has cost=-0.012264 [o=74 t=19]
 + -- Parameters = 66.4348 14.9373 -34.0290 33.9352 20.6722 -10.4953 0.9986 1.0022 0.9993 0.0001 0.0001 0.0009
 + - sorting parameter sets by cost
 + - scanning for distances from #1
 + --- dist(#2,#1) = 0.0383 
 + --- dist(#3,#1) = 0.48 
 + --- dist(#4,#1) = 0.456 
 + --- dist(#5,#1) = 0.44 
 + --- dist(#6,#1) = 0.495 
 + --- dist(#7,#1) = 0.473 
 + --- dist(#8,#1) = 0.473 
 + --- dist(#9,#1) = 0.474 
 + --- dist(#10,#1) = 0.377 
 + --- dist(#11,#1) = 0.478 
 + --- dist(#12,#1) = 0.491 
 + --- dist(#13,#1) = 0.476 
 + --- dist(#14,#1) = 0.392 
 + --- dist(#15,#1) = 0.428 
 + --- dist(#16,#1) = 0.438 
 + --- dist(#17,#1) = 0.433 
 + --- dist(#18,#1) = 0.36 
 + --- dist(#19,#1) = 0.413 
 + --- dist(#20,#1) = 0.482 
 + --- dist(#21,#1) = 0.49 
 + --- dist(#22,#1) = 0.522 
 + --- dist(#23,#1) = 0.443 
 + --- dist(#24,#1) = 0.507 
 + --- dist(#25,#1) = 0.432 
 + --- dist(#26,#1) = 0.437 
 + --- dist(#27,#1) = 0.486 
 + --- dist(#28,#1) = 0.472 
 + --- dist(#29,#1) = 0.426 
 + --- dist(#30,#1) = 0.501 
 + - Total coarse refinement net CPU time = 0.0 s; 9153 funcs
++ *** Fine pass begins ***
 + * Enter alignment setup routine
 + - Smoothing base; radius=1.00
 + - Smoothing source; radius=1.00
 + !source mask fill: ubot=64 usiz=159.5
 + - retaining old weight image
 + * Exit alignment setup routine
++ Picking best parameter set out of 31 cases
 + 32726 total points stored in 68 'TOHD(17.1233)' bloks (0 duplicates)
 + - cost(#1)=-0.229302 * [o=-1 t=-1]
 + -- Parameters = 86.4793 -3.3380 0.0217 -0.7549 -2.1405 -0.4338 0.9891 1.0267 0.9753 -0.0112 0.0131 -0.0443
 + - cost(#2)=-0.228654   [o=0 t=0]
 + -- Parameters = 86.4372 -3.2322 -0.0269 -0.6424 -1.6709 -0.2772 0.9885 1.0248 0.9691 -0.0071 0.0076 -0.0358
 + - cost(#3)=-0.020796   [o=42 t=21]
 + -- Parameters = 124.8635 -21.9185 -26.3384 8.9122 -2.8957 11.2486 0.9066 0.9500 0.9146 -0.0262 -0.0428 -0.0111
 + - cost(#4)=-0.021017   [o=2 t=2]
 + -- Parameters = 96.9853 -22.6084 36.5331 -10.5646 -42.3502 -25.8919 0.9936 0.9938 0.9909 -0.0015 0.0015 0.0018
 + - cost(#5)=-0.019426   [o=81 t=18]
 + -- Parameters = 100.8685 15.8940 -35.1960 -31.0087 7.4956 -4.8791 0.9890 1.0230 0.9984 -0.0014 0.0064 -0.0026
 + - cost(#6)=-0.019844   [o=76 t=6]
 + -- Parameters = 83.8861 4.6151 -39.5617 21.7046 10.7784 4.3335 1.0048 1.0034 1.0216 -0.0014 -0.0017 0.0062
 + - cost(#7)=-0.018617   [o=11 t=4]
 + -- Parameters = 122.3854 3.2395 37.8890 32.1032 -27.2846 -8.9726 0.9996 1.0025 0.9997 -0.0002 -0.0004 0.0002
 + - cost(#8)=-0.016587   [o=19 t=1]
 + -- Parameters = 120.2836 31.7782 37.8573 31.4903 -11.7839 -1.0432 1.0280 0.9925 0.9857 -0.0018 0.0016 0.0008
 + - cost(#9)=-0.017151   [o=21 t=5]
 + -- Parameters = 115.3360 31.3654 37.9305 28.3074 -10.2193 2.1137 0.9882 0.9720 1.0138 0.0030 0.0001 -0.0012
 + - cost(#10)=-0.018519   [o=20 t=11]
 + -- Parameters = 99.3866 -29.8615 26.9020 -5.3338 -28.4230 -34.3867 1.0113 0.9855 1.0194 -0.0030 -0.0004 0.0010
 + - cost(#11)=-0.016436   [o=59 t=15]
 + -- Parameters = 120.9740 -8.5507 38.2855 35.6054 -28.5926 -2.1032 0.9445 0.9658 0.9799 0.0065 -0.0097 0.0127
 + - cost(#12)=-0.016901   [o=6 t=7]
 + -- Parameters = 124.6007 -28.5691 20.2957 5.1816 -41.5171 -44.5870 1.0131 0.9665 0.9992 -0.0041 -0.0017 -0.0082
 + - cost(#13)=-0.016877   [o=27 t=3]
 + -- Parameters = 124.5882 -14.9891 37.9295 33.0540 -31.2298 -4.2381 1.0065 1.0007 0.9931 -0.0009 0.0053 0.0016
 + - cost(#14)=-0.016763   [o=12 t=24]
 + -- Parameters = 90.7229 19.1250 31.4046 30.8607 -12.3845 -26.7735 0.9996 0.9886 0.9229 -0.0090 0.0068 -0.0166
 + - cost(#15)=-0.016364   [o=61 t=20]
 + -- Parameters = 95.1214 -16.0331 34.2759 18.9140 -38.5791 -27.1663 0.9916 1.0140 0.9960 0.0012 0.0011 -0.0035
 + - cost(#16)=-0.015450   [o=13 t=14]
 + -- Parameters = 94.6948 -15.8655 35.0391 15.9754 -38.3484 -28.1206 0.9895 1.0072 0.9927 -0.0019 0.0009 -0.0027
 + - cost(#17)=-0.016063   [o=70 t=17]
 + -- Parameters = 86.9585 -14.1999 -34.6419 -5.8658 10.1152 3.4199 0.9923 0.9807 0.9588 0.0087 0.0037 -0.0025
 + - cost(#18)=-0.015527   [o=3 t=27]
 + -- Parameters = 92.2159 -30.5634 24.8590 5.7157 -33.5922 -32.8620 0.9876 0.9841 0.9895 0.0194 0.0052 -0.0038
 + - cost(#19)=-0.015525   [o=8 t=25]
 + -- Parameters = 92.1824 -0.8246 28.2401 -37.9242 16.3884 -33.9570 0.9830 0.9798 0.9728 -0.0014 -0.0014 -0.0006
 + - cost(#20)=-0.016496   [o=43 t=26]
 + -- Parameters = 66.9122 8.7775 -38.5261 20.0114 18.3468 -6.1556 0.9969 0.9943 0.9711 0.0009 0.0066 0.0213
 + - cost(#21)=-0.014669   [o=33 t=16]
 + -- Parameters = 110.5268 17.5289 -34.6249 -44.8163 11.5456 22.9792 0.9797 1.0014 0.9661 -0.0008 0.0213 0.0032
 + - cost(#22)=-0.015020   [o=68 t=10]
 + -- Parameters = 94.9995 11.4811 -41.7072 -27.1686 18.0982 -14.7609 0.9953 1.0045 1.0033 0.0090 -0.0015 -0.0005
 + - cost(#23)=-0.014942   [o=87 t=8]
 + -- Parameters = 80.8196 10.8792 31.9415 39.1021 -23.3509 -12.5253 0.9963 0.9912 0.9875 -0.0009 -0.0018 0.0008
 + - cost(#24)=-0.014574   [o=55 t=13]
 + -- Parameters = 101.9900 23.5558 -40.5738 -5.7638 -15.8114 40.9105 1.0031 0.9992 1.0094 0.0007 -0.0004 -0.0003
 + - cost(#25)=-0.014193   [o=23 t=9]
 + -- Parameters = 88.9620 -11.8477 -34.5045 -12.1120 11.6847 4.7198 0.9995 0.9920 0.9895 0.0145 0.0006 -0.0002
 + - cost(#26)=-0.012148   [o=26 t=12]
 + -- Parameters = 112.7557 -14.0757 -34.9144 -28.0999 24.1661 4.0230 0.9951 1.0018 1.0066 0.0048 0.0082 -0.0003
 + - cost(#27)=-0.012000   [o=53 t=28]
 + -- Parameters = 118.9961 -8.2432 -38.8829 -34.5285 24.2673 -0.6308 1.0005 1.0040 1.0051 -0.0013 0.0007 0.0002
 + - cost(#28)=-0.011452   [o=24 t=23]
 + -- Parameters = 119.4894 -7.0076 -37.7482 -11.0534 5.0314 -12.8294 0.9963 1.0036 0.9832 -0.0072 0.0027 -0.0031
 + - cost(#29)=-0.011364   [o=74 t=19]
 + -- Parameters = 66.4348 14.9373 -34.0290 33.9352 20.6722 -10.4953 0.9986 1.0022 0.9993 0.0001 0.0001 0.0009
 + - cost(#30)=-0.010783   [o=15 t=22]
 + -- Parameters = 119.3286 0.1633 -40.0271 -13.9141 11.3075 -14.2199 0.9960 0.9968 1.0031 0.0023 -0.0007 -0.0006
 + - cost(#31)=-0.129342   [o=-2 t=-2]
 + -- Parameters = 86.1901 -3.4407 -1.7088 0.0000 0.0000 0.0000 1.0000 1.0000 1.0000 0.0000 0.0000 0.0000
 + -num_rtb 99 ==> refine all 31 cases
 + - cost(#1)=-0.229705 * [o=-1 t=-1]
 + -- Parameters = 86.4786 -3.3794 0.0456 -0.7344 -2.0985 -0.4671 0.9912 1.0266 0.9763 -0.0110 0.0121 -0.0449
 + - cost(#2)=-0.229554   [o=0 t=0]
 + -- Parameters = 86.4108 -3.3549 0.0075 -0.6847 -1.9108 -0.2988 0.9897 1.0254 0.9729 -0.0093 0.0067 -0.0411
 + - cost(#3)=-0.020800   [o=42 t=21]
 + -- Parameters = 124.8687 -21.9275 -26.3385 8.9060 -2.8977 11.2572 0.9066 0.9499 0.9145 -0.0261 -0.0428 -0.0111
 + - cost(#4)=-0.021932   [o=2 t=2]
 + -- Parameters = 96.7132 -21.8547 37.0594 -11.0616 -41.9192 -26.4843 0.9931 0.9931 0.9950 -0.0013 0.0013 0.0069
 + - cost(#5)=-0.019536   [o=81 t=18]
 + -- Parameters = 100.8433 15.8919 -35.1646 -30.9880 7.4855 -4.8544 0.9870 1.0216 0.9993 -0.0015 0.0070 -0.0025
 + - cost(#6)=-0.021827   [o=76 t=6]
 + -- Parameters = 82.3364 4.8772 -39.6003 20.1755 10.4514 3.8632 1.0049 1.0059 1.0260 -0.0085 -0.0025 0.0079
 + - cost(#7)=-0.019391   [o=11 t=4]
 + -- Parameters = 122.1885 3.3850 37.7804 31.9993 -26.7764 -9.1048 1.0047 1.0043 1.0237 -0.0004 -0.0009 0.0010
 + - cost(#8)=-0.016887   [o=19 t=1]
 + -- Parameters = 120.3862 31.8744 37.9044 31.2181 -11.7938 -1.2006 1.0284 0.9884 0.9874 -0.0101 0.0025 0.0006
 + - cost(#9)=-0.017390   [o=21 t=5]
 + -- Parameters = 115.3469 31.2859 37.8570 28.2962 -10.3465 2.2030 0.9873 0.9648 1.0135 0.0016 0.0010 -0.0018
 + - cost(#10)=-0.018693   [o=20 t=11]
 + -- Parameters = 99.3262 -29.9447 26.9371 -5.3159 -28.4886 -34.0726 1.0107 0.9849 1.0213 -0.0036 -0.0003 0.0007
 + - cost(#11)=-0.016689   [o=59 t=15]
 + -- Parameters = 120.8994 -8.5654 38.2884 35.5660 -28.3844 -2.2898 0.9449 0.9652 0.9808 0.0065 -0.0097 0.0202
 + - cost(#12)=-0.017087   [o=6 t=7]
 + -- Parameters = 124.5712 -28.6409 20.3221 5.1349 -41.6487 -44.5124 1.0125 0.9652 0.9978 -0.0043 -0.0015 -0.0151
 + - cost(#13)=-0.018747   [o=27 t=3]
 + -- Parameters = 124.8220 -15.4132 35.7434 32.8513 -32.2128 -4.2913 1.0051 1.0020 0.9925 -0.0014 0.0061 0.0027
 + - cost(#14)=-0.016958   [o=12 t=24]
 + -- Parameters = 90.6424 19.0892 31.4461 30.8611 -12.4391 -26.9602 1.0001 0.9900 0.9213 -0.0096 0.0069 -0.0164
 + - cost(#15)=-0.016621   [o=61 t=20]
 + -- Parameters = 95.2265 -16.0288 34.3051 18.8769 -38.6949 -27.3742 0.9949 1.0116 0.9938 0.0095 0.0005 -0.0030
 + - cost(#16)=-0.015480   [o=13 t=14]
 + -- Parameters = 94.6942 -15.8722 35.0063 16.0018 -38.3548 -28.1013 0.9892 1.0073 0.9938 -0.0018 0.0006 -0.0023
 + - cost(#17)=-0.017580   [o=70 t=17]
 + -- Parameters = 87.0306 -14.2621 -34.6583 -9.0179 9.8610 3.8227 0.9879 0.9809 0.9564 0.0087 0.0030 -0.0024
 + - cost(#18)=-0.016272   [o=3 t=27]
 + -- Parameters = 92.1936 -30.6225 24.8890 5.7653 -33.6379 -32.8354 0.9906 0.9904 0.9919 0.0296 0.0046 -0.0038
 + - cost(#19)=-0.018831   [o=8 t=25]
 + -- Parameters = 92.0665 -2.7610 29.1632 -37.9380 15.4778 -34.5080 0.9731 0.9648 0.9439 -0.0023 -0.0035 0.0016
 + - cost(#20)=-0.016643   [o=43 t=26]
 + -- Parameters = 66.9145 8.7317 -38.5499 19.9377 18.3452 -6.1108 1.0030 0.9976 0.9713 0.0006 0.0051 0.0221
 + - cost(#21)=-0.015076   [o=33 t=16]
 + -- Parameters = 110.5064 17.5324 -34.6949 -44.8090 11.7870 22.7514 0.9787 1.0007 0.9652 -0.0008 0.0293 0.0042
 + - cost(#22)=-0.015064   [o=68 t=10]
 + -- Parameters = 94.9821 11.4850 -41.7087 -27.1684 18.0621 -14.7438 0.9953 1.0047 1.0033 0.0097 -0.0014 -0.0005
 + - cost(#23)=-0.015215   [o=87 t=8]
 + -- Parameters = 80.8903 10.8767 31.8345 38.9750 -23.2805 -12.6024 0.9964 0.9868 0.9912 -0.0075 -0.0002 0.0015
 + - cost(#24)=-0.014807   [o=55 t=13]
 + -- Parameters = 101.9003 23.5725 -40.5280 -5.6755 -15.6652 40.9313 1.0032 0.9991 1.0112 0.0085 -0.0004 -0.0001
 + - cost(#25)=-0.014391   [o=23 t=9]
 + -- Parameters = 88.9471 -11.7913 -34.3018 -12.1401 11.8714 4.7590 1.0001 0.9921 0.9903 0.0145 0.0001 -0.0000
 + - cost(#26)=-0.012283   [o=26 t=12]
 + -- Parameters = 112.7510 -14.0798 -34.9248 -28.0911 24.1450 4.0337 0.9952 1.0025 1.0059 0.0123 0.0083 -0.0004
 + - cost(#27)=-0.012050   [o=53 t=28]
 + -- Parameters = 119.0245 -8.2729 -38.8807 -34.4827 24.2436 -0.6653 1.0003 1.0042 1.0074 -0.0013 0.0015 0.0001
 + - cost(#28)=-0.011891   [o=24 t=23]
 + -- Parameters = 119.1164 -6.9467 -37.4876 -11.0812 5.1131 -12.3826 0.9973 1.0034 0.9823 -0.0065 0.0021 -0.0026
 + - cost(#29)=-0.011366   [o=74 t=19]
 + -- Parameters = 66.4278 14.9361 -34.0231 33.9244 20.6755 -10.4931 0.9986 1.0021 0.9994 0.0001 0.0002 0.0008
 + - cost(#30)=-0.012654   [o=15 t=22]
 + -- Parameters = 118.6806 -0.2779 -39.9209 -10.4236 10.9901 -14.6070 0.9859 0.9982 1.0056 0.0036 -0.0026 0.0003
 + - cost(#31)=-0.226142   [o=-2 t=-2]
 + -- Parameters = 86.2853 -3.2417 0.0041 -0.6043 -1.3783 0.2327 0.9846 1.0247 0.9738 -0.0073 -0.0072 -0.0283
 + - case #1 [o=-1 t=-1] is now the best
 + - Initial  cost = -0.229705
 + - Initial fine Parameters = 86.4786 -3.3794 0.0456 -0.7344 -2.0985 -0.4671 0.9912 1.0266 0.9763 -0.0110 0.0121 -0.0449
 + - Finalish cost = -0.230087 ; 443 funcs
 + - ini Finalish Parameters = 86.4243 -3.3934 0.0579 -0.6907 -2.4008 -0.2686 0.9907 1.0261 0.9755 -0.0090 0.0076 -0.0512
 + - Final    cost = -0.230087 ; 283 funcs
 + Final fine fit Parameters:
       x-shift= 86.4239   y-shift= -3.3912   z-shift=  0.0590  ...  enorm= 86.4904 mm
       z-angle= -0.6917   x-angle= -2.3988   y-angle= -0.2681  ...  total=  2.5094 deg
       x-scale=  0.9907   y-scale=  1.0261   z-scale=  0.9755  ...  vol3D=  0.9917 = base bigger than source
     y/x-shear= -0.0090 z/x-shear=  0.0076 z/y-shear= -0.0512
 + - Fine net CPU time = 0.0 s
++ Computing output image
++ image warp: parameters = 86.4239 -3.3912 0.0590 -0.6917 -2.3988 -0.2681 0.9907 1.0261 0.9755 -0.0090 0.0076 -0.0512
++ Unloading unneeded data
++ Output dataset ./sub-08_T1w_al_junk+orig.BRIK
++ Wrote -1Dmatrix_save ./sub-08_T1w_al_junk_mat.aff12.1D
++ 3dAllineate: total CPU time = 0.0 sec  Elapsed = 17.0
++ ###########################################################
++ #   PLEASE check results VISUALLY for alignment quality   #
++ ###########################################################
#++ Creating final output: skullstripped anat data
copying from dataset /home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/afni_pro_glm/sub_08.results/__tt_sub-08_T1w_ns+orig to /home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/afni_pro_glm/sub_08.results/sub-08_T1w_ns+orig
#Script is running (command trimmed):
  3dcopy ./__tt_sub-08_T1w_ns+orig sub-08_T1w_ns
++ 3dcopy: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
#++ Creating final output: anat data aligned to epi
# copy is not necessary
#++ Saving history
#Script is running (command trimmed):
  3dNotes -h "align_epi_anat.py -anat2epi -anat sub-08_T1w+orig \
 -save_skullstrip -suffix _al_junk -epi vr_base_min_outlier+orig -epi_base \
 0 -epi_strip 3dAutomask -giant_move -volreg off -tshift off" \
 ./sub-08_T1w_al_junk+orig

#++ Removing all the temporary files
#Script is running:
  \rm -f ./__tt_vr_base_min_outlier*
#Script is running:
  \rm -f ./__tt_sub-08_T1w*
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \

# Finished alignment successfully

@auto_tlrc -base MNI_avg152T1+tlrc -input sub-08_T1w_ns+orig -no_ss -init_xform AUTO_CENTER

Performing center alignment with @Align_Centers

++ 3dcopy: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ 3drefit: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
++ Processing AFNI dataset ./sub-08_T1w_ns_shft+orig
 + deoblique
++ 3drefit processed 1 datasets
++ 3drename: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ THD_rename_dataset_files: rename sub-08_T1w_ns_shft+orig.HEAD -> __ats_tmp__sub-08_T1w_ns_shft+orig.HEAD
++ THD_rename_dataset_files: rename sub-08_T1w_ns_shft+orig.BRIK -> __ats_tmp__sub-08_T1w_ns_shft+orig.BRIK
** THD_rename_dataset_files: old header sub-08_T1w_ns_shft+acpc.HEAD doesn't exist!
** THD_rename_dataset_files: old header sub-08_T1w_ns_shft+tlrc.HEAD doesn't exist!
++ 3dWarp: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
Center distance of 0.000000 mm
Padding ...
++ 3dZeropad: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ output dataset: ./__ats_tmp__ref_MNI_avg152T1_15pad+tlrc.BRIK
Resampling ...
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ././__ats_tmp__resamp_step+orig.BRIK
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ././__ats_tmp__resamp+tlrc.BRIK
Clipping -0.000100 1336.000100 ...
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./__ats_tmp___rs_pre.sub-08_T1w_ns+tlrc.BRIK
++ 3drefit: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
++ Processing AFNI dataset __ats_tmp___rs_pre.sub-08_T1w_ns+tlrc.HEAD
 + changing dataset view code
 + Changed dataset view type and filenames.
++ 3drefit processed 1 datasets
++ 3drefit: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
++ Processing AFNI dataset __ats_tmp__resamp_NN+tlrc.HEAD
 + changing dataset view code
 + Changed dataset view type and filenames.
++ 3drefit processed 1 datasets
++ 3drefit: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
++ Processing AFNI dataset __ats_tmp__resamp_edge_art+tlrc.HEAD
 + changing dataset view code
 + Changed dataset view type and filenames.
++ 3drefit processed 1 datasets
Registration (cubic final interpolation) ...
++ 3dWarpDrive: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
++ Initial scale factor set to 0.30/125.00=4.2e+02
RMS[0] = 0.283712 0.155217   ITER = 8/50
0.283712

Warping has converged.

++ 3dcopy: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ 3dWarp: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
Applying brain mask
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ././__ats_tmp__reg_braintlrcstep+orig.BRIK
++ 3dWarp: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
++ 3drename: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ THD_rename_dataset_files: rename __ats_tmp___pad15_pre.sub-08_T1w_ns+orig.HEAD -> __ats_tmp___pad15_pre.sub-08_T1w_ns.skl+orig.HEAD
++ THD_rename_dataset_files: rename __ats_tmp___pad15_pre.sub-08_T1w_ns+orig.BRIK -> __ats_tmp___pad15_pre.sub-08_T1w_ns.skl+orig.BRIK
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ././__ats_tmp___pad15_pre.sub-08_T1w_ns+orig.BRIK
Unpadding ...
++ 3dZeropad: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ output dataset: ./__ats_tmp___upad15_pre.sub-08_T1w_ns+orig.BRIK
++ 3drefit: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
++ Processing AFNI dataset __ats_tmp___upad15_pre.sub-08_T1w_ns+orig
*+ WARNING: Changing the space of an ORIG view dataset may cause confusion!
*+ WARNING:  NIFTI copies will be interpreted as TLRC view (not TLRC space).
*+ WARNING:  Consider changing the view of the dataset to TLRC view also
++ 3drefit processed 1 datasets
Changing view of transformed anatomy
++ 3drefit: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
++ Processing AFNI dataset __ats_tmp___upad15_pre.sub-08_T1w_ns+orig.HEAD
 + changing dataset view code
 + Changed dataset view type and filenames.
++ 3drefit processed 1 datasets
Setting parent with 3drefit -wset sub-08_T1w_ns+orig __ats_tmp___upad15_pre.sub-08_T1w_ns+tlrc
++ 3drefit: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
++ Processing AFNI dataset __ats_tmp___upad15_pre.sub-08_T1w_ns+tlrc
 + setting Warp parent
++ 3drefit processed 1 datasets
++ 3drename: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Warning: ignoring +tlrc on new_prefix.
++ THD_rename_dataset_files: rename __ats_tmp___upad15_pre.sub-08_T1w_ns+tlrc.HEAD -> sub-08_T1w_ns+tlrc.HEAD
++ THD_rename_dataset_files: rename __ats_tmp___upad15_pre.sub-08_T1w_ns+tlrc.BRIK -> sub-08_T1w_ns+tlrc.BRIK
Cleanup ...
cat_matvec sub-08_T1w_ns+tlrc::WARP_DATA -I
if ( ! -f sub-08_T1w_ns+tlrc.HEAD ) then
foreach run ( 01 02 )
3dvolreg -verbose -zpad 1 -base vr_base_min_outlier+orig -1Dfile dfile.r01.1D -prefix rm.epi.volreg.r01 -cubic -1Dmatrix_save mat.r01.vr.aff12.1D pb00.sub_08.r01.tcat+orig
++ 3dvolreg: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
++ Reading in base dataset ./vr_base_min_outlier+orig.BRIK
++ Reading input dataset ./pb00.sub_08.r01.tcat+orig.BRIK
++ Edging: x=3 y=3 z=2
++ Creating mask for -maxdisp
 + Automask has 40918 voxels
 + 5959 voxels left in -maxdisp mask after erosion
++ Initializing alignment base
++ Starting final pass on 146 sub-bricks: 0..1..2..3..4..5..6..7..8..9..10..11..12..13..14..15..16..17..18..19..20..21..22..23..24..25..26..27..28..29..30..31..32..33..34..35..36..37..38..39..40..41..42..43..44..45..46..47..48..49..50..51..52..53..54..55..56..57..58..59..60..61..62..63..64..65..66..67..68..69..70..71..72..73..74..75..76..77..78..79..80..81..82..83..84..85..86..87..88..89..90..91..92..93..94..95..96..97..98..99..100..101..102..103..104..105..106..107..108..109..110..111..112..113..114..115..116..117..118..119..120..121..122..123..124..125..126..127..128..129..130..131..132..133..134..135..136..137..138..139..140..141..142..143..144..145..
++ CPU time for realignment=0 s  [=0 s/sub-brick]
++ Min : roll=-0.014  pitch=-0.044  yaw=-0.059  dS=-0.092  dL=-0.041  dP=-0.083
++ Mean: roll=+0.022  pitch=+0.035  yaw=+0.065  dS=+0.016  dL=+0.029  dP=+0.013
++ Max : roll=+0.119  pitch=+0.184  yaw=+0.253  dS=+0.181  dL=+0.123  dP=+0.235
++ Max displacements (mm) for each sub-brick:
 0.15(0.00) 0.09(0.16) 0.06(0.09) 0.05(0.08) 0.07(0.08) 0.07(0.03) 0.08(0.05) 0.06(0.05) 0.15(0.13) 0.09(0.12) 0.15(0.12) 0.09(0.13) 0.11(0.10) 0.09(0.06) 0.09(0.05) 0.11(0.04) 0.04(0.10) 0.08(0.08) 0.07(0.05) 0.13(0.10) 0.06(0.11) 0.06(0.09) 0.07(0.09) 0.03(0.05) 0.09(0.07) 0.06(0.13) 0.07(0.09) 0.05(0.08) 0.00(0.05) 0.06(0.06) 0.06(0.08) 0.05(0.06) 0.10(0.07) 0.06(0.06) 0.07(0.09) 0.06(0.10) 0.08(0.08) 0.08(0.07) 0.12(0.10) 0.08(0.11) 0.09(0.08) 0.11(0.07) 0.05(0.08) 0.08(0.05) 0.03(0.08) 0.07(0.06) 0.08(0.09) 0.06(0.05) 0.10(0.07) 0.08(0.09) 0.12(0.10) 0.10(0.08) 0.06(0.07) 0.14(0.14) 0.09(0.11) 0.11(0.10) 0.14(0.06) 0.09(0.12) 0.12(0.11) 0.10(0.09) 0.10(0.06) 0.15(0.07) 0.09(0.12) 0.11(0.10) 0.09(0.15) 0.14(0.16) 0.09(0.09) 0.10(0.03) 0.11(0.07) 0.08(0.07) 0.13(0.11) 0.09(0.11) 0.13(0.11) 0.09(0.08) 0.10(0.06) 0.13(0.10) 0.10(0.09) 0.14(0.11) 0.11(0.14) 0.11(0.10) 0.09(0.07) 0.10(0.08) 0.11(0.06) 0.10(0.10) 0.16(0.16) 0.10(0.16) 0.13(0.14) 0.13(0.11) 0.17(0.07) 0.18(0.07) 0.15(0.09) 0.15(0.07) 0.12(0.10) 0.17(0.10) 0.15(0.05) 0.16(0.07) 0.14(0.06) 0.16(0.10) 0.24(0.15) 0.14(0.17) 0.21(0.14) 0.16(0.12) 0.29(0.22) 0.20(0.16) 0.23(0.11) 0.21(0.07) 0.21(0.10) 0.23(0.05) 0.19(0.12) 0.22(0.08) 0.18(0.09) 0.23(0.10) 0.19(0.11) 0.28(0.14) 0.21(0.10) 0.23(0.06) 0.23(0.07) 0.29(0.15) 0.22(0.17) 0.29(0.10) 0.30(0.04) 0.27(0.07) 0.31(0.08) 0.28(0.06) 0.34(0.11) 0.30(0.07) 0.37(0.11) 0.28(0.15) 0.36(0.14) 0.29(0.14) 0.36(0.15) 0.32(0.30) 0.41(0.27) 0.49(0.29) 0.46(0.11) 0.49(0.18) 0.56(0.18) 0.55(0.14) 0.55(0.10) 0.54(0.03) 0.52(0.12) 0.51(0.14) 0.48(0.15) 0.41(0.17) 0.41(0.22) 0.42(0.12)
++ Max displacement in automask = 0.56 (mm) at sub-brick 136
++ Max delta displ  in automask = 0.30 (mm) at sub-brick 131
++ Wrote dataset to disk in ./rm.epi.volreg.r01+orig.BRIK
3dcalc -overwrite -a pb00.sub_08.r01.tcat+orig -expr 1 -prefix rm.epi.all1
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
*+ WARNING: input 'a' is not used in the expression
++ Output dataset ./rm.epi.all1+orig.BRIK
cat_matvec -ONELINE sub-08_T1w_ns+tlrc::WARP_DATA -I sub-08_T1w_al_junk_mat.aff12.1D -I mat.r01.vr.aff12.1D
3dAllineate -base sub-08_T1w_ns+tlrc -input pb00.sub_08.r01.tcat+orig -1Dmatrix_apply mat.r01.warp.aff12.1D -mast_dxyz 3 -prefix rm.epi.nomask.r01
++ 3dAllineate: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Zhark the Registrator
++ Source dataset: ./pb00.sub_08.r01.tcat+orig.HEAD
++ Base dataset:   ./sub-08_T1w_ns+tlrc.HEAD
++ Loading datasets into memory
*+ WARNING: center of mass shifts (-cmass) are turned off, but would be TERRIBLY large!
*+ WARNING:   - at least one is more than 50% of search range
 +        -cmass x y z shifts =    0.027   -8.241  -29.822
 +  shift search range is +/- =   57.780   69.336   57.780
 +                                  0.0%    11.9%    51.6%
++ master dataset for output = base
++ changing output grid spacing to 3.0000 mm
++ OpenMP thread count = 15
++ ========== Applying transformation to 146 sub-bricks ==========
volume 0..1..2..3..4..5..6..7..8..9..10..11..12..13..14..15..16..17..18..19..20..21..22..23..24..25..26..27..28..29..30..31..32..33..34..35..36..37..38..39..40..41..42..43..44..45..46..47..48..49..50..51..52..53..54..55..56..57..58..59..60..61..62..63..64..65..66..67..68..69..70..71..72..73..74..75..76..77..78..79..80..81..82..83..84..85..86..87..88..89..90..91..92..93..94..95..96..97..98..99..100..101..102..103..104..105..106..107..108..109..110..111..112..113..114..115..116..117..118..119..120..121..122..123..124..125..126..127..128..129..130..131..132..133..134..135..136..137..138..139..140..141..142..143..144..145
++ Output dataset ./rm.epi.nomask.r01+tlrc.BRIK
++ 3dAllineate: total CPU time = 0.0 sec  Elapsed = 4.5
++ ###########################################################
 +  
++ ***********************************************************
*+ WARNING: -cmass was turned off, but might have been needed :(
 +           Please check your results - PLEASE PLEASE PLEASE
++ ***********************************************************
3dAllineate -base sub-08_T1w_ns+tlrc -input rm.epi.all1+orig -1Dmatrix_apply mat.r01.warp.aff12.1D -mast_dxyz 3 -final NN -quiet -prefix rm.epi.1.r01
++ 3dAllineate: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Zhark the Registrator
*+ WARNING: center of mass shifts (-cmass) are turned off, but would be TERRIBLY large!
*+ WARNING:   - at least one is more than 50% of search range
 +        -cmass x y z shifts =    1.280  -18.654  -32.063
 +  shift search range is +/- =   57.780   69.336   57.780
 +                                  2.2%    26.9%    55.5%
++ Output dataset ./rm.epi.1.r01+tlrc.BRIK
++ 3dAllineate: total CPU time = 0.0 sec  Elapsed = 3.9
 +  
++ ***********************************************************
*+ WARNING: -cmass was turned off, but might have been needed :(
 +           Please check your results - PLEASE PLEASE PLEASE
++ ***********************************************************
3dTstat -min -prefix rm.epi.min.r01 rm.epi.1.r01+tlrc
++ 3dTstat: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: KR Hammett & RW Cox
++ Output dataset ./rm.epi.min.r01+tlrc.BRIK
end
3dvolreg -verbose -zpad 1 -base vr_base_min_outlier+orig -1Dfile dfile.r02.1D -prefix rm.epi.volreg.r02 -cubic -1Dmatrix_save mat.r02.vr.aff12.1D pb00.sub_08.r02.tcat+orig
++ 3dvolreg: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
++ Reading in base dataset ./vr_base_min_outlier+orig.BRIK
++ Reading input dataset ./pb00.sub_08.r02.tcat+orig.BRIK
++ Edging: x=3 y=3 z=2
++ Creating mask for -maxdisp
 + Automask has 40888 voxels
 + 5952 voxels left in -maxdisp mask after erosion
++ Initializing alignment base
++ Starting final pass on 146 sub-bricks: 0..1..2..3..4..5..6..7..8..9..10..11..12..13..14..15..16..17..18..19..20..21..22..23..24..25..26..27..28..29..30..31..32..33..34..35..36..37..38..39..40..41..42..43..44..45..46..47..48..49..50..51..52..53..54..55..56..57..58..59..60..61..62..63..64..65..66..67..68..69..70..71..72..73..74..75..76..77..78..79..80..81..82..83..84..85..86..87..88..89..90..91..92..93..94..95..96..97..98..99..100..101..102..103..104..105..106..107..108..109..110..111..112..113..114..115..116..117..118..119..120..121..122..123..124..125..126..127..128..129..130..131..132..133..134..135..136..137..138..139..140..141..142..143..144..145..
++ CPU time for realignment=0 s  [=0 s/sub-brick]
++ Min : roll=+0.065  pitch=-0.196  yaw=-0.295  dS=-0.284  dL=+0.045  dP=-0.220
++ Mean: roll=+0.160  pitch=+0.114  yaw=+0.164  dS=-0.032  dL=+0.132  dP=-0.070
++ Max : roll=+0.233  pitch=+0.250  yaw=+0.335  dS=+0.142  dL=+0.306  dP=+0.067
++ Max displacements (mm) for each sub-brick:
 0.70(0.00) 0.61(0.16) 0.62(0.09) 0.60(0.07) 0.58(0.06) 0.63(0.08) 0.61(0.07) 0.62(0.08) 0.60(0.07) 0.55(0.07) 0.62(0.08) 0.61(0.11) 0.61(0.07) 0.59(0.05) 0.50(0.10) 0.54(0.06) 0.52(0.08) 0.57(0.09) 0.58(0.09) 0.56(0.09) 0.58(0.06) 0.56(0.07) 0.59(0.10) 0.57(0.09) 0.57(0.07) 0.59(0.05) 0.56(0.05) 0.59(0.08) 0.60(0.08) 0.58(0.07) 0.58(0.07) 0.58(0.06) 0.58(0.02) 0.59(0.05) 0.57(0.34) 0.38(0.39) 0.47(0.48) 0.90(0.47) 0.59(0.35) 0.49(0.19) 0.50(0.16) 0.46(0.12) 0.48(0.16) 0.46(0.17) 0.48(0.13) 0.47(0.10) 0.48(0.10) 0.49(0.09) 0.51(0.10) 0.53(0.06) 0.51(0.09) 0.53(0.09) 0.50(0.10) 0.50(0.09) 0.50(0.08) 0.49(0.07) 0.52(0.06) 0.46(0.10) 0.46(0.21) 0.52(0.33) 0.50(0.20) 0.54(0.12) 0.54(0.09) 0.60(0.12) 0.55(0.14) 0.59(0.12) 0.58(0.10) 0.62(0.13) 0.53(0.11) 0.49(0.14) 0.49(0.04) 0.46(0.07) 0.55(0.11) 0.48(0.14) 0.57(0.15) 0.46(0.14) 0.54(0.11) 0.44(0.13) 0.51(0.11) 0.47(0.10) 0.55(0.15) 0.59(0.11) 0.56(0.13) 0.53(0.13) 0.60(0.14) 0.58(0.10) 0.55(0.04) 0.53(0.07) 0.59(0.11) 0.49(0.15) 0.57(0.14) 0.52(0.17) 0.77(0.46) 0.58(0.27) 0.57(0.20) 0.57(0.10) 0.58(0.13) 0.56(0.14) 0.57(0.14) 0.55(0.09) 0.60(0.10) 0.55(0.09) 0.55(0.05) 0.55(0.04) 0.57(0.07) 0.61(0.06) 0.53(0.11) 0.67(0.16) 0.55(0.16) 0.59(0.11) 0.53(0.10) 0.54(0.06) 0.57(0.07) 0.51(0.12) 0.56(0.12) 0.57(0.17) 0.64(0.20) 0.58(0.21) 0.56(0.09) 0.60(0.07) 0.55(0.07) 0.61(0.08) 0.56(0.12) 0.60(0.14) 0.59(0.10) 0.61(0.07) 0.59(0.06) 0.56(0.08) 0.67(0.14) 0.61(0.12) 0.64(0.14) 0.64(0.04) 0.64(0.19) 0.57(0.25) 0.54(0.10) 0.54(0.07) 0.53(0.05) 0.57(0.11) 0.53(0.11) 0.58(0.12) 0.53(0.09) 0.55(0.06) 0.52(0.11) 0.56(0.13) 0.55(0.10) 0.53(0.06)
++ Max displacement in automask = 0.90 (mm) at sub-brick 37
++ Max delta displ  in automask = 0.48 (mm) at sub-brick 36
++ Wrote dataset to disk in ./rm.epi.volreg.r02+orig.BRIK
3dcalc -overwrite -a pb00.sub_08.r02.tcat+orig -expr 1 -prefix rm.epi.all1
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
*+ WARNING: input 'a' is not used in the expression
++ Output dataset ./rm.epi.all1+orig.BRIK
cat_matvec -ONELINE sub-08_T1w_ns+tlrc::WARP_DATA -I sub-08_T1w_al_junk_mat.aff12.1D -I mat.r02.vr.aff12.1D
3dAllineate -base sub-08_T1w_ns+tlrc -input pb00.sub_08.r02.tcat+orig -1Dmatrix_apply mat.r02.warp.aff12.1D -mast_dxyz 3 -prefix rm.epi.nomask.r02
++ 3dAllineate: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Zhark the Registrator
++ Source dataset: ./pb00.sub_08.r02.tcat+orig.HEAD
++ Base dataset:   ./sub-08_T1w_ns+tlrc.HEAD
++ Loading datasets into memory
*+ WARNING: center of mass shifts (-cmass) are turned off, but would be TERRIBLY large!
*+ WARNING:   - at least one is more than 50% of search range
 +        -cmass x y z shifts =   -0.046   -8.175  -29.810
 +  shift search range is +/- =   57.780   69.336   57.780
 +                                  0.1%    11.8%    51.6%
++ master dataset for output = base
++ changing output grid spacing to 3.0000 mm
++ OpenMP thread count = 15
++ ========== Applying transformation to 146 sub-bricks ==========
volume 0..1..2..3..4..5..6..7..8..9..10..11..12..13..14..15..16..17..18..19..20..21..22..23..24..25..26..27..28..29..30..31..32..33..34..35..36..37..38..39..40..41..42..43..44..45..46..47..48..49..50..51..52..53..54..55..56..57..58..59..60..61..62..63..64..65..66..67..68..69..70..71..72..73..74..75..76..77..78..79..80..81..82..83..84..85..86..87..88..89..90..91..92..93..94..95..96..97..98..99..100..101..102..103..104..105..106..107..108..109..110..111..112..113..114..115..116..117..118..119..120..121..122..123..124..125..126..127..128..129..130..131..132..133..134..135..136..137..138..139..140..141..142..143..144..145
++ Output dataset ./rm.epi.nomask.r02+tlrc.BRIK
++ 3dAllineate: total CPU time = 0.0 sec  Elapsed = 4.5
++ ###########################################################
 +  
++ ***********************************************************
*+ WARNING: -cmass was turned off, but might have been needed :(
 +           Please check your results - PLEASE PLEASE PLEASE
++ ***********************************************************
3dAllineate -base sub-08_T1w_ns+tlrc -input rm.epi.all1+orig -1Dmatrix_apply mat.r02.warp.aff12.1D -mast_dxyz 3 -final NN -quiet -prefix rm.epi.1.r02
++ 3dAllineate: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Zhark the Registrator
*+ WARNING: center of mass shifts (-cmass) are turned off, but would be TERRIBLY large!
*+ WARNING:   - at least one is more than 50% of search range
 +        -cmass x y z shifts =    1.280  -18.654  -32.063
 +  shift search range is +/- =   57.780   69.336   57.780
 +                                  2.2%    26.9%    55.5%
++ Output dataset ./rm.epi.1.r02+tlrc.BRIK
++ 3dAllineate: total CPU time = 0.0 sec  Elapsed = 4.0
 +  
++ ***********************************************************
*+ WARNING: -cmass was turned off, but might have been needed :(
 +           Please check your results - PLEASE PLEASE PLEASE
++ ***********************************************************
3dTstat -min -prefix rm.epi.min.r02 rm.epi.1.r02+tlrc
++ 3dTstat: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: KR Hammett & RW Cox
++ Output dataset ./rm.epi.min.r02+tlrc.BRIK
end
cat dfile.r01.1D dfile.r02.1D
1d_tool.py -infile dfile_rall.1D -set_nruns 2 -derivative -collapse_cols euclidean_norm -write motion_sub_08_enorm.1D
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
3dMean -datum short -prefix rm.epi.mean rm.epi.min.r01+tlrc.HEAD rm.epi.min.r02+tlrc.HEAD
++ 3dMean: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
3dcalc -a rm.epi.mean+tlrc -expr step(a-0.999) -prefix mask_epi_extents
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./mask_epi_extents+tlrc.BRIK
foreach run ( 01 02 )
3dcalc -a rm.epi.nomask.r01+tlrc -b mask_epi_extents+tlrc -expr a*b -prefix pb01.sub_08.r01.volreg
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./pb01.sub_08.r01.volreg+tlrc.BRIK
end
3dcalc -a rm.epi.nomask.r02+tlrc -b mask_epi_extents+tlrc -expr a*b -prefix pb01.sub_08.r02.volreg
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./pb01.sub_08.r02.volreg+tlrc.BRIK
end
cat_matvec -ONELINE sub-08_T1w_ns+tlrc::WARP_DATA -I sub-08_T1w_al_junk_mat.aff12.1D -I
3dAllineate -base sub-08_T1w_ns+tlrc -input vr_base_min_outlier+orig -1Dmatrix_apply mat.basewarp.aff12.1D -mast_dxyz 3 -prefix final_epi_vr_base_min_outlier
++ 3dAllineate: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Zhark the Registrator
++ Source dataset: ./vr_base_min_outlier+orig.HEAD
++ Base dataset:   ./sub-08_T1w_ns+tlrc.HEAD
++ Loading datasets into memory
*+ WARNING: center of mass shifts (-cmass) are turned off, but would be TERRIBLY large!
*+ WARNING:   - at least one is more than 50% of search range
 +        -cmass x y z shifts =    0.073   -8.252  -29.781
 +  shift search range is +/- =   57.780   69.336   57.780
 +                                  0.1%    11.9%    51.5%
++ master dataset for output = base
++ changing output grid spacing to 3.0000 mm
++ OpenMP thread count = 15
++ ========== Applying transformation to 1 sub-bricks ==========
++ Output dataset ./final_epi_vr_base_min_outlier+tlrc.BRIK
++ 3dAllineate: total CPU time = 0.0 sec  Elapsed = 0.1
++ ###########################################################
 +  
++ ***********************************************************
*+ WARNING: -cmass was turned off, but might have been needed :(
 +           Please check your results - PLEASE PLEASE PLEASE
++ ***********************************************************
3dcopy sub-08_T1w_ns+tlrc anat_final.sub_08
++ 3dcopy: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
3dAllineate -base final_epi_vr_base_min_outlier+tlrc -allcostX -input anat_final.sub_08+tlrc
tee out.allcostX.txt
++ 3dAllineate: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Zhark the Registrator
++ Source dataset: ./anat_final.sub_08+tlrc.HEAD
++ Base dataset:   ./final_epi_vr_base_min_outlier+tlrc.HEAD
++ Loading datasets into memory
++ Local correlation: blok type = 'TOHD(15.531)'
 +        -cmass x y z shifts =   -0.040    1.128    0.173
 +  shift search range is +/- =   66.447   79.929   68.373
*+ WARNING: No output dataset will be calculated
++ OpenMP thread count = 15
 + initial Parameters = 0.0000 0.0000 0.0000 0.0000 0.0000 0.0000 1.0000 1.0000 1.0000 0.0000 0.0000 0.0000
++ allcost output: init #0
   ls   = 0.102416
   sp   = 0.294745
   mi   = 2.69858
   crM  = 0.0196901
   nmi  = 0.820873
   je   = 2.69858
   hel  = -0.12172
   crA  = 0.141537
   crU  = 0.160044
   lss  = 0.897584
   lpc  = 0.647903
   lpa  = 0.352097
   lpc+ = 0.746398
   lpa+ = 0.450592
++ Output dataset ./volumized+tlrc.BRIK
++ 3dAllineate: total CPU time = 0.0 sec  Elapsed = 0.7
++ ###########################################################
3dAllineate -source sub-08_T1w+orig -master anat_final.sub_08+tlrc -final wsinc5 -1Dmatrix_apply warp.anat.Xat.1D -prefix anat_w_skull_warped
++ 3dAllineate: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Zhark the Registrator
++ -1Dmatrix_apply: converting input 3x4 array to 1 row of 12 numbers
++ Source dataset: ./sub-08_T1w+orig.HEAD
++ Base dataset:   (not given)
++ Loading datasets into memory
 +        -cmass x y z shifts =    0.000    0.000    0.000
 +  shift search range is +/- =   56.175   81.855   81.855
++ OpenMP thread count = 15
++ ========== Applying transformation to 1 sub-bricks ==========
++ wsinc5 interpolation setup:
 +   taper function  = Min sidelobe 3 term
 +   taper cut point = 0.000
 +   window radius   = 5 voxels
 +   window shape    = Cubical
 +   The above can be altered via the AFNI_WSINC5_* environment variables.
 +  (To avoid this message, 'setenv AFNI_WSINC5_SILENT YES'.)
 +   wsinc5 CUBE(5) mask has 1000 points
++ Output dataset ./anat_w_skull_warped+tlrc.BRIK
++ 3dAllineate: total CPU time = 0.0 sec  Elapsed = 1.2
++ ###########################################################
foreach run ( 01 02 )
3dmerge -1blur_fwhm 4.0 -doall -prefix pb02.sub_08.r01.blur pb01.sub_08.r01.volreg+tlrc
++ 3dmerge: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ default -1dindex = 0
++ default -1tindex = 1
Program 3dmerge 
3dmerge: edit and combine 3D datasets, by RW Cox
++ editing input dataset in memory (75.6 MB)
..................................................................................................................................................
-- Wrote edited dataset: ./pb02.sub_08.r01.blur+tlrc.BRIK

end
3dmerge -1blur_fwhm 4.0 -doall -prefix pb02.sub_08.r02.blur pb01.sub_08.r02.volreg+tlrc
++ 3dmerge: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ default -1dindex = 0
++ default -1tindex = 1
Program 3dmerge 
3dmerge: edit and combine 3D datasets, by RW Cox
++ editing input dataset in memory (75.6 MB)
..................................................................................................................................................
-- Wrote edited dataset: ./pb02.sub_08.r02.blur+tlrc.BRIK

end
foreach run ( 01 02 )
3dAutomask -prefix rm.mask_r01 pb02.sub_08.r01.blur+tlrc
++ 3dAutomask: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Emperor Zhark
++ Loading dataset pb02.sub_08.r01.blur+tlrc
++ Forming automask
 + Fixed clip level = 343.540375
 + Used gradual clip level = 322.806030 .. 362.186707
 + Number voxels above clip level = 69428
 + Clustering voxels ...
 + Largest cluster has 68830 voxels
 + Clustering voxels ...
 + Largest cluster has 68733 voxels
 + Filled   139 voxels in small holes; now have 68872 voxels
 + Filled     2 voxels in large holes; now have 68874 voxels
 + Clustering voxels ...
 + Largest cluster has 68873 voxels
 + Clustering non-brain voxels ...
 + Clustering voxels ...
 + Largest cluster has 202760 voxels
 + Mask now has 68873 voxels
++ 68873 voxels in the mask [out of 271633: 25.36%]
++ first   7 x-planes are zero [from L]
++ last    6 x-planes are zero [from R]
++ first   5 y-planes are zero [from P]
++ last    4 y-planes are zero [from A]
++ first   0 z-planes are zero [from I]
++ last    8 z-planes are zero [from S]
++ Output dataset ./rm.mask_r01+tlrc.BRIK
++ CPU time = 0.000000 sec
end
3dAutomask -prefix rm.mask_r02 pb02.sub_08.r02.blur+tlrc
++ 3dAutomask: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Emperor Zhark
++ Loading dataset pb02.sub_08.r02.blur+tlrc
++ Forming automask
 + Fixed clip level = 342.217621
 + Used gradual clip level = 321.662537 .. 360.685547
 + Number voxels above clip level = 69449
 + Clustering voxels ...
 + Largest cluster has 68853 voxels
 + Clustering voxels ...
 + Largest cluster has 68749 voxels
 + Filled   134 voxels in small holes; now have 68883 voxels
 + Filled     2 voxels in large holes; now have 68885 voxels
 + Clustering voxels ...
 + Largest cluster has 68885 voxels
 + Clustering non-brain voxels ...
 + Clustering voxels ...
 + Largest cluster has 202748 voxels
 + Mask now has 68885 voxels
++ 68885 voxels in the mask [out of 271633: 25.36%]
++ first   7 x-planes are zero [from L]
++ last    6 x-planes are zero [from R]
++ first   5 y-planes are zero [from P]
++ last    4 y-planes are zero [from A]
++ first   0 z-planes are zero [from I]
++ last    8 z-planes are zero [from S]
++ Output dataset ./rm.mask_r02+tlrc.BRIK
++ CPU time = 0.000000 sec
end
3dmask_tool -inputs rm.mask_r01+tlrc.HEAD rm.mask_r02+tlrc.HEAD -union -prefix full_mask.sub_08
++ processing 2 input dataset(s), NN=2...
++ padding all datasets by 0 (for dilations)
++ frac 0 over 2 volumes gives min count 0
++ voxel limits: 0 clipped, 68948 survived, 202685 were zero
++ writing result full_mask.sub_08...
++ Output dataset ./full_mask.sub_08+tlrc.BRIK
3dresample -master full_mask.sub_08+tlrc -input sub-08_T1w_ns+tlrc -prefix rm.resam.anat
3dmask_tool -dilate_input 5 -5 -fill_holes -input rm.resam.anat+tlrc -prefix mask_anat.sub_08
++ no -frac option: defaulting to -union
++ processing 1 input dataset(s), NN=2...
++ padding all datasets by 5 (for dilations)
++ frac 0 over 1 volumes gives min count 0
++ voxel limits: 0 clipped, 76711 survived, 194922 were zero
++ filled 0 holes (0 voxels)
++ writing result mask_anat.sub_08...
++ Output dataset ./mask_anat.sub_08+tlrc.BRIK
3dmask_tool -input full_mask.sub_08+tlrc mask_anat.sub_08+tlrc -inter -prefix mask_epi_anat.sub_08
++ processing 2 input dataset(s), NN=2...
++ padding all datasets by 0 (for dilations)
++ frac 1 over 2 volumes gives min count 2
++ voxel limits: 10363 clipped, 67648 survived, 193622 were zero
++ writing result mask_epi_anat.sub_08...
++ Output dataset ./mask_epi_anat.sub_08+tlrc.BRIK
3dABoverlap -no_automask full_mask.sub_08+tlrc mask_anat.sub_08+tlrc
tee out.mask_ae_overlap.txt
++ 3dABoverlap: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
#A=./full_mask.sub_08+tlrc.BRIK  B=./mask_anat.sub_08+tlrc.BRIK
#A           #B           #(A uni B)   #(A int B)   #(A \ B)     #(B \ A)     %(A \ B)    %(B \ A)    Rx(B/A)    Ry(B/A)    Rz(B/A)
68948        76711        78011        67648        1300         9063          1.8855     11.8145     1.0652     0.9478     1.1189
3ddot -dodice full_mask.sub_08+tlrc mask_anat.sub_08+tlrc
tee out.mask_ae_dice.txt
0.928854	
3dresample -master full_mask.sub_08+tlrc -prefix ./rm.resam.group -input /opt/afni-latest/MNI_avg152T1+tlrc
3dmask_tool -dilate_input 5 -5 -fill_holes -input rm.resam.group+tlrc -prefix mask_group
++ no -frac option: defaulting to -union
++ processing 1 input dataset(s), NN=2...
++ padding all datasets by 5 (for dilations)
++ frac 0 over 1 volumes gives min count 0
++ voxel limits: 0 clipped, 73409 survived, 198224 were zero
++ filled 0 holes (0 voxels)
++ writing result mask_group...
++ Output dataset ./mask_group+tlrc.BRIK
3ddot -dodice mask_anat.sub_08+tlrc mask_group+tlrc
tee out.mask_at_dice.txt
0.960445	
foreach run ( 01 02 )
3dTstat -prefix rm.mean_r01 pb02.sub_08.r01.blur+tlrc
++ 3dTstat: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: KR Hammett & RW Cox
++ Output dataset ./rm.mean_r01+tlrc.BRIK
3dcalc -a pb02.sub_08.r01.blur+tlrc -b rm.mean_r01+tlrc -c mask_epi_extents+tlrc -expr c * min(200, a/b*100)*step(a)*step(b) -prefix pb03.sub_08.r01.scale
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./pb03.sub_08.r01.scale+tlrc.BRIK
end
3dTstat -prefix rm.mean_r02 pb02.sub_08.r02.blur+tlrc
++ 3dTstat: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: KR Hammett & RW Cox
++ Output dataset ./rm.mean_r02+tlrc.BRIK
3dcalc -a pb02.sub_08.r02.blur+tlrc -b rm.mean_r02+tlrc -c mask_epi_extents+tlrc -expr c * min(200, a/b*100)*step(a)*step(b) -prefix pb03.sub_08.r02.scale
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./pb03.sub_08.r02.scale+tlrc.BRIK
end
1d_tool.py -infile dfile_rall.1D -set_nruns 2 -demean -write motion_demean.1D
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
3dDeconvolve -input pb03.sub_08.r01.scale+tlrc.HEAD pb03.sub_08.r02.scale+tlrc.HEAD -ortvec motion_demean.1D mot_demean -polort 2 -num_stimts 2 -stim_times 1 stimuli/congruent.1D GAM -stim_label 1 congruent -stim_times 2 stimuli/incongruent.1D GAM -stim_label 2 incongruent -gltsym SYM: +incongruent -congruent -glt_label 1 incongruent-congruent -gltsym SYM: +congruent -incongruent -glt_label 2 congruent-incongruent -jobs 8 -GOFORIT 0 -fout -tout -x1D X.xmat.1D -xjpeg X.jpg -fitts fitts.sub_08 -errts errts.sub_08 -bucket stats.sub_08
++ 3dDeconvolve extending num_stimts from 2 to 8 due to -ortvec
++ 3dDeconvolve: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: B. Douglas Ward, et al.
++ loading dataset pb03.sub_08.r01.scale+tlrc.HEAD pb03.sub_08.r02.scale+tlrc.HEAD
++ Auto-catenated input datasets treated as multiple imaging runs
++ Auto-catenated datasets start at:  0 146
++ STAT automask has 247109 voxels (out of 271633 = 91.0%)
++ Skipping check for initial transients
++ Input polort=2; Longest run=292.0 s; Recommended minimum polort=2 ++ OK ++
++ -stim_times using TR=2 s for stimulus timing conversion
++ -stim_times using TR=2 s for any -iresp output datasets
++  [you can alter the -iresp TR via the -TR_times option]
++ ** -stim_times NOTE ** guessing GLOBAL times if 1 time per line; LOCAL otherwise
++ ** GUESSED ** -stim_times 1 using LOCAL times
++ ** GUESSED ** -stim_times 2 using LOCAL times
------------------------------------------------------------
GLT matrix from 'SYM: +incongruent -congruent':
   0   0   0   0   0   0  -1   1   0   0   0   0   0   0 
 
------------------------------------------------------------
GLT matrix from 'SYM: +congruent -incongruent':
   0   0   0   0   0   0   1  -1   0   0   0   0   0   0 
 
++ Number of time points: 292 (no censoring)
 + Number of parameters:  14 [12 baseline ; 2 signal]
++ total shared memory needed = 648,659,604 bytes (about 649 million)
++ mmap() memory allocated: 648,659,604 bytes (about 649 million)
++ Memory required for output bricks = 648,659,604 bytes (about 649 million)
++ Wrote matrix image to file X.jpg
++ Wrote matrix values to file X.xmat.1D
++ ========= Things you can do with the matrix file =========
++ (a) Linear regression with ARMA(1,1) modeling of serial correlation:

3dREMLfit -matrix X.xmat.1D \
 -input "pb03.sub_08.r01.scale+tlrc.HEAD pb03.sub_08.r02.scale+tlrc.HEAD" \
 -fout -tout -Rbuck stats.sub_08_REML -Rvar stats.sub_08_REMLvar \
 -Rfitts fitts.sub_08_REML -Rerrts errts.sub_08_REML -verb
 
++ N.B.: 3dREMLfit command above written to file stats.REML_cmd
++ (b) Visualization/analysis of the matrix via ExamineXmat.R
++ (c) Synthesis of sub-model datasets using 3dSynthesize
++ ==========================================================
++ ----- Signal+Baseline matrix condition [X] (292x14):  2.63533  ++ VERY GOOD ++
++ ----- Signal-only matrix condition [X] (292x2):  1  ++ VERY GOOD ++
++ ----- Baseline-only matrix condition [X] (292x12):  2.63198  ++ VERY GOOD ++
++ ----- stim_base-only matrix condition [X] (292x6):  2.13231  ++ VERY GOOD ++
++ ----- polort-only matrix condition [X] (292x6):  1  ++ VERY GOOD ++
++ +++++ Matrix inverse average error = 1.11586e-15  ++ VERY GOOD ++
++ Matrix setup time = 0.66 s
++ Voxels in dataset: 271633
++ Voxels per job:    33954
++ Job #1: processing voxels 33954 to 67907; elapsed time=4.243
++ Job #2: processing voxels 67908 to 101861; elapsed time=4.257
++ Job #3: processing voxels 101862 to 135815; elapsed time=4.270
++ Job #4: processing voxels 135816 to 169769; elapsed time=4.283
++ Job #5: processing voxels 169770 to 203723; elapsed time=4.295
++ Job #6: processing voxels 203724 to 237677; elapsed time=4.309
++ Job #7: processing voxels 237678 to 271632; elapsed time=4.322
++ Job #0: processing voxels 0 to 33953; elapsed time=4.332
++ voxel loop:0123456789.0123456789.0123456789.0123456789.01234567++ Job #2 finished; elapsed time=6.467
++ Job #1 finished; elapsed time=6.479
8++ Job #3 finished; elapsed time=6.488
9.
++ Job #0 waiting for children to finish; elapsed time=6.525
++ Job #4 finished; elapsed time=6.547
++ Job #5 finished; elapsed time=6.565
++ Job #7 finished; elapsed time=6.589
++ Job #6 finished; elapsed time=6.626
++ Job #0 now finishing up; elapsed time=6.633
++ Smallest FDR q [0 Full_Fstat] = 3.8495e-12
++ Smallest FDR q [2 congruent#0_Tstat] = 7.46618e-10
++ Smallest FDR q [3 congruent_Fstat] = 7.46588e-10
++ Smallest FDR q [5 incongruent#0_Tstat] = 1.81843e-11
++ Smallest FDR q [6 incongruent_Fstat] = 1.81834e-11
++ Smallest FDR q [8 incongruent-congruent_GLT#0_Tstat] = 0.00764531
++ Smallest FDR q [9 incongruent-congruent_GLT_Fstat] = 0.00764541
++ Smallest FDR q [11 congruent-incongruent_GLT#0_Tstat] = 0.00764531
++ Smallest FDR q [12 congruent-incongruent_GLT_Fstat] = 0.00764541
++ Wrote bucket dataset into ./stats.sub_08+tlrc.BRIK
 + created 9 FDR curves in bucket header
++ Wrote 3D+time dataset into ./fitts.sub_08+tlrc.BRIK
++ Wrote 3D+time dataset into ./errts.sub_08+tlrc.BRIK
++ Program finished; elapsed time=18.310
if ( 0 != 0 ) then
1d_tool.py -show_cormat_warnings -infile X.xmat.1D
tee out.cormat_warn.txt
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
-- no warnings for correlation matrix (cut = 0.400) --
1d_tool.py -show_df_info -infile X.xmat.1D
tee out.df_info.txt
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \

initial DF                   : 292 : 100.0%

DF used for regs of interest :   2 :   0.7%
DF used for censoring        :   0 :   0.0%
DF used for polort           :   6 :   2.1%
DF used for motion           :   6 :   2.1%
total DF used                :  14 :   4.8%

final DF                     : 278 :  95.2%

tcsh -x stats.REML_cmd
3dREMLfit -matrix X.xmat.1D -input pb03.sub_08.r01.scale+tlrc.HEAD pb03.sub_08.r02.scale+tlrc.HEAD -fout -tout -Rbuck stats.sub_08_REML -Rvar stats.sub_08_REMLvar -Rfitts fitts.sub_08_REML -Rerrts errts.sub_08_REML -verb
++ 3dREMLfit: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RWCox
++ Number of OpenMP threads = 15
++ No mask ==> computing for all 271633 voxels
++ FDR automask has 247109 voxels (out of 271633 = 91.0%)
++ shortest run = 146   longest run = 146
++ -----  matrix condition (292x14):  2.63533  ++ VERY GOOD ++
 + masked off 47222 voxels for being all zero; 224411 left in mask
++ starting REML setup calculations; total CPU=0.00 Elapsed=2.31
 + X matrix: 69.912% of elements are nonzero
 + starting 15 OpenMP threads for REML setup
 + REML setup finished: matrix rows=292 cols=14; 109*1 cases; total CPU=0.00 Elapsed=2.32
 +  average case bandwidth = 16.10
++ REML voxel loop: [15 threads]0123456789.0123456789.0123456789.0123456789.01
 + ARMA voxel parameters estimated: total CPU=0.00 Elapsed=13.62
++ Ljung-Box max lag parameter h = 31 (29 chi-squared DOF)
++ GLSQ loop:0123456789.0123456789.0123456789.0123456789.0123456789.
 + GLSQ regression done: total CPU=0.00 Elapsed=32.21
++ Output dataset ./stats.sub_08_REMLvar+tlrc.BRIK
++ Output dataset ./fitts.sub_08_REML+tlrc.BRIK
++ Output dataset ./errts.sub_08_REML+tlrc.BRIK
++ creating FDR curves in dataset stats.sub_08_REML+tlrc
++ Smallest FDR q [0 Full_Fstat] = 5.01432e-12
++ Smallest FDR q [2 congruent#0_Tstat] = 1.38069e-09
++ Smallest FDR q [3 congruent_Fstat] = 1.3807e-09
++ Smallest FDR q [5 incongruent#0_Tstat] = 2.04457e-10
++ Smallest FDR q [6 incongruent_Fstat] = 2.04457e-10
*+ WARNING: Smallest FDR q [8 incongruent-congruent#0_Tstat] = 0.144911 ==> few true single voxel detections
*+ WARNING: Smallest FDR q [9 incongruent-congruent_Fstat] = 0.144911 ==> few true single voxel detections
*+ WARNING: Smallest FDR q [11 congruent-incongruent#0_Tstat] = 0.144911 ==> few true single voxel detections
*+ WARNING: Smallest FDR q [12 congruent-incongruent_Fstat] = 0.144911 ==> few true single voxel detections
 + Added 9 FDR curves to dataset stats.sub_08_REML+tlrc
++ Output dataset ./stats.sub_08_REML+tlrc.BRIK
 + unloading input dataset and REML matrices
++ 3dREMLfit is all done! total CPU=0.00 Elapsed=43.03
if ( 0 != 0 ) then
3dTcat -prefix all_runs.sub_08 pb03.sub_08.r01.scale+tlrc.HEAD pb03.sub_08.r02.scale+tlrc.HEAD
++ 3dTcat: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ elapsed time = 0.7 s
3dTstat -mean -prefix rm.signal.all all_runs.sub_08+tlrc
++ 3dTstat: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: KR Hammett & RW Cox
++ Output dataset ./rm.signal.all+tlrc.BRIK
3dTstat -stdev -prefix rm.noise.all errts.sub_08_REML+tlrc
++ 3dTstat: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: KR Hammett & RW Cox
++ Output dataset ./rm.noise.all+tlrc.BRIK
3dcalc -a rm.signal.all+tlrc -b rm.noise.all+tlrc -expr a/b -prefix TSNR.sub_08
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./TSNR.sub_08+tlrc.BRIK
3dTnorm -norm2 -prefix rm.errts.unit errts.sub_08_REML+tlrc
++ 3dTnorm: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: RW Cox
++ Output dataset ./rm.errts.unit+tlrc.BRIK
3dmaskave -quiet -mask full_mask.sub_08+tlrc rm.errts.unit+tlrc
++ 3dmaskave: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
+++ 68948 voxels survive the mask
3dTstat -sos -prefix - mean.errts.unit.1D'
++ 3dTstat: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: KR Hammett & RW Cox
*+ WARNING: Input dataset is not 3D+time; assuming TR=1.0
echo -- GCOR = `cat out.gcor.1D`
cat out.gcor.1D
-- GCOR =  0.0806407
3dmaskave -quiet -mask full_mask.sub_08+tlrc errts.sub_08_REML+tlrc
++ 3dmaskave: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
+++ 68948 voxels survive the mask
3dTcorr1D -prefix corr_brain errts.sub_08_REML+tlrc mean.errts.1D
++ 3dTcorr1D: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
 + reading dataset file errts.sub_08_REML+tlrc
 + reading 1D file mean.errts.1D
 + loading dataset ./errts.sub_08_REML+tlrc.BRIK into memory
++ Start correlations: 271633 voxels X 1 time series(292); 1 threads
*+ WARNING: THD_Tcorr1D: 47222 voxels skipped because were constant in time
++ Wrote dataset: ./corr_brain+tlrc.BRIK
1dcat X.xmat.1D[6]
1dcat X.xmat.1D[7]
1d_tool.py -infile X.xmat.1D -write_xstim X.stim.xmat.1D
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
3dTstat -sum -prefix sum_ideal.1D X.stim.xmat.1D
++ 3dTstat: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: KR Hammett & RW Cox
*+ WARNING: Input dataset is not 3D+time; assuming TR=1.0
++ Output dataset ./sum_ideal.1D
gen_epi_review.py -script @epi_review.sub_08 -dsets pb00.sub_08.r01.tcat+orig.HEAD pb00.sub_08.r02.tcat+orig.HEAD
gen_ss_review_scripts.py -exit0 -mask_dset full_mask.sub_08+tlrc.HEAD -ss_review_dset out.ss_review.sub_08.txt -write_uvars_json out.ss_review_uvars.json
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
++ writing ss review basic:          @ss_review_basic
** no mask_dset dset, cannot drive view_stats, skipping...
++ writing ss review driver:         @ss_review_driver
++ writing ss review drive commands: @ss_review_driver_commands
rm -f rm.epi.1.r01+tlrc.BRIK rm.epi.1.r01+tlrc.HEAD rm.epi.1.r02+tlrc.BRIK rm.epi.1.r02+tlrc.HEAD rm.epi.all1+orig.BRIK rm.epi.all1+orig.HEAD rm.epi.mean+tlrc.BRIK rm.epi.mean+tlrc.HEAD rm.epi.min.r01+tlrc.BRIK rm.epi.min.r01+tlrc.HEAD rm.epi.min.r02+tlrc.BRIK rm.epi.min.r02+tlrc.HEAD rm.epi.nomask.r01+tlrc.BRIK rm.epi.nomask.r01+tlrc.HEAD rm.epi.nomask.r02+tlrc.BRIK rm.epi.nomask.r02+tlrc.HEAD rm.epi.volreg.r01+orig.BRIK rm.epi.volreg.r01+orig.HEAD rm.epi.volreg.r02+orig.BRIK rm.epi.volreg.r02+orig.HEAD rm.errts.unit+tlrc.BRIK rm.errts.unit+tlrc.HEAD rm.mask_r01+tlrc.BRIK rm.mask_r01+tlrc.HEAD rm.mask_r02+tlrc.BRIK rm.mask_r02+tlrc.HEAD rm.mean_r01+tlrc.BRIK rm.mean_r01+tlrc.HEAD rm.mean_r02+tlrc.BRIK rm.mean_r02+tlrc.HEAD rm.noise.all+tlrc.BRIK rm.noise.all+tlrc.HEAD rm.resam.anat+tlrc.BRIK rm.resam.anat+tlrc.HEAD rm.resam.group+tlrc.BRIK rm.resam.group+tlrc.HEAD rm.signal.all+tlrc.BRIK rm.signal.all+tlrc.HEAD
if ( -e @ss_review_basic ) then
./@ss_review_basic
tee out.ss_review.sub_08.txt

subject ID                : sub_08
AFNI version              : AFNI_21.2.00
AFNI package              : linux_openmp_64
TR                        : 2.0
TRs removed (per run)     : 0
num stim classes provided : 2
final anatomy dset        : anat_final.sub_08+tlrc.HEAD
final stats dset          : stats.sub_08_REML+tlrc.HEAD
final voxel resolution    : 3.000000	3.000000	3.000000

motion limit              : 0.3
num TRs above mot limit   : 2
average motion (per TR)   : 0.0767002
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
max motion displacement   : 0.868807
average outlier frac (TR) : 0.00122644

/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
num runs found            : 2
num TRs per run           : 146 146
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
TRs total                 : 292
degrees of freedom used   : 14
degrees of freedom left   : 278

/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
num regs of interest      : 2
num TRs per stim          : 120 110
ave mot per sresp         : 0.070899 0.079812

TSNR average              : 136.907
global correlation (GCOR) : 0.0806407
anat/EPI mask Dice coef   : 0.928854
anat/templ mask Dice coef : 0.960445
maximum F-stat (masked)   : 52.0792


apqc_make_tcsh.py -review_style pythonic -subj_dir . -uvar_json out.ss_review_uvars.json
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
++ Found 35 files for QCing.
++ Done making (executable) script to generate HTML QC:
    ./@ss_review_html
tcsh @ss_review_html
tee out.review_html
*+ Found main dset (template):  /opt/afni-latest/MNI_avg152T1+tlrc
++ pbar name has known extension: jpg
++ My command:
   @chauffeur_afni -ulay vr_base_min_outlier+orig.HEAD -olay vr_base_min_outlier+orig.HEAD -ulay_range_nz 0 829.000000 -func_range 829.000000 -box_focus_slices AMASK_FOCUS_ULAY -cbar gray_scale -pbar_posonly -pbar_saveim QC_sub_08/media/qc_00_vorig_EPI.pbar.jpg -pbar_comm_range 98%ile in vol -pbar_for dset -prefix QC_sub_08/media/qc_00_vorig_EPI -save_ftype JPEG -blowup 4 -opacity 9 -montx 7 -monty 1 -montgap 1 -montcolor black -set_xhairs OFF -label_mode 1 -label_size 3 -do_clean

++ Using AFNI ver : AFNI_21.2.00
++ chauffeur ver  : 6.26

------------------ start of optionizing ------------------

++ Found input file:   vr_base_min_outlier+orig.HEAD
++ Found input file:   vr_base_min_outlier+orig.HEAD
++ Using blowup factor: 4
++ Using opacity:  9
++ Making temporary work directory to copy vis files: QC_sub_08/media/__tmp_chauf_9t3MZI1OgAi
++ Converted 0 to labels
++ Final subbrick indices: -1 -1 -1
++ Copy ulay to visualize (volumetric) within user's range:
++ Ulay to be visualized within user range:
   [0, 829.000000]
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./QC_sub_08/media/__tmp_chauf_9t3MZI1OgAi/tmp_ulay.nii
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./QC_sub_08/media/__tmp_chauf_9t3MZI1OgAi/tmp_olay.nii
++ User-entered function range value value (829.000000)
++ Dimensions (xyzt): 64 64 40 1
++ (initial) Slice spacing ordered (x,y,z) is:  9 9 5
++ 3dAutomask: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Emperor Zhark
++ 3dAutobox: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Auto bbox: x=10..54  y=0..59  z=0..36
++ 3dAutobox: output dataset = QC_sub_08/media/__tmp_chauf_9t3MZI1OgAi/ulay_box_0.nii
++ 3dmaskdump: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Executing 3dcalc()
 argv[0]=3dcalc argv[1]=-a argv[2]=QC_sub_08/media/__tmp_chauf_9t3MZI1OgAi/ulay_box_0.nii[0] argv[3]=-expr argv[4]=a argv[5]=-byte argv[6]=-session argv[7]=/tmp argv[8]=-prefix argv[9]=3dcalc_XYZ_bsOflmNcbxf_KJpT0Ip1-g argv[10]=-verbose
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Computing sub-brick 0
++ Scaling output to type byte brick(s)
++ Sub-brick 0: no scale factor
++ Computing output statistics
++ Output dataset /tmp/3dcalc_XYZ_bsOflmNcbxf_KJpT0Ip1-g+orig.BRIK
++ 99900 voxels in the entire dataset (no mask)
++ 1 voxels in the boxes and/or balls
++ Using only the boxes+balls mask
++ How many coors? 3
++ Will have the ref box central coors : SET_DICOM_XYZ 1.5 8.945793 -26.24097
++ Will have the ref box central gapord: 6 8 5

------------------- end of optionizing -------------------

 -- trying to start Xvfb :204 
[1] 474332
_XSERVTransmkdir: Owner of /tmp/.X11-unix should be set to root
+/home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/afni_pro_glm/sub_08.results/QC_sub_08/media/__tmp_chauf_9t3MZI1OgAi++ Writing palette image to QC_sub_08/media/qc_00_vorig_EPI.pbar.jpg
++ Writing one 1816x212 image to filter '/opt/afni-latest/cjpeg -quality 95 > QC_sub_08/media/qc_00_vorig_EPI.sag.jpg'
++ Writing one 1816x212 image to filter '/opt/afni-latest/cjpeg -quality 95 > QC_sub_08/media/qc_00_vorig_EPI.cor.jpg'
++ Writing one 1816x256 image to filter '/opt/afni-latest/cjpeg -quality 95 > QC_sub_08/media/qc_00_vorig_EPI.axi.jpg'

AFNI QUITTs!

+++ Command Echo:
   afni -q -no1D -noplugins -no_detach -com SWITCH_UNDERLAY tmp_ulay.nii -com SWITCH_OVERLAY  tmp_olay.nii -com SEE_OVERLAY     + -com OPEN_WINDOW sagittalimage opacity=9 mont=7x1:6:1:black crop=0:0,0:0 -com OPEN_WINDOW coronalimage  opacity=9 mont=7x1:8:1:black crop=0:0,0:0 -com OPEN_WINDOW axialimage    opacity=9 mont=7x1:5:1:black crop=0:0,0:0 -com SET_PBAR_ALL    +99 1 gray_scale -com PBAR_SAVEIM QC_sub_08/media/qc_00_vorig_EPI.pbar.jpg dim=64x512H -com SET_SUBBRICKS   -1 -1 -1 -com SET_ULAY_RANGE A.all 0 829.000000 -com SET_FUNC_RANGE  829.000000 -com SET_THRESHNEW   0 * -com SET_FUNC_ALPHA  No -com SET_FUNC_BOXED  No -com SET_FUNC_RESAM  NN.NN -com SET_XHAIRS      OFF -com SET_XHAIR_GAP   -1 -com SET_DICOM_XYZ 1.5 8.945793 -26.24097 -com SAVE_JPEG sagittalimage QC_sub_08/media/qc_00_vorig_EPI.sag blowup=4 -com SAVE_JPEG coronalimage  QC_sub_08/media/qc_00_vorig_EPI.cor blowup=4 -com SAVE_JPEG axialimage    QC_sub_08/media/qc_00_vorig_EPI.axi blowup=4 -com QUITT QC_sub_08/media/__tmp_chauf_9t3MZI1OgAi 


+* Removing temporary image directory 'QC_sub_08/media/__tmp_chauf_9t3MZI1OgAi'.

[1]    Done                          Xvfb :204 -screen 0 1024x768x24

++ DONE (good exit)
   see: QC_sub_08/media/qc_00_vorig_EPI*

++ Prepare for running @djunct_edgy_align_check (ver = 1.45)
++ Copy refbox (/opt/afni-latest/MNI_avg152T1+tlrc) to workdir
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./QC_sub_08/media/__workdir_EAC_S9rW96jAAny/REFBOX.nii
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./QC_sub_08/media/__workdir_EAC_S9rW96jAAny/eac_0_cp.nii
++ 3dAllineate: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Zhark the Registrator
++ Source dataset: /home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/afni_pro_glm/sub_08.results/QC_sub_08/media/__workdir_EAC_S9rW96jAAny/eac_0_cp.nii
++ Base dataset:   (not given)
++ Loading datasets into memory
 +        -cmass x y z shifts =    0.000    0.000    0.000
 +  shift search range is +/- =   57.780   69.336   57.780
++ OpenMP thread count = 15
++ ========== Applying transformation to 1 sub-bricks ==========
++ wsinc5 interpolation setup:
 +   taper function  = Min sidelobe 3 term
 +   taper cut point = 0.000
 +   window radius   = 5 voxels
 +   window shape    = Cubical
 +   The above can be altered via the AFNI_WSINC5_* environment variables.
 +  (To avoid this message, 'setenv AFNI_WSINC5_SILENT YES'.)
 +   wsinc5 CUBE(5) mask has 1000 points
++ Output dataset QC_sub_08/media/__workdir_EAC_S9rW96jAAny/eac_1_grid2olay.nii
++ 3dAllineate: total CPU time = 0.0 sec  Elapsed = 0.2
++ ###########################################################
++ Output dataset ./eac_2_ulay_shrp.nii
++ Just copy olay, bc ulay will get regridded
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./QC_sub_08/media/__workdir_EAC_S9rW96jAAny/eac_3_cp.nii
++ 3dAutomask: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Emperor Zhark
++ Loading dataset eac_3_cp.nii
++ Forming automask
 + Fixed clip level = 125.049599
 + Used gradual clip level = 113.553802 .. 136.496994
 + Number voxels above clip level = 226551
 + Clustering voxels ...
 + Largest cluster has 226334 voxels
 + Clustering voxels ...
 + Largest cluster has 221333 voxels
 + Filled  8457 voxels in small holes; now have 229790 voxels
 + Filled  5358 voxels in large holes; now have 235148 voxels
 + Clustering voxels ...
 + Largest cluster has 235139 voxels
 + Clustering non-brain voxels ...
 + Clustering voxels ...
 + Largest cluster has 667426 voxels
 + Mask now has 235203 voxels
++ 235203 voxels in the mask [out of 902629: 26.06%]
++ first   9 x-planes are zero [from L]
++ last    6 x-planes are zero [from R]
++ first  10 y-planes are zero [from P]
++ last    8 y-planes are zero [from A]
++ first   3 z-planes are zero [from I]
++ last   11 z-planes are zero [from S]
++ Output dataset ./eac_4_mask.nii
++ CPU time = 0.000000 sec
++ 3dMedianFilter: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Output dataset ./eac_5_mfilt.nii
++ 3dedge3: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ olay_alpha has known value: No

++ My command:
   @chauffeur_afni -ulay eac_2_ulay_shrp.nii -box_focus_slices REFBOX.nii -olay eac_6_edgy.nii -ulay_range_nz 2% 98% -func_range_perc_nz 33 -cbar Reds_and_Blues_Inv -set_subbricks 0 0 0 -olay_alpha No -olay_boxed No -thr_olay 38.126259 -opacity 9 -prefix ../qc_01_ve2a_epi2anat -montx 7 -monty 1 -montgap 1 -montcolor black -save_ftype JPEG -set_xhairs OFF -label_mode 1 -label_size 3 -do_clean -pass

++ Using AFNI ver : AFNI_21.2.00
++ chauffeur ver  : 6.26

------------------ start of optionizing ------------------

++ Found input file:   eac_2_ulay_shrp.nii
++ Found input file:   eac_6_edgy.nii
++ Found focus refbox file:   REFBOX.nii
++ Using blowup factor: 2
++ Using opacity:  9
++ Making temporary work directory to copy vis files: ../__tmp_chauf_Y7rYokZCYPP
++ Converted 0 to labels
++ Final subbrick indices: 0 0 0
++ Copy ulay to visualize (volumetric) within user's range:
++ Ulay to be visualized within user range:
  [2%, 98%] -> [0.340431, 853.099365]
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./../__tmp_chauf_Y7rYokZCYPP/tmp_ulay.nii
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./../__tmp_chauf_Y7rYokZCYPP/tmp_olay.nii
++ For olay, the 33%ile value leads to
   --> upper range value: 99.547501
++ Dimensions (xyzt): 91 109 91 1
++ (initial) Slice spacing ordered (x,y,z) is:  13 15 13
++ 3dAutobox: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Auto bbox: x=10..81  y=10..101  z=3..78
++ 3dAutobox: output dataset = ../__tmp_chauf_Y7rYokZCYPP/ulay_box_0.nii
++ 3dmaskdump: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Executing 3dcalc()
 argv[0]=3dcalc argv[1]=-a argv[2]=../__tmp_chauf_Y7rYokZCYPP/ulay_box_0.nii[0] argv[3]=-expr argv[4]=a argv[5]=-byte argv[6]=-session argv[7]=/tmp argv[8]=-prefix argv[9]=3dcalc_XYZ_syOIEalEhstY9tRTfSk_XA argv[10]=-verbose
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Computing sub-brick 0
++ Scaling output to type byte brick(s)
++ Sub-brick 0 scale factor = 314.130402
++ Computing output statistics
++ Output dataset /tmp/3dcalc_XYZ_syOIEalEhstY9tRTfSk_XA+tlrc.BRIK
++ 503424 voxels in the entire dataset (no mask)
++ 1 voxels in the boxes and/or balls
++ Using only the boxes+balls mask
++ How many coors? 3
++ Will have the ref box central coors : SET_DICOM_XYZ 0 16 10
++ Will have the ref box central gapord: 10 13 10

------------------- end of optionizing -------------------

 -- trying to start Xvfb :195 
[1] 474880
_XSERVTransmkdir: Owner of /tmp/.X11-unix should be set to root
+/home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/afni_pro_glm/sub_08.results/QC_sub_08/media/__tmp_chauf_Y7rYokZCYPP++ Writing one 1538x182 image to filter '/opt/afni-latest/cjpeg -quality 95 > ../qc_01_ve2a_epi2anat.sag.jpg'
++ Writing one 1286x182 image to filter '/opt/afni-latest/cjpeg -quality 95 > ../qc_01_ve2a_epi2anat.cor.jpg'
++ Writing one 1286x218 image to filter '/opt/afni-latest/cjpeg -quality 95 > ../qc_01_ve2a_epi2anat.axi.jpg'

AFNI QUITTs!

+++ Command Echo:
   afni -q -no1D -noplugins -no_detach -com SWITCH_UNDERLAY tmp_ulay.nii -com SWITCH_OVERLAY  tmp_olay.nii -com SEE_OVERLAY     + -com OPEN_WINDOW sagittalimage opacity=9 mont=7x1:10:1:black crop=0:0,0:0 -com OPEN_WINDOW coronalimage  opacity=9 mont=7x1:13:1:black crop=0:0,0:0 -com OPEN_WINDOW axialimage    opacity=9 mont=7x1:10:1:black crop=0:0,0:0 -com SET_PBAR_ALL    -99 1 Reds_and_Blues_Inv -com DO_NOTHING -com SET_SUBBRICKS   0 0 0 -com SET_ULAY_RANGE A.all 0.340431 853.099365 -com SET_FUNC_RANGE  99.547501 -com SET_THRESHNEW   38.126259 * -com SET_FUNC_ALPHA  No -com SET_FUNC_BOXED  No -com SET_FUNC_RESAM  NN.NN -com SET_XHAIRS      OFF -com SET_XHAIR_GAP   -1 -com SET_DICOM_XYZ 0 16 10 -com SAVE_JPEG sagittalimage ../qc_01_ve2a_epi2anat.sag blowup=2 -com SAVE_JPEG coronalimage  ../qc_01_ve2a_epi2anat.cor blowup=2 -com SAVE_JPEG axialimage    ../qc_01_ve2a_epi2anat.axi blowup=2 -com QUITT ../__tmp_chauf_Y7rYokZCYPP 


+* Removing temporary image directory '../__tmp_chauf_Y7rYokZCYPP'.

[1]    Done                          Xvfb :195 -screen 0 1024x768x24

++ DONE (good exit)
   see: ../qc_01_ve2a_epi2anat*


+* Removing temporary workdir 'QC_sub_08/media/__workdir_EAC_S9rW96jAAny*'


++ DONE! Image output:
       QC_sub_08/media/qc_01_ve2a_epi2anat

++ Prepare for running @djunct_edgy_align_check (ver = 1.45)
++ Copy refbox (/opt/afni-latest/MNI_avg152T1+tlrc) to workdir
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./QC_sub_08/media/__workdir_EAC_puwVfbOsxyP/REFBOX.nii
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./QC_sub_08/media/__workdir_EAC_puwVfbOsxyP/eac_0_cp.nii
++ Output dataset ./eac_1_ulay_shrp.nii
++ 3dAllineate: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Zhark the Registrator
++ Source dataset: /opt/afni-latest/MNI_avg152T1+tlrc.HEAD
++ Base dataset:   (not given)
++ Loading datasets into memory
 +        -cmass x y z shifts =    0.000    0.000    0.000
 +  shift search range is +/- =   57.780   69.336   57.780
++ OpenMP thread count = 15
++ ========== Applying transformation to 1 sub-bricks ==========
++ Output dataset QC_sub_08/media/__workdir_EAC_puwVfbOsxyP/eac_2_res.nii
++ 3dAllineate: total CPU time = 0.0 sec  Elapsed = 0.1
++ ###########################################################
++ 3dAutomask: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Emperor Zhark
++ Loading dataset eac_2_res.nii
++ Forming automask
 + Fixed clip level = 0.298080
 + Used gradual clip level = 0.286276 .. 0.307885
 + Number voxels above clip level = 231114
 + Clustering voxels ...
 + Largest cluster has 231101 voxels
 + Clustering voxels ...
 + Largest cluster has 230543 voxels
 + Filled  1108 voxels in small holes; now have 231651 voxels
 + Filled  1424 voxels in large holes; now have 233075 voxels
 + Clustering voxels ...
 + Largest cluster has 233075 voxels
 + Clustering non-brain voxels ...
 + Clustering voxels ...
 + Largest cluster has 669554 voxels
 + Mask now has 233075 voxels
++ 233075 voxels in the mask [out of 902629: 25.82%]
++ first  10 x-planes are zero [from L]
++ last    9 x-planes are zero [from R]
++ first  11 y-planes are zero [from P]
++ last    9 y-planes are zero [from A]
++ first   3 z-planes are zero [from I]
++ last   13 z-planes are zero [from S]
++ Output dataset ./eac_3_mask.nii
++ CPU time = 0.000000 sec
++ 3dMedianFilter: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Output dataset ./eac_4_mfilt.nii
++ 3dedge3: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ olay_alpha has known value: No

++ My command:
   @chauffeur_afni -ulay eac_1_ulay_shrp.nii -box_focus_slices REFBOX.nii -olay eac_5_edgy.nii -ulay_range 0% 120% -func_range_perc_nz 33 -cbar Reds_and_Blues_Inv -set_subbricks 0 0 0 -olay_alpha No -olay_boxed No -thr_olay 0.500561 -opacity 9 -prefix ../qc_02_va2t_anat2temp -montx 7 -monty 1 -montgap 1 -montcolor black -save_ftype JPEG -set_xhairs OFF -label_mode 1 -label_size 3 -do_clean -pass

++ Using AFNI ver : AFNI_21.2.00
++ chauffeur ver  : 6.26

------------------ start of optionizing ------------------

++ Found input file:   eac_1_ulay_shrp.nii
++ Found input file:   eac_5_edgy.nii
++ Found focus refbox file:   REFBOX.nii
++ Using blowup factor: 2
++ Using opacity:  9
++ Making temporary work directory to copy vis files: ../__tmp_chauf_kZKrrbNX9BO
++ Converted 0 to labels
++ Final subbrick indices: 0 0 0
++ Copy ulay to visualize (volumetric) within user's range:
++ Ulay range calc for >100%ile ulay max:
   calculating 98%ile value, and then
   multiplying it by a scale factor = 1.22448,
   in order to produce the 98%ile value
++ Ulay to be visualized within user range:
  [0%, 120%] -> [0.000000, 481.832880]
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./../__tmp_chauf_kZKrrbNX9BO/tmp_ulay.nii
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./../__tmp_chauf_kZKrrbNX9BO/tmp_olay.nii
++ For olay, the 33%ile value leads to
   --> upper range value: 0.519532
++ Dimensions (xyzt): 91 109 91 1
++ (initial) Slice spacing ordered (x,y,z) is:  13 15 13
++ 3dAutobox: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Auto bbox: x=10..81  y=10..101  z=3..78
++ 3dAutobox: output dataset = ../__tmp_chauf_kZKrrbNX9BO/ulay_box_0.nii
++ 3dmaskdump: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Executing 3dcalc()
 argv[0]=3dcalc argv[1]=-a argv[2]=../__tmp_chauf_kZKrrbNX9BO/ulay_box_0.nii[0] argv[3]=-expr argv[4]=a argv[5]=-byte argv[6]=-session argv[7]=/tmp argv[8]=-prefix argv[9]=3dcalc_XYZ_HNs9p0GnClsTmyVg7C7oKA argv[10]=-verbose
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Computing sub-brick 0
++ Scaling output to type byte brick(s)
++ Sub-brick 0 scale factor = 314.130402
++ Computing output statistics
++ Output dataset /tmp/3dcalc_XYZ_HNs9p0GnClsTmyVg7C7oKA+tlrc.BRIK
++ 503424 voxels in the entire dataset (no mask)
++ 1 voxels in the boxes and/or balls
++ Using only the boxes+balls mask
++ How many coors? 3
++ Will have the ref box central coors : SET_DICOM_XYZ 0 16 10
++ Will have the ref box central gapord: 10 13 10

------------------- end of optionizing -------------------

 -- trying to start Xvfb :887 
[1] 475387
_XSERVTransmkdir: Owner of /tmp/.X11-unix should be set to root
+/home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/afni_pro_glm/sub_08.results/QC_sub_08/media/__tmp_chauf_kZKrrbNX9BO++ Writing one 1538x182 image to filter '/opt/afni-latest/cjpeg -quality 95 > ../qc_02_va2t_anat2temp.sag.jpg'
++ Writing one 1286x182 image to filter '/opt/afni-latest/cjpeg -quality 95 > ../qc_02_va2t_anat2temp.cor.jpg'
++ Writing one 1286x218 image to filter '/opt/afni-latest/cjpeg -quality 95 > ../qc_02_va2t_anat2temp.axi.jpg'

AFNI QUITTs!

+++ Command Echo:
   afni -q -no1D -noplugins -no_detach -com SWITCH_UNDERLAY tmp_ulay.nii -com SWITCH_OVERLAY  tmp_olay.nii -com SEE_OVERLAY     + -com OPEN_WINDOW sagittalimage opacity=9 mont=7x1:10:1:black crop=0:0,0:0 -com OPEN_WINDOW coronalimage  opacity=9 mont=7x1:13:1:black crop=0:0,0:0 -com OPEN_WINDOW axialimage    opacity=9 mont=7x1:10:1:black crop=0:0,0:0 -com SET_PBAR_ALL    -99 1 Reds_and_Blues_Inv -com DO_NOTHING -com SET_SUBBRICKS   0 0 0 -com SET_ULAY_RANGE A.all 0.000000 481.832880 -com SET_FUNC_RANGE  0.519532 -com SET_THRESHNEW   0.500561 * -com SET_FUNC_ALPHA  No -com SET_FUNC_BOXED  No -com SET_FUNC_RESAM  NN.NN -com SET_XHAIRS      OFF -com SET_XHAIR_GAP   -1 -com SET_DICOM_XYZ 0 16 10 -com SAVE_JPEG sagittalimage ../qc_02_va2t_anat2temp.sag blowup=2 -com SAVE_JPEG coronalimage  ../qc_02_va2t_anat2temp.cor blowup=2 -com SAVE_JPEG axialimage    ../qc_02_va2t_anat2temp.axi blowup=2 -com QUITT ../__tmp_chauf_kZKrrbNX9BO 


+* Removing temporary image directory '../__tmp_chauf_kZKrrbNX9BO'.

[1]    Done                          Xvfb :887 -screen 0 1024x768x24

++ DONE (good exit)
   see: ../qc_02_va2t_anat2temp*


+* Removing temporary workdir 'QC_sub_08/media/__workdir_EAC_puwVfbOsxyP*'


++ DONE! Image output:
       QC_sub_08/media/qc_02_va2t_anat2temp

++ olay_alpha has known value: Yes
++ pbar name has known extension: jpg
++ My command:
   @chauffeur_afni -ulay /opt/afni-latest/MNI_avg152T1+tlrc -box_focus_slices /opt/afni-latest/MNI_avg152T1+tlrc -olay stats.sub_08_REML+tlrc.HEAD -cbar Plasma -pbar_posonly -ulay_range 0% 120% -func_range 16.247768 -thr_olay 4.841945 -olay_alpha Yes -olay_boxed Yes -set_subbricks 0 0 0 -opacity 9 -pbar_saveim QC_sub_08/media/qc_03_vstat_Full_Fstat.pbar.jpg -pbar_comm_range 99%ile in mask -pbar_comm_thr 90%ile in mask, alpha+boxed on -prefix QC_sub_08/media/qc_03_vstat_Full_Fstat -save_ftype JPEG -montx 7 -monty 1 -montgap 1 -montcolor black -set_xhairs OFF -label_mode 1 -label_size 3 -do_clean

++ Using AFNI ver : AFNI_21.2.00
++ chauffeur ver  : 6.26

------------------ start of optionizing ------------------

++ Found input file:   /opt/afni-latest/MNI_avg152T1+tlrc
++ Found input file:   stats.sub_08_REML+tlrc.HEAD
++ Found focus refbox file:   /opt/afni-latest/MNI_avg152T1+tlrc
++ Using blowup factor: 2
++ Using opacity:  9
++ Making temporary work directory to copy vis files: QC_sub_08/media/__tmp_chauf_RIc1A3P5Lfs
++ Converted 0 to labels
++ Final subbrick indices: 0 0 0
++ Copy ulay to visualize (volumetric) within user's range:
++ Ulay range calc for >100%ile ulay max:
   calculating 98%ile value, and then
   multiplying it by a scale factor = 1.22448,
   in order to produce the 98%ile value
++ Ulay to be visualized within user range:
  [0%, 120%] -> [0.000000, .893150]
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./QC_sub_08/media/__tmp_chauf_RIc1A3P5Lfs/tmp_ulay.nii
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./QC_sub_08/media/__tmp_chauf_RIc1A3P5Lfs/tmp_olay.nii
++ User-entered function range value value (16.247768)
++ Dimensions (xyzt): 91 109 91 1
++ (initial) Slice spacing ordered (x,y,z) is:  13 15 13
++ 3dAutobox: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Auto bbox: x=10..81  y=10..101  z=3..78
++ 3dAutobox: output dataset = QC_sub_08/media/__tmp_chauf_RIc1A3P5Lfs/ulay_box_0.nii
++ 3dmaskdump: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Executing 3dcalc()
 argv[0]=3dcalc argv[1]=-a argv[2]=QC_sub_08/media/__tmp_chauf_RIc1A3P5Lfs/ulay_box_0.nii[0] argv[3]=-expr argv[4]=a argv[5]=-byte argv[6]=-session argv[7]=/tmp argv[8]=-prefix argv[9]=3dcalc_XYZ_5LfIQJma2lf0xXmmrFCTgg argv[10]=-verbose
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Computing sub-brick 0
++ Scaling output to type byte brick(s)
++ Sub-brick 0 scale factor = 314.130402
++ Computing output statistics
++ Output dataset /tmp/3dcalc_XYZ_5LfIQJma2lf0xXmmrFCTgg+tlrc.BRIK
++ 503424 voxels in the entire dataset (no mask)
++ 1 voxels in the boxes and/or balls
++ Using only the boxes+balls mask
++ How many coors? 3
++ Will have the ref box central coors : SET_DICOM_XYZ 0 16 10
++ Will have the ref box central gapord: 10 13 10

------------------- end of optionizing -------------------

 -- trying to start Xvfb :714 
[1] 476115
_XSERVTransmkdir: Owner of /tmp/.X11-unix should be set to root
+/home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/afni_pro_glm/sub_08.results/QC_sub_08/media/__tmp_chauf_RIc1A3P5Lfs++ Writing palette image to QC_sub_08/media/qc_03_vstat_Full_Fstat.pbar.jpg
++ Writing one 1538x182 image to filter '/opt/afni-latest/cjpeg -quality 95 > QC_sub_08/media/qc_03_vstat_Full_Fstat.sag.jpg'
++ Writing one 1286x182 image to filter '/opt/afni-latest/cjpeg -quality 95 > QC_sub_08/media/qc_03_vstat_Full_Fstat.cor.jpg'
++ Writing one 1286x218 image to filter '/opt/afni-latest/cjpeg -quality 95 > QC_sub_08/media/qc_03_vstat_Full_Fstat.axi.jpg'

AFNI QUITTs!

+++ Command Echo:
   afni -q -no1D -noplugins -no_detach -com SWITCH_UNDERLAY tmp_ulay.nii -com SWITCH_OVERLAY  tmp_olay.nii -com SEE_OVERLAY     + -com OPEN_WINDOW sagittalimage opacity=9 mont=7x1:10:1:black crop=0:0,0:0 -com OPEN_WINDOW coronalimage  opacity=9 mont=7x1:13:1:black crop=0:0,0:0 -com OPEN_WINDOW axialimage    opacity=9 mont=7x1:10:1:black crop=0:0,0:0 -com SET_PBAR_ALL    +99 1 Plasma -com PBAR_SAVEIM QC_sub_08/media/qc_03_vstat_Full_Fstat.pbar.jpg dim=64x512H -com SET_SUBBRICKS   0 0 0 -com SET_ULAY_RANGE A.all 0.000000 .893150 -com SET_FUNC_RANGE  16.247768 -com SET_THRESHNEW   4.841945 * -com SET_FUNC_ALPHA  Yes -com SET_FUNC_BOXED  Yes -com SET_FUNC_RESAM  NN.NN -com SET_XHAIRS      OFF -com SET_XHAIR_GAP   -1 -com SET_DICOM_XYZ 0 16 10 -com SAVE_JPEG sagittalimage QC_sub_08/media/qc_03_vstat_Full_Fstat.sag blowup=2 -com SAVE_JPEG coronalimage  QC_sub_08/media/qc_03_vstat_Full_Fstat.cor blowup=2 -com SAVE_JPEG axialimage    QC_sub_08/media/qc_03_vstat_Full_Fstat.axi blowup=2 -com QUITT QC_sub_08/media/__tmp_chauf_RIc1A3P5Lfs 


+* Removing temporary image directory 'QC_sub_08/media/__tmp_chauf_RIc1A3P5Lfs'.

[1]    Done                          Xvfb :714 -screen 0 1024x768x24

++ DONE (good exit)
   see: QC_sub_08/media/qc_03_vstat_Full_Fstat*

/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
Traceback (most recent call last):
  File "/opt/afni-latest/1dplot.py", line 50, in <module>
    from afnipy import lib_plot_1D as lpod
  File "/opt/afni-latest/afnipy/lib_plot_1D.py", line 39, in <module>
    import matplotlib.pyplot  as plt
ModuleNotFoundError: No module named 'matplotlib'
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
Traceback (most recent call last):
  File "/opt/afni-latest/1dplot.py", line 50, in <module>
    from afnipy import lib_plot_1D as lpod
  File "/opt/afni-latest/afnipy/lib_plot_1D.py", line 39, in <module>
    import matplotlib.pyplot  as plt
ModuleNotFoundError: No module named 'matplotlib'
++ 3dGrayplot: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
 + Loading dataset ./errts.sub_08_REML+tlrc.HEAD
 + Number of voxels in mask = 68948
 + 3dGrayplot: Elapsed = 8.4 s
++ pbar name has known extension: jpg
++ My command:
   @chauffeur_afni -ulay full_mask.sub_08+tlrc.HEAD -olay full_mask.sub_08+tlrc.HEAD -box_focus_slices AMASK_FOCUS_OLAY -cbar gray_scale -func_range 3.29 -blowup 1 -set_subbricks 0 0 0 -opacity 9 -pbar_saveim QC_sub_08/media/qc_06_mot_grayplot.pbar.jpg -pbar_comm_range for normal distr, bounds of 0.001 prob tail -prefix __tmp_ZXCV_img -save_ftype JPEG -montx 1 -monty 1 -set_xhairs OFF -label_mode 1 -label_size 3 -do_clean

++ Using AFNI ver : AFNI_21.2.00
++ chauffeur ver  : 6.26

------------------ start of optionizing ------------------

++ Found input file:   full_mask.sub_08+tlrc.HEAD
++ Found input file:   full_mask.sub_08+tlrc.HEAD
++ Using blowup factor: 1
++ Using opacity:  9
++ Making temporary work directory to copy vis files: ./__tmp_chauf_1UXyS66kodz
++ Converted 0 to labels
++ Final subbrick indices: 0 0 0
++ Copy ulay to visualize (volumetric) within user's range:
++ Ulay to be visualized within user range:
  [0%, 98%] -> [0.000000, 1.000000]
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ././__tmp_chauf_1UXyS66kodz/tmp_ulay.nii
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ././__tmp_chauf_1UXyS66kodz/tmp_olay.nii
++ User-entered function range value value (3.29)
++ Dimensions (xyzt): 61 73 61 1
++ (initial) Slice spacing ordered (x,y,z) is:  61 73 61
++ 3dAutomask: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: Emperor Zhark
++ 3dAutobox: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Auto bbox: x=0..60  y=0..72  z=0..60
++ THD_zeropad: all pad values are zero - just copying dataset
++ 3dAutobox: output dataset = ./__tmp_chauf_1UXyS66kodz/ulay_box_0.nii
++ 3dmaskdump: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Executing 3dcalc()
 argv[0]=3dcalc argv[1]=-a argv[2]=./__tmp_chauf_1UXyS66kodz/ulay_box_0.nii[0] argv[3]=-expr argv[4]=a argv[5]=-byte argv[6]=-session argv[7]=/tmp argv[8]=-prefix argv[9]=3dcalc_XYZ_4jCjngDrOFfg8kfbqKMAwQ argv[10]=-verbose
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Computing sub-brick 0
++ Scaling output to type byte brick(s)
++ Sub-brick 0: no scale factor
++ Computing output statistics
++ Output dataset /tmp/3dcalc_XYZ_4jCjngDrOFfg8kfbqKMAwQ+tlrc.BRIK
++ 271633 voxels in the entire dataset (no mask)
++ 1 voxels in the boxes and/or balls
++ Using only the boxes+balls mask
++ How many coors? 3
++ Will have the ref box central coors : SET_DICOM_XYZ 3 18 18
++ Will have the ref box central gapord: 61 73 61

------------------- end of optionizing -------------------

 -- trying to start Xvfb :138 
[1] 476846
_XSERVTransmkdir: Owner of /tmp/.X11-unix should be set to root
+/home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/afni_pro_glm/sub_08.results/__tmp_chauf_1UXyS66kodz++ Writing palette image to QC_sub_08/media/qc_06_mot_grayplot.pbar.jpg
++ Writing one 73x61 image to filter '/opt/afni-latest/cjpeg -quality 95 > ./__tmp_ZXCV_img.sag.jpg'
++ Writing one 61x61 image to filter '/opt/afni-latest/cjpeg -quality 95 > ./__tmp_ZXCV_img.cor.jpg'
++ Writing one 61x73 image to filter '/opt/afni-latest/cjpeg -quality 95 > ./__tmp_ZXCV_img.axi.jpg'

AFNI QUITTs!

+++ Command Echo:
   afni -q -no1D -noplugins -no_detach -com SWITCH_UNDERLAY tmp_ulay.nii -com SWITCH_OVERLAY  tmp_olay.nii -com SEE_OVERLAY     + -com OPEN_WINDOW sagittalimage opacity=9 mont=1x1:61:0:black crop=0:0,0:0 -com OPEN_WINDOW coronalimage  opacity=9 mont=1x1:73:0:black crop=0:0,0:0 -com OPEN_WINDOW axialimage    opacity=9 mont=1x1:61:0:black crop=0:0,0:0 -com SET_PBAR_ALL    -99 1 gray_scale -com PBAR_SAVEIM QC_sub_08/media/qc_06_mot_grayplot.pbar.jpg dim=64x512H -com SET_SUBBRICKS   0 0 0 -com SET_ULAY_RANGE A.all 0.000000 1.000000 -com SET_FUNC_RANGE  3.29 -com SET_THRESHNEW   0 * -com SET_FUNC_ALPHA  No -com SET_FUNC_BOXED  No -com SET_FUNC_RESAM  NN.NN -com SET_XHAIRS      OFF -com SET_XHAIR_GAP   -1 -com SET_DICOM_XYZ 3 18 18 -com SAVE_JPEG sagittalimage ./__tmp_ZXCV_img.sag blowup=1 -com SAVE_JPEG coronalimage  ./__tmp_ZXCV_img.cor blowup=1 -com SAVE_JPEG axialimage    ./__tmp_ZXCV_img.axi blowup=1 -com QUITT ./__tmp_chauf_1UXyS66kodz 


+* Removing temporary image directory './__tmp_chauf_1UXyS66kodz'.


++ DONE (good exit)
   see: ./__tmp_ZXCV_img*

/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
Traceback (most recent call last):
  File "/opt/afni-latest/1dplot.py", line 50, in <module>
    from afnipy import lib_plot_1D as lpod
  File "/opt/afni-latest/afnipy/lib_plot_1D.py", line 39, in <module>
    import matplotlib.pyplot  as plt
ModuleNotFoundError: No module named 'matplotlib'
djpeg: can't open __tmp_img_enorm.jpg
pnmcat: Error reading first byte of what is expected to be a Netpbm magic number.  Most often, this means your input file is empty
Empty input file

+* Removing temporary files '__tmp_gluing*'


++ DONE! Image output:
       QC_sub_08/media/qc_06_mot_grayplot.jpg

rm: cannot remove '__tmp_img_enorm.jpg': No such file or directory
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
Traceback (most recent call last):
  File "/opt/afni-latest/1dplot.py", line 50, in <module>
    from afnipy import lib_plot_1D as lpod
  File "/opt/afni-latest/afnipy/lib_plot_1D.py", line 39, in <module>
    import matplotlib.pyplot  as plt
ModuleNotFoundError: No module named 'matplotlib'
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
Traceback (most recent call last):
  File "/opt/afni-latest/1dplot.py", line 50, in <module>
    from afnipy import lib_plot_1D as lpod
  File "/opt/afni-latest/afnipy/lib_plot_1D.py", line 39, in <module>
    import matplotlib.pyplot  as plt
ModuleNotFoundError: No module named 'matplotlib'
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
++ Check summary of degrees of freedom in: QC_sub_08/media/qc_09_regr_df.dat
++ olay_alpha has known value: Yes
++ pbar name has known extension: jpg
++ My command:
   @chauffeur_afni -ulay /opt/afni-latest/MNI_avg152T1+tlrc -box_focus_slices /opt/afni-latest/MNI_avg152T1+tlrc -olay corr_brain+tlrc.HEAD -cbar Reds_and_Blues_Inv -ulay_range 0% 120% -func_range 0.6 -thr_olay 0.3 -olay_alpha Yes -olay_boxed Yes -set_subbricks 0 0 0 -opacity 9 -pbar_saveim QC_sub_08/media/qc_10_regr_corr_errts.pbar.jpg -pbar_comm_range Pearson r -pbar_comm_thr alpha+boxed on -prefix QC_sub_08/media/qc_10_regr_corr_errts -save_ftype JPEG -montx 7 -monty 1 -montgap 1 -montcolor black -set_xhairs OFF -label_mode 1 -label_size 3 -do_clean

++ Using AFNI ver : AFNI_21.2.00
++ chauffeur ver  : 6.26

------------------ start of optionizing ------------------

++ Found input file:   /opt/afni-latest/MNI_avg152T1+tlrc
++ Found input file:   corr_brain+tlrc.HEAD
++ Found focus refbox file:   /opt/afni-latest/MNI_avg152T1+tlrc
++ Using blowup factor: 2
++ Using opacity:  9
++ Making temporary work directory to copy vis files: QC_sub_08/media/__tmp_chauf_0ctY7xOMulm
++ Converted 0 to labels
++ Final subbrick indices: 0 0 0
++ Copy ulay to visualize (volumetric) within user's range:
++ Ulay range calc for >100%ile ulay max:
   calculating 98%ile value, and then
   multiplying it by a scale factor = 1.22448,
   in order to produce the 98%ile value
++ Ulay to be visualized within user range:
  [0%, 120%] -> [0.000000, .893150]
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./QC_sub_08/media/__tmp_chauf_0ctY7xOMulm/tmp_ulay.nii
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./QC_sub_08/media/__tmp_chauf_0ctY7xOMulm/tmp_olay.nii
++ User-entered function range value value (0.6)
++ Dimensions (xyzt): 91 109 91 1
++ (initial) Slice spacing ordered (x,y,z) is:  13 15 13
++ 3dAutobox: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Auto bbox: x=10..81  y=10..101  z=3..78
++ 3dAutobox: output dataset = QC_sub_08/media/__tmp_chauf_0ctY7xOMulm/ulay_box_0.nii
++ 3dmaskdump: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Executing 3dcalc()
 argv[0]=3dcalc argv[1]=-a argv[2]=QC_sub_08/media/__tmp_chauf_0ctY7xOMulm/ulay_box_0.nii[0] argv[3]=-expr argv[4]=a argv[5]=-byte argv[6]=-session argv[7]=/tmp argv[8]=-prefix argv[9]=3dcalc_XYZ_ioqpO9xu8c4CL1Ohrtz_Sw argv[10]=-verbose
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Computing sub-brick 0
++ Scaling output to type byte brick(s)
++ Sub-brick 0 scale factor = 314.130402
++ Computing output statistics
++ Output dataset /tmp/3dcalc_XYZ_ioqpO9xu8c4CL1Ohrtz_Sw+tlrc.BRIK
++ 503424 voxels in the entire dataset (no mask)
++ 1 voxels in the boxes and/or balls
++ Using only the boxes+balls mask
++ How many coors? 3
++ Will have the ref box central coors : SET_DICOM_XYZ 0 16 10
++ Will have the ref box central gapord: 10 13 10

------------------- end of optionizing -------------------

 -- trying to start Xvfb :27 
[1] 477741
_XSERVTransmkdir: Owner of /tmp/.X11-unix should be set to root
+/home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/afni_pro_glm/sub_08.results/QC_sub_08/media/__tmp_chauf_0ctY7xOMulm++ Writing palette image to QC_sub_08/media/qc_10_regr_corr_errts.pbar.jpg
++ Writing one 1538x182 image to filter '/opt/afni-latest/cjpeg -quality 95 > QC_sub_08/media/qc_10_regr_corr_errts.sag.jpg'
++ Writing one 1286x182 image to filter '/opt/afni-latest/cjpeg -quality 95 > QC_sub_08/media/qc_10_regr_corr_errts.cor.jpg'
++ Writing one 1286x218 image to filter '/opt/afni-latest/cjpeg -quality 95 > QC_sub_08/media/qc_10_regr_corr_errts.axi.jpg'

AFNI QUITTs!

+++ Command Echo:
   afni -q -no1D -noplugins -no_detach -com SWITCH_UNDERLAY tmp_ulay.nii -com SWITCH_OVERLAY  tmp_olay.nii -com SEE_OVERLAY     + -com OPEN_WINDOW sagittalimage opacity=9 mont=7x1:10:1:black crop=0:0,0:0 -com OPEN_WINDOW coronalimage  opacity=9 mont=7x1:13:1:black crop=0:0,0:0 -com OPEN_WINDOW axialimage    opacity=9 mont=7x1:10:1:black crop=0:0,0:0 -com SET_PBAR_ALL    -99 1 Reds_and_Blues_Inv -com PBAR_SAVEIM QC_sub_08/media/qc_10_regr_corr_errts.pbar.jpg dim=64x512H -com SET_SUBBRICKS   0 0 0 -com SET_ULAY_RANGE A.all 0.000000 .893150 -com SET_FUNC_RANGE  0.6 -com SET_THRESHNEW   0.3 * -com SET_FUNC_ALPHA  Yes -com SET_FUNC_BOXED  Yes -com SET_FUNC_RESAM  NN.NN -com SET_XHAIRS      OFF -com SET_XHAIR_GAP   -1 -com SET_DICOM_XYZ 0 16 10 -com SAVE_JPEG sagittalimage QC_sub_08/media/qc_10_regr_corr_errts.sag blowup=2 -com SAVE_JPEG coronalimage  QC_sub_08/media/qc_10_regr_corr_errts.cor blowup=2 -com SAVE_JPEG axialimage    QC_sub_08/media/qc_10_regr_corr_errts.axi blowup=2 -com QUITT QC_sub_08/media/__tmp_chauf_0ctY7xOMulm 


+* Removing temporary image directory 'QC_sub_08/media/__tmp_chauf_0ctY7xOMulm'.

[1]    Done                          Xvfb :27 -screen 0 1024x768x24

++ DONE (good exit)
   see: QC_sub_08/media/qc_10_regr_corr_errts*

++ Prepare for running adjunct_apqc_tsnr_general (ver = 1.1)
++ MODE: 10
++ olay_alpha has known value: No
*+ Setting pbar file extension: jpg


++ My command:
   @chauffeur_afni -ulay /opt/afni-latest/MNI_avg152T1+tlrc -olay TSNR.sub_08+tlrc.HEAD -ulay_range 0% 120% -func_range 187 -box_focus_slices /opt/afni-latest/MNI_avg152T1+tlrc -set_subbricks 0 0 0 -pbar_posonly -blowup 2 -cbar   187=red  166=oran-red  146=orange  126=oran-yell  105=yell-oran  85=yellow  65=lt-blue2  36=blue  0=none -cbar_ncolors 8 -cbar_topval EMPTY -opacity 4 -olay_alpha No -olay_boxed No -thr_olay 0 -pbar_saveim QC_sub_08/media/qc_11_regr_tsnr_fin.pbar -pbar_comm_range 95%ile in mask -pbar_comm_gen  cbar: hot color range (5-95%ile TSNR in mask):  65 - 187 -prefix QC_sub_08/media/qc_11_regr_tsnr_fin -save_ftype JPEG -montx 7 -monty 1 -montgap 1 -montcolor black -set_xhairs OFF -label_mode 1 -label_size 3 -do_clean -pass -pass

++ Using AFNI ver : AFNI_21.2.00
++ chauffeur ver  : 6.26

------------------ start of optionizing ------------------

++ Found input file:   /opt/afni-latest/MNI_avg152T1+tlrc
++ Found input file:   TSNR.sub_08+tlrc.HEAD
++ Found focus refbox file:   /opt/afni-latest/MNI_avg152T1+tlrc
++ Using blowup factor: 2
++ Using opacity:  4
++ Making temporary work directory to copy vis files: QC_sub_08/media/__tmp_chauf_ApCgHDTmsbC
++ Converted 0 to labels
++ Final subbrick indices: 0 0 0
++ Copy ulay to visualize (volumetric) within user's range:
++ Ulay range calc for >100%ile ulay max:
   calculating 98%ile value, and then
   multiplying it by a scale factor = 1.22448,
   in order to produce the 98%ile value
++ Ulay to be visualized within user range:
  [0%, 120%] -> [0.000000, .893150]
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./QC_sub_08/media/__tmp_chauf_ApCgHDTmsbC/tmp_ulay.nii
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Output dataset ./QC_sub_08/media/__tmp_chauf_ApCgHDTmsbC/tmp_olay.nii
++ User-entered function range value value (187)
++ Dimensions (xyzt): 91 109 91 1
++ (initial) Slice spacing ordered (x,y,z) is:  13 15 13
++ 3dAutobox: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Auto bbox: x=10..81  y=10..101  z=3..78
++ 3dAutobox: output dataset = QC_sub_08/media/__tmp_chauf_ApCgHDTmsbC/ulay_box_0.nii
++ 3dmaskdump: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Executing 3dcalc()
 argv[0]=3dcalc argv[1]=-a argv[2]=QC_sub_08/media/__tmp_chauf_ApCgHDTmsbC/ulay_box_0.nii[0] argv[3]=-expr argv[4]=a argv[5]=-byte argv[6]=-session argv[7]=/tmp argv[8]=-prefix argv[9]=3dcalc_XYZ_hi7FvYWkOu-Y-oAjK1_msw argv[10]=-verbose
++ 3dcalc: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
++ Authored by: A cast of thousands
++ Computing sub-brick 0
++ Scaling output to type byte brick(s)
++ Sub-brick 0 scale factor = 314.130402
++ Computing output statistics
++ Output dataset /tmp/3dcalc_XYZ_hi7FvYWkOu-Y-oAjK1_msw+tlrc.BRIK
++ 503424 voxels in the entire dataset (no mask)
++ 1 voxels in the boxes and/or balls
++ Using only the boxes+balls mask
++ How many coors? 3
++ Will have the ref box central coors : SET_DICOM_XYZ 0 16 10
++ Will have the ref box central gapord: 10 13 10

------------------- end of optionizing -------------------

 -- trying to start Xvfb :568 
[1] 478418
_XSERVTransmkdir: Owner of /tmp/.X11-unix should be set to root
+/home/jovyan/Git_repositories/example-notebooks/books/functional_imaging/afni_pro_glm/sub_08.results/QC_sub_08/media/__tmp_chauf_ApCgHDTmsbC++ Writing palette image to QC_sub_08/media/qc_11_regr_tsnr_fin.pbar.jpg
++ Writing one 1538x182 image to filter '/opt/afni-latest/cjpeg -quality 95 > QC_sub_08/media/qc_11_regr_tsnr_fin.sag.jpg'
++ Writing one 1286x182 image to filter '/opt/afni-latest/cjpeg -quality 95 > QC_sub_08/media/qc_11_regr_tsnr_fin.cor.jpg'
++ Writing one 1286x218 image to filter '/opt/afni-latest/cjpeg -quality 95 > QC_sub_08/media/qc_11_regr_tsnr_fin.axi.jpg'

AFNI QUITTs!

+++ Command Echo:
   afni -q -no1D -noplugins -no_detach -com SWITCH_UNDERLAY tmp_ulay.nii -com SWITCH_OVERLAY  tmp_olay.nii -com SEE_OVERLAY     + -com OPEN_WINDOW sagittalimage opacity=4 mont=7x1:10:1:black crop=0:0,0:0 -com OPEN_WINDOW coronalimage  opacity=4 mont=7x1:13:1:black crop=0:0,0:0 -com OPEN_WINDOW axialimage    opacity=4 mont=7x1:10:1:black crop=0:0,0:0 -com SET_PBAR_ALL    +8    187=red  166=oran-red  146=orange  126=oran-yell  105=yell-oran  85=yellow  65=lt-blue2  36=blue  0=none -com PBAR_SAVEIM QC_sub_08/media/qc_11_regr_tsnr_fin.pbar.jpg dim=64x512H -com SET_SUBBRICKS   0 0 0 -com SET_ULAY_RANGE A.all 0.000000 .893150 -com SET_FUNC_RANGE  187 -com SET_THRESHNEW   0 * -com SET_FUNC_ALPHA  No -com SET_FUNC_BOXED  No -com SET_FUNC_RESAM  NN.NN -com SET_XHAIRS      OFF -com SET_XHAIR_GAP   -1 -com SET_DICOM_XYZ 0 16 10 -com SAVE_JPEG sagittalimage QC_sub_08/media/qc_11_regr_tsnr_fin.sag blowup=2 -com SAVE_JPEG coronalimage  QC_sub_08/media/qc_11_regr_tsnr_fin.cor blowup=2 -com SAVE_JPEG axialimage    QC_sub_08/media/qc_11_regr_tsnr_fin.axi blowup=2 -com QUITT QC_sub_08/media/__tmp_chauf_ApCgHDTmsbC 


+* Removing temporary image directory 'QC_sub_08/media/__tmp_chauf_ApCgHDTmsbC'.

[1]    Done                          Xvfb :568 -screen 0 1024x768x24

++ DONE (good exit)
   see: QC_sub_08/media/qc_11_regr_tsnr_fin*

/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
++ Check for corr matrix warnings in: QC_sub_08/media/qc_12_warns_xmat.dat
++ Check basic summary quants from proc in: QC_sub_08/media/qc_14_qsumm_ssrev.dat


# +++++++++++ Check output of @ss_review_basic +++++++++++ #


subject ID                : sub_08
AFNI version              : AFNI_21.2.00
AFNI package              : linux_openmp_64
TR                        : 2.0
TRs removed (per run)     : 0
num stim classes provided : 2
final anatomy dset        : anat_final.sub_08+tlrc.HEAD
final stats dset          : stats.sub_08_REML+tlrc.HEAD
final voxel resolution    : 3.000000	3.000000	3.000000

motion limit              : 0.3
num TRs above mot limit   : 2
average motion (per TR)   : 0.0767002
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
max motion displacement   : 0.868807
average outlier frac (TR) : 0.00122644

/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
num runs found            : 2
num TRs per run           : 146 146
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
TRs total                 : 292
degrees of freedom used   : 14
degrees of freedom left   : 278

/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
num regs of interest      : 2
num TRs per stim          : 120 110
ave mot per sresp         : 0.070899 0.079812

TSNR average              : 136.907
global correlation (GCOR) : 0.0806407
anat/EPI mask Dice coef   : 0.928854
anat/templ mask Dice coef : 0.960445
maximum F-stat (masked)   : 52.0792


apqc_make_html.py -qc_dir QC_sub_08
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \

++ Done! Wrote QC HTML.  To check, consider:

   afni_open -b QC_sub_08/index.html

echo \nconsider running: \n\n    afni_open -b ./afni_pro_glm/sub_08.results/QC_sub_08/index.html\n

consider running: 

    afni_open -b ./afni_pro_glm/sub_08.results/QC_sub_08/index.html

endif
cd ..
echo execution finished: `date`
date
execution finished: Thu May  1 05:32:23 UTC 2025

Results: Examining the output#

Let’s take a look at the results directory. Files containing the "pb" string are the preprocessed functional images at each step of the pipeline, while those with "T1w" refer to the preprocessed anatomical images. Additional auxiliary functional images are generated to assist with specific preprocessing steps, and auxiliary text files store information such as transformation matrices and motion parameters.

The file named stats.sub_08+tlrc contains results from the traditional 3dDeconvolve analysis, whereas stats.sub_08_REML+tlrc contains results from the 3dREMLfit approach, which accounts for temporal autocorrelation.

You’ll also see several files beginning with "X", such as X.xmat.1D, which represent components of the design matrix used in the regression analysis.

AFNI also automatically creates a quality control directory named QC_sub_08.

!ls ./afni_pro_glm/sub_08.results
3dREMLfit.err				 out.gcor.1D
@epi_review.sub_08			 out.mask_ae_dice.txt
@ss_review_basic			 out.mask_ae_overlap.txt
@ss_review_driver			 out.mask_at_dice.txt
@ss_review_driver_commands		 out.min_outlier.txt
@ss_review_html				 out.pre_ss_warn.txt
QC_sub_08				 out.review_html
TSNR.sub_08+tlrc.BRIK			 out.ss_review.sub_08.txt
TSNR.sub_08+tlrc.HEAD			 out.ss_review_uvars.json
X.jpg					 outcount.r01.1D
X.stim.xmat.1D				 outcount.r02.1D
X.xmat.1D				 outcount_rall.1D
_tmp.txt				 pb00.sub_08.r01.tcat+orig.BRIK
_tmp2.txt				 pb00.sub_08.r01.tcat+orig.HEAD
all_runs.sub_08+tlrc.BRIK		 pb00.sub_08.r02.tcat+orig.BRIK
all_runs.sub_08+tlrc.HEAD		 pb00.sub_08.r02.tcat+orig.HEAD
anat_final.sub_08+tlrc.BRIK		 pb01.sub_08.r01.volreg+tlrc.BRIK
anat_final.sub_08+tlrc.HEAD		 pb01.sub_08.r01.volreg+tlrc.HEAD
anat_w_skull_warped+tlrc.BRIK		 pb01.sub_08.r02.volreg+tlrc.BRIK
anat_w_skull_warped+tlrc.HEAD		 pb01.sub_08.r02.volreg+tlrc.HEAD
corr_brain+tlrc.BRIK			 pb02.sub_08.r01.blur+tlrc.BRIK
corr_brain+tlrc.HEAD			 pb02.sub_08.r01.blur+tlrc.HEAD
dfile.r01.1D				 pb02.sub_08.r02.blur+tlrc.BRIK
dfile.r02.1D				 pb02.sub_08.r02.blur+tlrc.HEAD
dfile_rall.1D				 pb03.sub_08.r01.scale+tlrc.BRIK
errts.sub_08+tlrc.BRIK			 pb03.sub_08.r01.scale+tlrc.HEAD
errts.sub_08+tlrc.HEAD			 pb03.sub_08.r02.scale+tlrc.BRIK
errts.sub_08_REML+tlrc.BRIK		 pb03.sub_08.r02.scale+tlrc.HEAD
errts.sub_08_REML+tlrc.HEAD		 pre.sub-08_T1w_ns+orig.BRIK
final_epi_vr_base_min_outlier+tlrc.BRIK  pre.sub-08_T1w_ns+orig.HEAD
final_epi_vr_base_min_outlier+tlrc.HEAD  pre.sub-08_T1w_ns_WarpDrive.log
fitts.sub_08+tlrc.BRIK			 stats.REML_cmd
fitts.sub_08+tlrc.HEAD			 stats.sub_08+tlrc.BRIK
fitts.sub_08_REML+tlrc.BRIK		 stats.sub_08+tlrc.HEAD
fitts.sub_08_REML+tlrc.HEAD		 stats.sub_08_REML+tlrc.BRIK
full_mask.sub_08+tlrc.BRIK		 stats.sub_08_REML+tlrc.HEAD
full_mask.sub_08+tlrc.HEAD		 stats.sub_08_REMLvar+tlrc.BRIK
ideal_congruent.1D			 stats.sub_08_REMLvar+tlrc.HEAD
ideal_incongruent.1D			 stimuli
mask_anat.sub_08+tlrc.BRIK		 sub-08_T1w+orig.BRIK
mask_anat.sub_08+tlrc.HEAD		 sub-08_T1w+orig.HEAD
mask_epi_anat.sub_08+tlrc.BRIK		 sub-08_T1w_al_junk+orig.BRIK
mask_epi_anat.sub_08+tlrc.HEAD		 sub-08_T1w_al_junk+orig.HEAD
mask_epi_extents+tlrc.BRIK		 sub-08_T1w_al_junk_mat.aff12.1D
mask_epi_extents+tlrc.HEAD		 sub-08_T1w_ns+orig.BRIK
mask_group+tlrc.BRIK			 sub-08_T1w_ns+orig.HEAD
mask_group+tlrc.HEAD			 sub-08_T1w_ns+tlrc.BRIK
mat.basewarp.aff12.1D			 sub-08_T1w_ns+tlrc.HEAD
mat.r01.vr.aff12.1D			 sub-08_T1w_ns.Xaff12.1D
mat.r01.warp.aff12.1D			 sub-08_T1w_ns.Xat.1D
mat.r02.vr.aff12.1D			 sub-08_T1w_ns.maskwarp.Xat.1D
mat.r02.warp.aff12.1D			 sub-08_T1w_ns_shft.1D
mean.errts.1D				 sum_ideal.1D
mean.errts.unit.1D			 volumized+tlrc.BRIK
motion_demean.1D			 volumized+tlrc.HEAD
motion_sub_08_enorm.1D			 vr_base_min_outlier+orig.BRIK
out.allcostX.txt			 vr_base_min_outlier+orig.HEAD
out.cormat_warn.txt			 warp.anat.Xat.1D
out.df_info.txt

Design Matrix#

Let’s visualize the graphical representation of the design matrix to check the experimental design setup. The image shows how each condition (stimulus) is modeled across the time series. The "X" files contain important information about how the stimuli, motion parameters, and other regressors are combined into the matrix for the GLM analysis.

In this case, the design matrix includes the following regressors in order:

  • The first 6 regressors (Run#1Pol#0 to Run#2Pol#2) are drift (polynomial) terms used to model low-frequency signal fluctuations separately for each run.

  • The next 2 regressors (congruent#0 and incongruent#0) correspond to the task-related conditions and model stimulus events across both runs.

  • The final 6 regressors (mot_demean[0]#0 to mot_demean[5]#0) represent motion parameters for the entire session, capturing estimated head movement in 3 translational and 3 rotational directions.

display(Image(filename='./afni_pro_glm/sub_08.results/X.jpg',  width=700))

To view the names of the individual regressors in the design matrix, you can run the following command. This will list the labels in the same order they appear in the matrix, helping you verify which columns correspond to drift terms, task conditions, and motion parameters.

!1d_tool.py -infile ./afni_pro_glm/sub_08.results/X.xmat.1D -show_labels
/opt/afni-latest/afnipy/lib_afni1D.py:1302: SyntaxWarning: 'str' object is not callable; perhaps you missed a comma?
  print('** uncensor from vec: nt = %d, but nocen len = %d' \
++ labels are: ['Run#1Pol#0', 'Run#1Pol#1', 'Run#1Pol#2', 'Run#2Pol#0', 'Run#2Pol#1', 'Run#2Pol#2', 'congruent#0', 'incongruent#0', 'mot_demean[0]#0', 'mot_demean[1]#0', 'mot_demean[2]#0', 'mot_demean[3]#0', 'mot_demean[4]#0', 'mot_demean[5]#0']

In addition to this, you’ll also see a visualization of the design matrix using the file X.xmat.1D below. This provides another way to examine the structure of the GLM model, showing when each regressor is active across the time series. Make sure the design matrix looks reasonable.

# Load the design matrix
xmat = np.loadtxt('./afni_pro_glm/sub_08.results/X.xmat.1D')

# Set up number of regressors and colors
n_regressors = xmat.shape[1]
colors = matplotlib.colormaps.get_cmap('tab20').resampled(n_regressors)

# Plot each regressor in its own row with a distinct color
fig, axes = plt.subplots(nrows=n_regressors, ncols=1, figsize=(12, n_regressors * 0.8), sharex=True)

for i in range(n_regressors):
    ax = axes[i]
    ax.plot(xmat[:, i], color=colors(i))
    ax.set_yticks([])
    ax.set_ylabel(f'{i+1}', rotation=0, fontsize=8, labelpad=15)
    ax.spines['top'].set_visible(False)
    ax.spines['right'].set_visible(False)
    ax.spines['left'].set_visible(False)

axes[-1].set_xlabel('Time points (TRs)', fontsize=10)
plt.suptitle('AFNI Design Matrix: X.xmat.1D', fontsize=14)
plt.tight_layout(rect=[0, 0, 1, 0.96])
plt.show()
../_images/b4710aa2a6fab77790616ba74f0c9259b71779544c86af26b96eca71ade97264.png

Quality Check#

AFNI automatically generates a quality control directory named QC_sub_08, which contains images and summary metrics for each preprocessing and GLM step such as motion estimates, outlier fractions and EPI-to-anatomical alignment. These quality control plots are stored in the media/ subfolder and can be displayed within the notebook to visually inspect the success of each step.

The show_qc_image() function can be used to display quality control images directly within the notebook. It takes the image filename and an optional title to present relevant QC plots inline.

def show_qc_image(filename, title=None):
    from IPython.display import Image, display
    if title:
        print(f'\n📊 {title}')
    display(Image(filename=filename))
show_qc_image('./afni_pro_glm/sub_08.results/QC_sub_08/media/qc_01_ve2a_epi2anat.cor.jpg', 'EPI to Anatomical Alignment')
📊 EPI to Anatomical Alignment
../_images/d384b604258cdd7691b2f275b346a402e16acbbf9d25fbd47af47e36437c1e85.jpg
show_qc_image('./afni_pro_glm/sub_08.results/QC_sub_08/media/qc_02_va2t_anat2temp.sag.jpg', 'Anatomical to MNI template Alignment')
📊 Anatomical to MNI template Alignment
../_images/e4658e55e068b2b72cf9bf438551e9b129c583b611a1f7372db0e408f42567ea.jpg
show_qc_image('./afni_pro_glm/sub_08.results/QC_sub_08/media/qc_03_vstat_Full_Fstat.axi.jpg', 'Full F_stat (stats.sub_08_REML)')
📊 Full F_stat (stats.sub_08_REML)
../_images/711214597d5ebcaa1994351f517a6da6969d692661ee387aa93757429f69248c.jpg

Statistical Files#

AFNI’s GUI provides extensive control over how to explore statistical maps. However, for this analysis, we will visualize some of these results using Nilearn to plot thresholded contrast maps. First, we’ll convert the stats.sub_08_REML file to NIfTI format using AFNItoNIFTI and inspect the metadata of the stats.sub_08_REML dataset with the command 3dinfo.

!3dAFNItoNIFTI -prefix ./afni_pro_glm/sub_08.results/stats.sub_08_REML+tlrc.nii.gz ./afni_pro_glm/sub_08.results/stats.sub_08_REML+tlrc
++ 3dAFNItoNIFTI: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]
!3dinfo -verb ./afni_pro_glm/sub_08.results/stats.sub_08+tlrc.HEAD
++ 3dinfo: AFNI version=AFNI_21.2.00 (Jul  8 2021) [64-bit]

Dataset File:    stats.sub_08+tlrc
Identifier Code: XYZ_x4aAlweUZ-h-BasfMg8M3Q  Creation Date: Thu May  1 05:30:14 2025
Template Space:  MNI
Dataset Type:    Func-Bucket (-fbuc)
Byte Order:      LSB_FIRST [this CPU native = LSB_FIRST]
Storage Mode:    BRIK
Storage Space:   14,124,916 (14 million) bytes
Geometry String: "MATRIX(-3,0,0,90,0,-3,0,126,0,0,3,-72):61,73,61"
Data Axes Tilt:  Plumb
Data Axes Orientation:
  first  (x) = Left-to-Right
  second (y) = Posterior-to-Anterior
  third  (z) = Inferior-to-Superior   [-orient LPI]
R-to-L extent:   -90.000 [R] -to-    90.000 [L] -step-     3.000 mm [ 61 voxels]
A-to-P extent:   -90.000 [A] -to-   126.000 [P] -step-     3.000 mm [ 73 voxels]
I-to-S extent:   -72.000 [I] -to-   108.000 [S] -step-     3.000 mm [ 61 voxels]
Number of values stored at each pixel = 13
  -- At sub-brick #0 'Full_Fstat' datum type is float:            0 to       57.8599
     statcode = fift;  statpar = 2 278
  -- At sub-brick #1 'congruent#0_Coef' datum type is float:     -19.2888 to       19.8009
  -- At sub-brick #2 'congruent#0_Tstat' datum type is float:     -4.80356 to       8.21562
     statcode = fitt;  statpar = 278
  -- At sub-brick #3 'congruent_Fstat' datum type is float:            0 to       67.4963
     statcode = fift;  statpar = 1 278
  -- At sub-brick #4 'incongruent#0_Coef' datum type is float:     -17.3512 to       20.0187
  -- At sub-brick #5 'incongruent#0_Tstat' datum type is float:     -5.54419 to       9.81473
     statcode = fitt;  statpar = 278
  -- At sub-brick #6 'incongruent_Fstat' datum type is float:            0 to        96.329
     statcode = fift;  statpar = 1 278
  -- At sub-brick #7 'incongruent-congruent_GLT#0_Coef' datum type is float:     -20.2822 to       21.2336
  -- At sub-brick #8 'incongruent-congruent_GLT#0_Tstat' datum type is float:     -4.32906 to       5.61382
     statcode = fitt;  statpar = 278
  -- At sub-brick #9 'incongruent-congruent_GLT_Fstat' datum type is float:            0 to       31.5149
     statcode = fift;  statpar = 1 278
  -- At sub-brick #10 'congruent-incongruent_GLT#0_Coef' datum type is float:     -21.2336 to       20.2822
  -- At sub-brick #11 'congruent-incongruent_GLT#0_Tstat' datum type is float:     -5.61382 to       4.32906
     statcode = fitt;  statpar = 278
  -- At sub-brick #12 'congruent-incongruent_GLT_Fstat' datum type is float:            0 to       31.5149
     statcode = fift;  statpar = 1 278

----- HISTORY -----
[jovyan@jupyter-monidoerig: Thu May  1 05:30:14 2025] {AFNI_21.2.00:linux_openmp_64} 3dDeconvolve -input pb03.sub_08.r01.scale+tlrc.HEAD pb03.sub_08.r02.scale+tlrc.HEAD -ortvec motion_demean.1D mot_demean -polort 2 -num_stimts 2 -stim_times 1 stimuli/congruent.1D GAM -stim_label 1 congruent -stim_times 2 stimuli/incongruent.1D GAM -stim_label 2 incongruent -gltsym 'SYM: +incongruent -congruent' -glt_label 1 incongruent-congruent -gltsym 'SYM: +congruent -incongruent' -glt_label 2 congruent-incongruent -jobs 8 -GOFORIT 0 -fout -tout -x1D X.xmat.1D -xjpeg X.jpg -fitts fitts.sub_08 -errts errts.sub_08 -bucket stats.sub_08
[jovyan@jupyter-monidoerig: Thu May  1 05:30:14 2025] Output prefix: stats.sub_08

🧠 Summary of Regressors and Contrasts

The following table provides key information from the 3dinfo output of the stats.sub_08_REML dataset. It includes the regressors (conditions) and contrasts, as well as their associated T-statistics. These values will be visualized as T-stat maps using Nilearn to examine the statistical significance of the task-related effects.

Sub-brick

Label

Meaning

#1

congruent#0_Coef

Beta weight (coefficient) for congruent trials

#4

incongruent#0_Coef

Beta weight (coefficient) for incongruent trials

#7

incongruent-congruent_GLT#0_Coef

Beta weight (coefficient) for the contrast between incongruent and congruent trials

#10

congruent-incongruent_GLT#0_Coef

Beta weight (coefficient) for the contrast between congruent and incongruent tri0als

#2

congruent#0_Tstat

T-statistic for congruent trials

#5

incongruent#0_Tstat

T-statistic for incongruent trials

#8

incongruent-congruent_GLT#0_Tstat

T-statistic for incongruent > congruent

#11

congruent-incongruent_GLT#0_Tstat

T-statistic for congruent > incongruent

# Degrees of freedom (statpar)
df = 278

# Calculate the critical t-value for two-tailed p=0.05
alpha = 0.05
critical_t_value = t.ppf(1 - alpha/2, df)
print(f"Critical t-value for p=0.05 and df={df}: {np.round(critical_t_value,3)}")

# Load image
img = nib.load('./afni_pro_glm/sub_08.results/stats.sub_08_REML+tlrc.nii.gz')
data = img.get_fdata()
affine = img.affine

# Extract contrasts
tstat_congruent = data[:, :, :, 0, 2] #sub-brick #2
tstat_incongruent = data[:, :, :, 0, 5]
tstat_incongruent_gt_congruent = data[:, :, :, 0, 8]
tstat_congruent_gt_incongruent = data[:, :, :, 0, 11]

# Make NIfTI images
tstat_congruent_img = nib.Nifti1Image(tstat_congruent, affine)
tstat_incongruent_img = nib.Nifti1Image(tstat_incongruent, affine)
tstat_contrast1_img = nib.Nifti1Image(tstat_incongruent_gt_congruent, affine)
tstat_contrast2_img = nib.Nifti1Image(tstat_congruent_gt_incongruent, affine)

# Plot
plotting.plot_stat_map(tstat_congruent_img, title="Congruent", threshold=critical_t_value) 
plotting.plot_stat_map(tstat_incongruent_img, title="Incongruent", threshold=critical_t_value)
plotting.plot_stat_map(tstat_contrast1_img, title="Incongruent > Congruent", threshold=critical_t_value)
plotting.plot_stat_map(tstat_contrast2_img, title="Congruent > Incongruent", threshold=critical_t_value)

plotting.show()
Critical t-value for p=0.05 and df=278: 1.969
../_images/fc951a209549939f3af54e38b996ef0f44bf24362807a954f6b75180a197f453.png ../_images/b17e5e47e9bc4b42155680b860c1539738fb4be50ecc45e8746db22e898efeb0.png ../_images/93988e75aee1618a52a1e50f033cedfa7259c9ce55236da512a4f68a1fac6bb1.png ../_images/b98d13dcfdafbab0b694b4267bb3ff60be00c1721bd62c866c952cff69b927d0.png