Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Problem running ICA-AROMA #74

Open
kelaporter opened this issue Jan 26, 2024 · 0 comments
Open

Problem running ICA-AROMA #74

kelaporter opened this issue Jan 26, 2024 · 0 comments

Comments

@kelaporter
Copy link

Hello,

I ran the code and it stated that the distplot has been depricated and to change to histplot or displot. I changed it to histplot. I tried updating to the histplot terminology but keep running into errors. Currently my classification_plots code starting at line 165 where the error starts is the following:

# plot distributions
# RP
sns.histplot(df.loc[df['Motion'] == "True", "RP"],
             ax=ax1t,
             color=colortrue,
             kde_kws=dict(cut=3),
             alpha=.4)
sns.histplot(df.loc[df['Motion'] == "False", "RP"],
             ax=ax1t,
             color=colorfalse,
             kde_kws=dict(cut=3),
             alpha=.4)
ax1t.set_xlim([0, 1])

# Edge
sns.histplot(df.loc[df['Motion'] == "True", "Edge"],
             ax=ax1r,
             vertical=True,
             color=colortrue,
             kde_kws=dict(cut=3),
             alpha=.4)
sns.histplot(df.loc[df['Motion'] == "False", "Edge"],
             ax=ax1r,
             vertical=True,
             color=colorfalse,
             kde_kws=dict(cut=3),
             alpha=.4)
ax1r.set_ylim([0, 1])

The current error that I am getting is:
------------------------------- RUNNING ICA-AROMA -------------------------------
--------------- 'ICA-based Automatic Removal Of Motion Artifacts' ---------------

Step 1) MELODIC

  • The existing/specified MELODIC directory will be used.
  • The MELODIC directory does not contain the required 'stats' folder. Mixture modeling on the Z-statistical maps will be run.
    Step 2) Automatic classification of the components
  • registering the spatial maps to MNI
  • extracting the CSF & Edge fraction features
  • extracting the Maximum RP correlation feature
  • extracting the High-frequency content feature
  • classification
    Found 1 file(s)
    Found 128 head motion-related components in a total of 135 components.
    Traceback (most recent call last):
    File "/home/meduser/porter/scripts/ICA_AROMA.py", line 228, in
    classification_plot(os.path.join(outDir, 'classification_overview.txt'),
    File "/home/meduser/porter/scripts/classification_plots.py", line 178, in classification_plot
    sns.histplot(df.loc[df['Motion'] == "True", "Edge"],
    File "/home/local/fsl/lib/python3.10/site-packages/seaborn/distributions.py", line 1432, in histplot
    p.plot_univariate_histogram(
    File "/home/local/fsl/lib/python3.10/site-packages/seaborn/distributions.py", line 575, in plot_univariate_histogram
    artists = plot_func(
    File "/home/local/fsl/lib/python3.10/site-packages/matplotlib/init.py", line 1442, in inner
    return func(ax, *map(sanitize_sequence, args), **kwargs)
    File "/home/local/fsl/lib/python3.10/site-packages/matplotlib/axes/_axes.py", line 2488, in bar
    r._internal_update(kwargs)
    File "/home/local/fsl/lib/python3.10/site-packages/matplotlib/artist.py", line 1223, in _internal_update
    return self._update_props(
    File "/home/local/fsl/lib/python3.10/site-packages/matplotlib/artist.py", line 1197, in _update_props
    raise AttributeError(
    AttributeError: Rectangle.set() got an unexpected keyword argument 'vertical'

Before changing it to histplot it ran fine, but since I have changed it I cannot get it to run without an error. I am not sure what else I need to change.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant