yeatmanlab / pyAFQ

Automated Fiber Quantification ... in Python
http://yeatmanlab.github.io/pyAFQ/
BSD 2-Clause "Simplified" License
55 stars 34 forks source link

Using the default bundle definition raises warnings #1075

Open arokem opened 8 months ago

arokem commented 8 months ago
WARNING:AFQ:FP and Occipital bundles are co-located, and AFQ assigns each streamline to only one bundle. Only Occipital will be used.
WARNING:AFQ:FA and Orbital bundles are co-located, and AFQ assigns each streamline to only one bundle. Only Orbital will be used.
WARNING:AFQ:FP and Occipital bundles are co-located, and AFQ assigns each streamline to only one bundle. Only Occipital will be used.
WARNING:AFQ:FA and Orbital bundles are co-located, and AFQ assigns each streamline to only one bundle. Only Orbital will be used.
arokem commented 8 months ago

And then crashes with:

Traceback (most recent call last):
  File "/Users/arokem/projects/project/afq.py", line 29, in <module>
    myafq.export_all()
  File "/Users/arokem/source/pyAFQ/AFQ/api/group.py", line 514, in export_all
    self.assemble_AFQ_browser()
  File "/Users/arokem/source/pyAFQ/AFQ/api/group.py", line 906, in assemble_AFQ_browser
    sls_json_fname = self.get_streamlines_json()
  File "/Users/arokem/source/pyAFQ/AFQ/api/group.py", line 360, in get_streamlines_json
    idx = seg_sft.bundle_idxs[b]

The full script I ran is:

from AFQ.api.group import GroupAFQ
from AFQ.definitions.image import ImageFile

brain_mask_definition = ImageFile(
    suffix="mask",
    filters={'desc': 'brain',
             'space': 'T1w',
             'scope': 'qsiprep'})

myafq = GroupAFQ(
    bids_path="/path/to/bids/dataset",
    preproc_pipeline='qsiprep',
    brain_mask_definition=brain_mask_definition,
    )

myafq.export_all()
# myafq.export("template_xform")
arokem commented 8 months ago

I believe the error is AFQ-Browser related, which is why we haven't seen it much so far.

36000 commented 8 months ago

I wonder if a problem here is that the bundle was not found?