abyzovlab / CNVnator

a tool for CNV discovery and genotyping from depth-of-coverage by mapped reads
Other
206 stars 65 forks source link

singularity image failure #271

Open cmatKhan opened 1 year ago

cmatKhan commented 1 year ago

Hi all,

I am trying to use CNVnator in a nextflow pipeline with the singularity image constructed via bioconda. I am getting this error:

➜  8d4a843587d895c128cc6d0e925856 singularity shell --bind $PWD:/home ~/Desktop/tmp/bsa_tester/singularity/depot.galaxyproject.org-singularity-cnvnator-0.4.1--py39h8ff43dc_5.img
Singularity> cd /home/
Singularity> ls
KN99_genome_fungidb.fasta            kn99_chr                             oguzkhan                             sample2_bwamem2_sorted_markdups.bam
Singularity> cnvnator -root out.root -tree sample2_bwamem2_sorted_markdups.bam
cnvnator: /home/conda/feedstock_root/build_artifacts/root_base_1630711584118/work/root-source/interpreter/cling/lib/Interpreter/CIFactory.cpp:595: {anonymous}::collectModuleMaps(clang::CompilerInstance&, llvm::SmallVectorImpl<std::__cxx11::basic_string<char> >&)::<lambda(llvm::StringRef, const string&, const string&, std::string&, bool, bool)>: Assertion `llvm::sys::fs::exists(SystemDir) && "Must exist!"' failed.
Aborted (core dumped)

Through bioconda, a docker image is also built. Doing the same thing with docker succeeds:

➜  8d4a843587d895c128cc6d0e925856 docker run -it --mount type=bind,source="${PWD}",target="$HOME" bbab39e8960f bash 
root@5830ccfee311:/# cd home/oguzkhan/
root@5830ccfee311:/home/oguzkhan# ls
KN99_genome_fungidb.fasta            kn99_chr                             sample2_bwamem2_sorted_markdups.bam
root@5830ccfee311:/home/oguzkhan# cnvnator -root out.root -tree sample2_bwamem2_sorted_markdups.bam 
Parsing file sample2_bwamem2_sorted_markdups.bam ...
[E::hts_open_format] Failed to open file "sample2_bwamem2_sorted_markdups.bam" : No such file or directory
Can't open file 'sample2_bwamem2_sorted_markdups.bam'.
No chromosome/contig description given.
No reference genome specified. Aborting parsing.
Writing histograms ... 
Total of 0 reads were placed.
root@5830ccfee311:/home/oguzkhan# ls
KN99_genome_fungidb.fasta            kn99_chr                             out.root                             sample2_bwamem2_sorted_markdups.bam

I am using this on a HPC where I don't have access to docker, hence the need for singularity, unfortunately.

As an aside, when I tried to create a conda environment, I received the following error:

(/home/oguzkhan/Desktop/cnvnator) ➜  8d4a843587d895c128cc6d0e925856 conda install -c bioconda cnvnator
Collecting package metadata (current_repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: failed with repodata from current_repodata.json, will retry with next repodata source.
Collecting package metadata (repodata.json): done
Solving environment: failed with initial frozen solve. Retrying with flexible solve.
Solving environment: \ 
Found conflicts! Looking for incompatible packages.
This can take several minutes.  Press CTRL-C to abort.
failed                                                                                                                                                                       

UnsatisfiableError: The following specifications were found to be incompatible with your system:

  - feature:/linux-64::__glibc==2.31=0
  - cnvnator -> libgcc-ng[version='>=9.3.0'] -> __glibc[version='>=2.17']

Your installed version is: 2.31

Could be related to https://github.com/NVIDIA/MinkowskiEngine/issues/354. Probably worth a note in the install docs, though, for conda.

arpanda commented 1 year ago

The cnvnator's bioconda repo probably has an installation issue. I will report the issue in bioconda.

For your CNV analysis, you may use CNVpytor (Updated version of cnvnator), available at https://github.com/abyzovlab/CNVpytor.

If you would like to use cnvnator, I would suggest you to install it directly from GitHub.

Thanks Arijit