JiekaiLab / scTE

MIT License
87 stars 27 forks source link

scTE: error: argument -CB: invalid choice: 'CB' (choose from 'True', 'False') #4

Open lexie-lee opened 3 years ago

lexie-lee commented 3 years ago

Hello,

Thanks for the scTE at first, but I met problem when I use scTE, and I guess this is because the parameters of "-CB" and "-UMI".

the error is: scTE: error: argument -CB: invalid choice: 'CB' (choose from 'True', 'False')

My commands are: scTE -i /Volumes/Backup\ Plus/F19FTSSCWLJ0261_10X/bam/F03_PBS_MG.possorted_genome_bam.bam -o /Volumes/Backup\ Plus/F19FTSSCWLJ0261_10X/bam/F03_PBS_MG.possorted_genome_bam_scTE -x mm10.exclusive.idx --hdf5 True -CB CB -UMI UB -g mm10

and part of my bam files are: E00490:510:HYC2TCCXY:5:2105:25022:45646 256 1 3044966 0 30S121M * 0 0 AAGCAGTGGTATCAACGCAGAGTACATGGGAGAGAAAAACAAACCTGGGTATGCCTCGTAGTTAAAACATTCCTGGGAACATCTTGACCATAAGATAAAGGGGACTGTGAAGACATAGCAGGGCTATATTATCTAAGTCAACACCATCTGG AAFFFJFJJJJJJJJJJJJJJJJJJJJJJJJJJFAFJJFFJFFFJJJFFAFJFFJ7FFFJJJJJJFJJJJJFJJJJFJJJJJJJJFJJJJF7FJFJF-JJFJJ-<A<AFJJJJJJJFJJFJJJJJJ7AFFJ<FJAAAAAF<JJJJJFJJJJ NH:i:6 HI:i:3 AS:i:119 nM:i:0 NM:i:0 CR:Z:GCGCCAACATTGAGCT CY:Z:AAAFFFJJJJJJJJJJ CB:Z:GCGCCAACATTGAGCT-1 UR:Z:ATAGCAAGCA UY:Z:JJJJJJJFFJ UB:Z:ATAGCAAGCA BC:Z:CCTTTGTC QT:Z:AAFFFJJJ TR:Z:TTTTTTTTTTTTTTTTTTTTTTTTTTTTTTCCATTACAAGAGGGCGTTTAATTTCGGGGGTTCAAACCGACATTCATCCCACACAAGAGATAATGGGAGTCGGCCACGGGGGCCGCAAGACAGGG TQ:Z:JJJJJFJJJJJJJJJJJJJJJJJJJJJJJ<--<-A--<----<)---AF--A---7<)))))7----7--))7--7-7<F<))---7-<-7<F--7--))7)<))))-)--)-)-))<A----<F RG:Z:F03_PBS_MG:MissingLibrary:1:HYC2TCCXY:5

I saw in your Readme.txt file that the value of parameter "-CB" and "-UMI" are "CB" and "CR", but the recommend value in my terminal shows only can choose "False" or "True"....

I'm looking forward to your reply, Thanks a lot!

Xiaoyu

jphe commented 3 years ago

Seems you use the old version, you need to re-install the latest one

lexie-lee commented 3 years ago

Thanks a lot, but I reinstalled the site via the command in your README file, it still didn't work, and the error is the same...

jphe commented 3 years ago

Maybe you need to uninstall the old one?

then run:

$ git clone https://github.com/JiekaiLab/scTE.git $ cd scTE $ python setup.py install

lexie-lee commented 3 years ago

Yeah, I indeed deleted the scTE folder and rerun these commands : $ git clone https://github.com/JiekaiLab/scTE.git $ cd scTE $ python setup.py install

So only remove the old files is not ok? after running these commands, it says:

Using /usr/local/lib/python3.7/site-packages/six-1.15.0-py3.7.egg Finished processing dependencies for scTE==1.0

the scTE 1.0 version is the old one or the new one?

Thanks a lot!

jphe commented 3 years ago

You need to do: python setup.py uninstall. Then reinstall it

lexie-lee commented 3 years ago

