RitataLU / MethylC-analyzer

GNU General Public License v3.0
11 stars 4 forks source link

Issue running MethylC-analyzer demo on HPC - Script can't recognize files in the folder #6

Open FarzanehRah opened 1 year ago

FarzanehRah commented 1 year ago

Hi,

I'm facing an issue while trying to run the demo of MethylC-analyzer on our High-Performance Computing (HPC) cluster. After installing the necessary requirements and loading all dependencies, I'm able to execute the command. However, even though the required files are present in the designated folder, the script cannot recognize them.

I would greatly appreciate any guidance or insights on how to resolve this issue. Thank you in advance for your help!

(ENV_3_9) [f@n MethylC-analyzer/scripts]$ python MethylC.py all samples_list.txt TAR10_2_demo.gtf /home/MethylC-analyzer/scripts/ -a MT -b WT -d 4 -r 200 -q 2 -bs 200000 -pvalue 0.1
Now processing MT1s.CGmap.gz
Now processing MT2s.CGmap.gz
Now processing WT1s.CGmap.gz
Now processing WT2s.CGmap.gz
no display found. Using non-interactive Agg backend
*------------------------*
|generating Heatmap $ PCA|
*------------------------*
Fatal error: cannot open file '/MethylC-analyzer/scripts/heatmap_PCA_all.R': No such file or directory

*---------------*
|Identifying DMR|
*---------------*
/cvmfs/soft.computecanada.ca/easybuild/software/2020/avx2/Core/scipy-stack/2023a/lib/python3.9/site-packages/scipy/stats/_stats_py.py:8380: RuntimeWarning: ks_2samp: Exact calculation unsuccessful. Switching to method=asymp.
  return ks_2samp(xvals, yvals, alternative=alternative, method=method)
....

python: can't open file '/MethylC-analyzer/scripts/extract_transcript_regions.py': [Errno 2] No such file or directory
cat: /home/MethylC-analyzer/scripts/TAR10_2_demo.gtf_exons.bed: No such file or directory
cat: /home/MethylC-analyzer/scripts/TAR10_2_demo.gtf_introns.bed: No such file or directory
cat: /home/MethylC-analyzer/scripts/TAR10_2_demo.gtf_5utr.bed: No such file or directory
cat: /home/MethylC-analyzer/scripts/TAR10_2_demo.gtf_cds.bed: No such file or directory
cat: /home/MethylC-analyzer/scripts/TAR10_2_demo.gtf_3utr.bed: No such file or directory
rm: cannot remove '/home/MethylC-analyzer/scripts/*3utr.bed': No such file or directory
rm: cannot remove '/home/MethylC-analyzer/scripts/*5utr.bed': No such file or directory
rm: cannot remove '/home/MethylC-analyzer/scripts/*_cds.bed': No such file or directory
rm: cannot remove '/home/MethylC-analyzer/scripts/*_exons.bed': No such file or directory
rm: cannot remove '/home/MethylC-analyzer/scripts/*_introns.bed': No such file or directory
rm: cannot remove '/home/MethylC-analyzer/scripts/*_coding*.bed': No such file or directory
rm: cannot remove '/home/MethylC-analyzer/scripts/*noncoding*.bed': No such file or directory
rm: cannot remove '/home/MethylC-analyzer/scripts/*5utr_start.bed': No such file or directory

*****
***** ERROR: Requested column 4, but database file - only has fields 1 - 0.

*****
***** ERROR: Requested column 4, but database file - only has fields 1 - 0.

*****
***** ERROR: Requested column 4, but database file - only has fields 1 - 0.

*****
***** ERROR: Requested column 4, but database file - only has fields 1 - 0.

*****
***** ERROR: Requested column 4, but database file - only has fields 1 - 0.
rm: cannot remove '/home/MethylC-analyzer/scripts/*gene_igr_bed6.bed': No such file or directory
*--------------------------------*
|Applying DMR enrichment analysis|
*--------------------------------*
*---------------*
|Identifying DMG|
*---------------*
*--------------------------*
|Generating ChrView figures|
*--------------------------*
/home/MethylC-analyzer/scripts/MethylC.py:711: FutureWarning: The frame.append method is deprecated and will be removed from pandas in a future version. Use pandas.concat instead.
  savefile=savefile.append(out,ignore_index=True)
....
*--------------------*
|Generating metaplots|
*--------------------*
Fatal error: cannot open file '/MethylC-analyzer/scripts/metaplot.R': No such file or directory
Traceback (most recent call last):
  File "/home/MethylC-analyzer/scripts/MethylC.py", line 849, in <module>
    Delta_Meta('CG')
  File "/home/MethylC-analyzer/scripts/MethylC.py", line 309, in Delta_Meta
    exp_df.append(pd.read_csv(path_to_files+expfile+"_"+ context +".matrix.gz" ,sep='\t', skiprows=1,compression ='gzip',na_values='-',header =None))
  File "/cvmfs/soft.computecanada.ca/easybuild/software/2020/avx2/Core/scipy-stack/2023a/lib/python3.9/site-packages/pandas/util/_decorators.py", line 211, in wrapper
    return func(*args, **kwargs)
  File "/cvmfs/soft.computecanada.ca/easybuild/software/2020/avx2/Core/scipy-stack/2023a/lib/python3.9/site-packages/pandas/util/_decorators.py", line 331, in wrapper
    return func(*args, **kwargs)
  File "/cvmfs/soft.computecanada.ca/easybuild/software/2020/avx2/Core/scipy-stack/2023a/lib/python3.9/site-packages/pandas/io/parsers/readers.py", line 950, in read_csv
    return _read(filepath_or_buffer, kwds)
  File "/cvmfs/soft.computecanada.ca/easybuild/software/2020/avx2/Core/scipy-stack/2023a/lib/python3.9/site-packages/pandas/io/parsers/readers.py", line 605, in _read
    parser = TextFileReader(filepath_or_buffer, **kwds)
  File "/cvmfs/soft.computecanada.ca/easybuild/software/2020/avx2/Core/scipy-stack/2023a/lib/python3.9/site-packages/pandas/io/parsers/readers.py", line 1442, in __init__
    self._engine = self._make_engine(f, self.engine)
  File "/cvmfs/soft.computecanada.ca/easybuild/software/2020/avx2/Core/scipy-stack/2023a/lib/python3.9/site-packages/pandas/io/parsers/readers.py", line 1753, in _make_engine
    return mapping[engine](f, **self.options)
  File "/cvmfs/soft.computecanada.ca/easybuild/software/2020/avx2/Core/scipy-stack/2023a/lib/python3.9/site-packages/pandas/io/parsers/c_parser_wrapper.py", line 79, in __init__
    self._reader = parsers.TextReader(src, **kwds)
  File "pandas/_libs/parsers.pyx", line 554, in pandas._libs.parsers.TextReader.__cinit__
pandas.errors.EmptyDataError: No columns to parse from file

image

treartis commented 1 year ago

I would adjust the MethylC.py script directly and change the files to include their exact paths. For example, where it says '/MethylC-analyzer/scripts/heatmap_PCA_all.R' in the script, adjust this with it's actual path.