Index.html- va2t and mot questions

Hello!

Thank you so much for adding in this wonderful index.html function. I have two questions related to the output.

  1. When I look in the va2t block, the background does not look nice and solidly black like it does in your example (11.4.2. APQC-HTML navigation: example — AFNI, SUMA and FATCAT: v23.1.06) and there is some activation outside of the brain. However, I do see visual cortex activation as expected. Is this “normal” or “OK” what I’m seeing? Or does it suggest a problem?

  2. The mot block is blank for me, and when I go to the media subfolder, it looks like the qc_13_mot_grayplot.jpg file is zero bytes. Where may that have gone wrong? I can run @ss_review_driver just fine and see the motion output.

I have attached some images to assist in this question, but am happy to email over the results folder if that’s more useful.

Thank you so much!!!

Best,
Megan

Hi, Megan-

Re. #1: I think that is actaully the vstat block you are looking at and referring to (not the va2t) here, right? I will assume so in replying…
And indeed, the patterns observed here will vary depending on the task/stimulus and modeling. In the example you refer to, there was a very strong audio and visual task presented as a block design with many blocks—we would expect large F-stat then in the temporal lobe and visual cortex, because of both the nature of the task and the relatively simple block design (20 s blocks). In more modern cases, particularly with event related tasks and more complicated designs with fewer regressors per stim class we might expect lower F-stats in many cases. There is some notable visual cortex with high F-stat in your image though, I believe?
And yes, in many cases, you might also expect to see more regions outside the brain, again depending on the task and paradigm. Seeing the eyeballs can also be common, as blinking might be associated with visual stimulus changes.

Re. #2) Hmm, I wonder if there is an issue with the Python setup on your system, since it sounds like the Python-plotting files are not present. The requirement should basically just be having Python (either 2.7 or 3.*) with Matplotlib ver>=2.2.3. What is the output of this on your computer:


afni_system_check.py -check_all

?
Also, there is a log of the terminal output of creating the APQC HTML in your afni_proc.py-produced results directory, called out.review_html. I will send you a messge through the interface here with my email address, if you wouldn’t mind sending me that (which should also suggest/pinpoint what is happening).

–pt

Hello!

  1. Yes, you are correct thank you! And thanks! I figured that more complex designs may lead to messier looking output but wanted to make sure. This is an event related design with many different things going on so I would expect it to be a bit less clear than in the example. And I do see visual cortex here which is comforting.

  2. Here is the output from that command. I’d be happy to send along that html file once I get your email!

tue50988@cla19097:~$ afni_system_check.py -check_all
-------------------------------- general ---------------------------------
architecture: 64bit ELF
system: Linux
release: 5.15.0-46-generic
version: #49~20.04.1-Ubuntu SMP Thu Aug 4 19:15:44 UTC 2022
distribution: ubuntu 20.04 focal
number of CPUs: 48
apparent login shell: bash
shell RC file: .bashrc (exists)

--------------------- AFNI and related program tests ---------------------
which afni : /usr/local/abin/afni
afni version : Precompiled binary linux_ubuntu_16_64: Aug 25 2022
: AFNI_22.2.08 ‘Marcus Aurelius’
AFNI_version.txt : AFNI_22.2.08, linux_ubuntu_16_64, Aug 25 2022
which python : /usr/bin/python
python version : 3.8.10
which R : /usr/bin/R
R version : R version 3.6.3 (2020-02-29) – “Holding the Windsock”
which tcsh : /usr/bin/tcsh

instances of various programs found in PATH:
afni : 1 (/usr/local/abin/afni)
R : 1 (/usr/bin/R)
python : 1 (/usr/bin/python3.8)
python2 : 1 (/usr/bin/python2.7)
python3 : 1 (/usr/bin/python3.8)

testing ability to start various programs…
afni : success
suma : success
3dSkullStrip : success
uber_subject.py : success
3dAllineate : success
3dRSFC : success
SurfMesh : success
3dClustSim : success
3dMVM : success

checking for R packages…
rPkgsInstall -pkgs ALL -check : FAILURE

    oo Warning: 
       These packages are not installed on the computer: paran!
    These packages are not installed on the computer: psych!
    These packages are not installed on the computer: brms!
    These packages are not installed on the computer: corrplot!
    These packages are not installed on the computer: metafor!

R RHOME : /usr/lib/R

checking for $HOME files…
.afnirc : found
.sumarc : found
.afni/help/all_progs.COMP : found

------------------------------ python libs -------------------------------
** failed to load module PyQt4
– PyQt4 is no longer needed for an AFNI bootcamp

++ module loaded: matplotlib.pyplot
module file : /usr/lib/python3/dist-packages/matplotlib/pyplot.py
matplotlib version : 3.1.2

-------------------------------- env vars --------------------------------
PATH = /home/local/TU/tue50988/.local/bin:/usr/local/freesurfer/bin:/usr/local/freesurfer/fsfast/bin:/usr/local/freesurfer/tktools:/usr/local/fsl/bin:/usr/local/freesurfer/mni/bin:/usr/local/fsl/bin:/usr/local/sbin:/usr/local/bin:/usr/sbin:/usr/bin:/sbin:/bin:/usr/games:/usr/local/games:/snap/bin:/usr/local/abin:/usr/local/abin

PYTHONPATH =
R_LIBS =
LD_LIBRARY_PATH =
DYLD_LIBRARY_PATH = :/opt/X11/lib/flat_namespace:/opt/X11/lib/flat_namespace:/opt/X11/lib/flat_namespace:/opt/X11/lib/flat_namespace

DYLD_FALLBACK_LIBRARY_PATH =

------------------------------ data checks -------------------------------
data dir : missing AFNI_data6
data dir : missing AFNI_demos
data dir : missing suma_demo
data dir : missing afni_handouts
atlas : found TT_N27+tlrc under /usr/local/abin

------------------------------ OS specific -------------------------------
which apt-get : /usr/bin/apt-get
apt-get version : apt 2.0.9 (amd64)

have Ubuntu system: ubuntu 20.04 focal
have Ubuntu afni : Precompiled binary linux_ubuntu_16_64: Aug 25 2022

========================= summary, please fix: =========================

  • just be aware: login shell ‘bash’, but our code examples use ‘tcsh’
  • missing R packages (see rPkgsInstall)
  • insufficient data for AFNI bootcamp
    (see “Prepare for Bootcamp” on install pages)

Hi, Megan-

Thanks for sending that information.

There is a Python error that shows up:


ValueError: Format 'jpg' is not supported (supported formats: eps, pdf, pgf, png, ps, raw, rgba, svg, svgz)

The bad news: the default package manager in Ubuntu 20.04 (Aptitude) distributes a version of Matplotlib, 3.1.2, that contains this error when trying to make JPGs:
https://bugs.launchpad.net/ubuntu/+source/matplotlib/+bug/1897283
I don’t know why they haven’t fixed it, and it is the root cause of the error here. From your afni_system_check.py output, that does appear to be the Matplotlib version you have.

The good news: there is a fix. Can you please run the following on your computer (requires the admin/sudo password):


sudo apt-get install pip
sudo apt-get remove python3-matplotlib
pip install matplotlib

That should get you matplotlib ver=3.6.2 (or so), and Python can now generate JPG images. (Why Ubuntu didn’t make the bug-free version of matplotlib its default… I don’t know.)

Then you can go into an afni_proc.py (AP) results directory, and do:


curl -O [https://raw.githubusercontent.com/afni/afni/master/src/ptaylor/supplement/redo_apqc.tcsh](https://raw.githubusercontent.com/afni/afni/master/src/ptaylor/supplement/redo_apqc.tcsh)
tcsh redo_apqc.tcsh

… to regenerate the QC directory there. Under the ‘mot’ block and in other places in the HTML, you should now see lots of line plots.

–pt