loosolab / TOBIAS

Transcription factor Occupancy prediction By Investigation of ATAC-seq Signal

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Error with BINDetect static plot, AttributeError: 'FancyArrowPatch' object has no property 'add_objects'

Freeda2023 opened this issue · comments

Hello,
I'm trying to run BINDetect and in the step of static plot, I get the error of:
2024-06-17 18:21:49 (8246) [INFO] - cntrl / KO (static plot) `

Traceback (most recent call last): File "/home/farzaneh/miniconda3/bin/TOBIAS", line 11, in sys.exit(main()) File "/home/farzaneh/miniconda3/lib/python3.9/site-packages/tobias/TOBIAS.py", line 162, in main args.func(args) File "/home/farzaneh/miniconda3/lib/python3.9/site-packages/tobias/tools/bindetect.py", line 819, in run_bindetect fig = plot_bindetect(motif_list, clustering, [cond1, cond2], args) File "/home/farzaneh/miniconda3/lib/python3.9/site-packages/tobias/tools/bindetect_functions.py", line 773, in plot_bindetect adjust_text(txts, ax=ax1, add_objects=[l], text_from_points=True, arrowprops=dict(arrowstyle='-', color='black', lw=0.5)) #, expand_text=(0.1,1.2), expand_objects=(0.1,0.1)) File "/home/farzaneh/miniconda3/lib/python3.9/site-packages/adjustText/init.py", line 635, in adjust_text arrowpatch = FancyArrowPatch( File "/home/farzaneh/miniconda3/lib/python3.9/site-packages/matplotlib/_api/deprecation.py", line 386, in wrapper return func(*inner_args, **inner_kwargs) File "/home/farzaneh/miniconda3/lib/python3.9/site-packages/matplotlib/patches.py", line 4241, in init super().init(**kwargs) File "/home/farzaneh/miniconda3/lib/python3.9/site-packages/matplotlib/patches.py", line 113, in init self.update(kwargs) File "/home/farzaneh/miniconda3/lib/python3.9/site-packages/matplotlib/artist.py", line 1064, in update raise AttributeError(f"{type(self).name!r} object " AttributeError: 'FancyArrowPatch' object has no property 'add_objects'

`
How can I fix this issue? I changed my matplotlib per its request but the issue is still here.
Thanks

Hello @Freeda2023,

the error comes from the adjustText package because they changed the name of one of their parameters. We have already fixed this in the #270 pull request. If you install the current version from our dev branch, it should work. You can do this e.g. with pip install git+https://github.com/loosolab/TOBIAS@dev.

However, if the error persists please don't hesitate to reopen the issue.

I installed successfully the dev version but I'm not sure if my code runs it through "dev" version or not since I still get the same error. TOBIAS --version returns 0.16.2-b.

0.16.2-b is the correct version your error may have a different reason. However, I need more information to help you. Would you kindly provide your BINDetect call or even better a small reproducible example? To ensure this is not related to your data you can also try to run our BINDetect examples.

No activity for at least 30 days. Marking issue as stale. Stale issues are closed after one week.