CRISPRCasTyper icon indicating copy to clipboard operation
CRISPRCasTyper copied to clipboard

ValueError: invalid literal for int() with base 10: 'lengt'

Open AndAvia opened this issue 3 months ago • 2 comments

Hello. I first ran the single bins(2159kb) and he was able to output the results properly, but when I merged the 1472 bins (3.39Gb)into one fasta file and ran it again, the following error was reported,

cctyper ~/virus/viwrap_input/merge.fa ~/virus/CRISPRCasTyper --prodigal meta --threads 12
[2024-03-20 14:32:44] INFO: Running CRISPRCasTyper version 1.8.0
[2024-03-20 14:32:57] INFO: Predicting ORFs with prodigal
[2024-03-20 18:56:28] INFO: Running HMMER against Cas profiles
100%|████████████████████████████████████████████████████████████████████| 705/705 [4:57:48<00:00, 25.35s/it]
/data4/machuang/miniconda3/envs/cctyper/lib/python3.8/site-packages/cctyper/hmmer.py:85: DtypeWarning: Columns (28) have mixed types. Specify dtype option on import or set low_memory=False.
  hmm_df = pd.read_csv(self.out+'hmmer.tab', sep='\s+', header=None,
Traceback (most recent call last):
  File "/data4/machuang/miniconda3/envs/cctyper/bin/cctyper", line 85, in <module>
    hmmeri.main_hmm()
  File "/data4/machuang/miniconda3/envs/cctyper/lib/python3.8/site-packages/cctyper/hmmer.py", line 26, in main_hmm
    self.load_hmm()
  File "/data4/machuang/miniconda3/envs/cctyper/lib/python3.8/site-packages/cctyper/hmmer.py", line 100, in load_hmm
    hmm_df['Pos'] = [int(re.sub(".*_","",x)) for x in hmm_df['ORF']]
  File "/data4/machuang/miniconda3/envs/cctyper/lib/python3.8/site-packages/cctyper/hmmer.py", line 100, in <listcomp>
    hmm_df['Pos'] = [int(re.sub(".*_","",x)) for x in hmm_df['ORF']]
ValueError: invalid literal for int() with base 10: 'lengt'

The hmmer.log shows

Fatal exception (source file easel.c, line 2248):
unexpected getcwd() error

what is the reason for this, thanks for your help.

AndAvia avatar Mar 21 '24 01:03 AndAvia

It sounds like something on your system is deleting temporary files. Maybe you have a disk space limit for your temporary folder? A fix could be to set the TMPDIR environment variable to somewhere with enough diskspace.

Russel88 avatar Mar 21 '24 08:03 Russel88

It sounds like something on your system is deleting temporary files. Maybe you have a disk space limit for your temporary folder? A fix could be to set the TMPDIR environment variable to somewhere with enough diskspace.

Fine, I'll give up on making such a large merged file as input, I'll run the code using a loop statement, thanks for the answer!

AndAvia avatar Mar 21 '24 09:03 AndAvia