Thanks a lot, I will try this command later, now my terminal is freezing, maybe the command can work, and my command is: scTE -i /Volumes/PBLAB/F19FTSSCWLJ0261_10X/bam/F03_PBS_MG.possorted_genome_bam.bam -o /Volumes/PBLAB/F19FTSSCWLJ0261_10X/bam/F03_PBS_MG.possorted_genome_bam_scTE -x mm10.exclusive.idx --hdf5 True -CB True -UMI True -g mm10

The informations are: DEBUG : Creating converter from 7 to 5 DEBUG : Creating converter from 5 to 7 DEBUG : Creating converter from 7 to 5 DEBUG : Creating converter from 5 to 7 INFO : Parameter list: Sample = /Volumes/PBLAB/F19FTSSCWLJ0261_10X/bam/F03_PBS_MG.possorted_genome_bam_scTE Genome = mm10 Reference annotation index = mm10.exclusive.idx Minimum number of genes required = 200 Minimum number of counts required = None Number of threads = 1

INFO : Loading the genome annotation index... 2021-03-22 20:52:53 INFO : Loaded 'mm10.exclusive.idx' binary file with 3900779 items ['Y', '14', '2', '16', '1', '11', '8', '15', 'X', '10', 'M', '13', '18', '19', '5', '17', '6', '9', '3', '12', '7', '4'] INFO : Finished loading the genome annotation index... 2021-03-22 20:53:27

INFO : Processing BAM/SAM files ...2021-03-22 20:53:27 INFO : Input SAM/BAM file appears to be valid

I will wait and try your advice later, Thanks a lot again๐Ÿ‘๐Ÿ‘๐Ÿ‘

frenkiboy commented 3 years ago

I get the same error regarding CB, and UMI.

Installed the version 1.0 today.

Any update on this?

leeyoyohku commented 3 years ago

Hi @frenkiboy and @lexie-lee , I previously encountered the same issue and tried the new version which works with CB flags. But later I encountered index error mentioned here https://github.com/jphe/scTE/issues/7#issuecomment-804517997. I'm not sure if it's just me or you share similar problems.

Thanks.

jphe commented 3 years ago

@leeyoyohku

Can you add the option "--keeptmp True", it will gereate a tmp folder, then check the files under o1, o2, o3 folder to see if are correct.

image
jphe commented 3 years ago

I get the same error regarding CB, and UMI.

Installed the version 1.0 today.

Any update on this?

The newest version is correct in my here

$ git clone https://github.com/JiekaiLab/scTE.git
$ cd scTE
$ python setup.py install
lexie-lee commented 3 years ago

My commands are:

`scTE -i /Volumes/PBLAB/F19FTSSCWLJ0261_10X/bam/F03_PBS_MG.possorted_genome_bam.bam -o F03_PBS_MG_scTE -x mm10.exclusive.idx --hdf5 True -CB True -UMI True -g mm10 DEBUG : Creating converter from 7 to 5 DEBUG : Creating converter from 5 to 7 DEBUG : Creating converter from 7 to 5 DEBUG : Creating converter from 5 to 7 INFO : Parameter list: Sample = F03_PBS_MG_scTE Genome = mm10 Reference annotation index = mm10.exclusive.idx Minimum number of genes required = 200 Minimum number of counts required = None Number of threads = 1

INFO : Loading the genome annotation index... 2021-03-23 21:22:02 INFO : Loaded 'mm10.exclusive.idx' binary file with 3900779 items ['4', '6', '12', 'M', '18', '8', 'X', '1', 'Y', '7', '19', '15', '14', '13', '3', '9', '5', '16', '2', '11', '10', '17'] INFO : Finished loading the genome annotation index... 2021-03-23 21:22:36

INFO : Processing BAM/SAM files ...2021-03-23 21:22:36 INFO : Input SAM/BAM file appears to be valid INFO : Done BAM/SAM files processing ...2021-03-24 03:26:47

INFO : Splitting ...2021-03-24 03:26:47 INFO : Executing single thread path INFO : Finished processing sample files 2021-03-24 03:36:47

INFO : Fetching from the annotation index... 2021-03-24 03:36:47 INFO : Done fetching... 2021-03-24 03:42:21

INFO : Calculating expression... 2021-03-24 03:42:21 DEBUG : Creating converter from 5 to 3 INFO : Detect 9768 cells expressed at least 200 genes, results output to F03_PBS_MG_scTE.csv INFO : Finished calculating expression 2021-03-24 03:48:26 INFO : Done with 0d 6h 26m 25s ` And it can work successfully

