W-L / deviaTE

Python tool for the analysis and visualization of mobile genetic elements
GNU General Public License v3.0
19 stars 7 forks source link

various errors after conda installation #7

Closed r-mashoodh closed 2 years ago

r-mashoodh commented 3 years ago

Hi,

I installed via conda as instructed. But I had a few questions.

  1. deviaTE --input_bam_dir ... how do you specify a folder of bam files, when I do the following --input_bam_dir ./bam_files i get an deviaTE: error: unrecognized arguments: ./bam_files

  2. When I provide a single file ... deviaTE --input_bam ./bam_files/F1_R1.aln.bam

Alignment provided, skipping step 1
Detecting internal deletions..

samtools: error while loading shared libraries: libcrypto.so.1.0.0: cannot open shared object file: No such file or directory
samtools: error while loading shared libraries: libcrypto.so.1.0.0: cannot open shared object file: No such file or directory
[E::hts_open_format] Failed to open file ./bam_files/F1_R1.aln.bam.tmp.sam
Traceback (most recent call last):
  File "/home/rm786/.conda/envs/deviaTE_env/bin/deviaTE_fuse", line 23, in <module>
  1. What's your recommendation for PE information, align separately and combine into a single bam?

Thanks so much!

W-L commented 3 years ago

Hi, Thanks for getting in touch! 1.) In order to use the tool on a folder of *.bam files you need to launch it inside of that folder. It will then use all bam files within that directory. In other words the argument --input_bam_dir acts as a flag and does not take an additional path afterwards.

2.) The issue about the libcrypto.so not being found is something that comes up on MacOS every now and then. You might be able to solve it by making sure that openssl is installed and then linking those libraries manually. Something like this:

brew update
brew install openssl

ln -s /usr/local/opt/openssl/lib/libcrypto.1.0.0.dylib /usr/local/lib/
ln -s /usr/local/opt/openssl/lib/libssl.1.0.0.dylib /usr/local/lib/

3.) Yes, that sounds like a good strategy! Hope this helps with solving your issues, please let me know how it goes. Cheers, Lukas

r-mashoodh commented 3 years ago

doh about input dir ... thanks!!

is there any way to install openssl within the conda env? I made an attempt but failed.

I have access to another cluster where I can get it to run but its going extremely slowly ... over 2 days on 1 bam (~4.5GB) so far, and still going. Do you have any advice on speeding it up? Or is that generally what you would expect ...

thanks again!

W-L commented 3 years ago

You can of course try to install openssl within the conda environment as well. But I'm not sure if that will solve the problem. If I recall correctly the issue is due to samtools struggling to find these linked libraries, so I think you will have to create these links I mentioned in my last message if the problem persist and it is indeed because of that. The tool is not very optimised at all and unfortunately I don't have the capacity to do anything about that. But there is one thing you can possibly try to speed it up. In case you are not interested in internal deletions in TEs, you can switch off their detection by using the argument --no_delet_detect. I remember that this part of the analysis was particularly slow. Hope that helps!

r-mashoodh commented 3 years ago

Thank you again!

Really sorry, but new problem ... it's generating the data file but says it can't install ggplot2 ... do you have some code that I could use in R to plot and see if the data files generated are useful or not?

******************** Visualization

Installing package into ‘/usr/local/lib/R/site-library’
(as ‘lib’ is unspecified)
Warning in install.packages("ggplot2", repos = rep) :
  'lib = "/usr/local/lib/R/site-library"' is not writable
Error in install.packages("ggplot2", repos = rep) : 
  unable to install packages
Execution halted
W-L commented 3 years ago

You could try to install the required R packages in the conda environment yourself. ggplot2 grid gridExtra argparse data.table cowplot And then use the standalone script for plotting, deviaTE_plot with arguments --input and --output