leeyoyohku commented 3 years ago

@jphe Thanks for your reply. After adding the flag "--keeptmp True", I couldn't see the three folders. Here are the same old error info:

DEBUG   : Creating converter from 7 to 5
DEBUG   : Creating converter from 5 to 7
DEBUG   : Creating converter from 7 to 5
DEBUG   : Creating converter from 5 to 7
INFO    : Parameter list:
Sample = new/D0_2
Reference annotation index = /home/yoyo/yoyo/0_reference/scTE_human.exclusive.idx
Minimum number of genes required = 200
Minimum number of counts required = None
Number of threads = 10

INFO    : Loading the genome annotation index... 2021-03-29 14:18:59
INFO    : Loaded '/home/yoyo/yoyo/0_reference/scTE_human.exclusive.idx' binary file with 5554908 items
INFO    : Finished loading the genome annotation index... 2021-03-29 14:19:31

INFO    : Processing BAM/SAM files ...2021-03-29 14:19:31
INFO    : Input SAM/BAM file appears to be valid
INFO    : Done BAM/SAM files processing ...2021-03-29 14:50:35

INFO    : Splitting ...2021-03-29 14:50:35
INFO    : Executing multiple thread path with 10 threads
['1', '10', '11', '12', '13', '14', '15', '16', '17', '18', '19', '2', '20', '21', '22', '3', '4', '5', '6', '7', '8', '9', 'M', 'X', 'Y']
CB UB good

multiprocessing.pool.RemoteTraceback:
"""
Traceback (most recent call last):
  File "/home/yoyo/miniconda2/envs/scTE/lib/python3.7/multiprocessing/pool.py", line 121, in worker
    result = (True, func(*args, **kwds))
  File "/home/yoyo/miniconda2/envs/scTE/lib/python3.7/multiprocessing/pool.py", line 44, in mapstar
    return list(map(*args))
  File "/home/yoyo/miniconda2/envs/scTE/lib/python3.7/site-packages/scTE-1.0-py3.7.egg/scTE/base.py", line 366, in splitChr
    CRs[t[3]] += 1
IndexError: list index out of range
"""

The above exception was the direct cause of the following exception:

Traceback (most recent call last):
  File "/home/yoyo/miniconda2/envs/scTE/bin/scTE", line 4, in <module>
    __import__('pkg_resources').run_script('scTE==1.0', 'scTE')
  File "/home/yoyo/miniconda2/envs/scTE/lib/python3.7/site-packages/pkg_resources/__init__.py", line 651, in run_script
    self.require(requires)[0].run_script(script_name, ns)
  File "/home/yoyo/miniconda2/envs/scTE/lib/python3.7/site-packages/pkg_resources/__init__.py", line 1448, in run_script
    exec(code, namespace, namespace)
  File "/home/yoyo/miniconda2/envs/scTE/lib/python3.7/site-packages/scTE-1.0-py3.7.egg/EGG-INFO/scripts/scTE", line 169, in <module>
    main()
  File "/home/yoyo/miniconda2/envs/scTE/lib/python3.7/site-packages/scTE-1.0-py3.7.egg/EGG-INFO/scripts/scTE", line 134, in main
    pool.map(partial_work, chr_list)
  File "/home/yoyo/miniconda2/envs/scTE/lib/python3.7/multiprocessing/pool.py", line 268, in map
    return self._map_async(func, iterable, mapstar, chunksize).get()
  File "/home/yoyo/miniconda2/envs/scTE/lib/python3.7/multiprocessing/pool.py", line 657, in get
    raise self._value
IndexError: list index out of range
jphe commented 3 years ago

there should be a folder named samplename_tmp, and you can see the files under that folder

leeyoyohku commented 3 years ago

Thank you @jphe . Seems I don't have the o3 and o4 in the tmp folder.

image
jphe commented 3 years ago

Can you check the file size under o2 folder? and also the file format are correct?.

image

for the bed file:

image

for the count file:

image
leeyoyohku commented 3 years ago

@jphe Thank you. The file sizes and contents look normal tho. But somehow only chr1 count file is lacking.

image image image