aryeelab / guideseq

Analysis pipeline for the GUIDE-seq assay.
GNU Affero General Public License v3.0
75 stars 53 forks source link

unsupported operand type(s) #55

Open frankMusacchia opened 5 years ago

frankMusacchia commented 5 years ago

I am having this problem using the SAM file to identify the off-target

python ~/bin/guideseq-1.0.2/guideseq/guideseq.py identify --aligned ~/Desktop/WORKS/CODE/download/AA_1.sam --target_sequence ctgcgcgctcgctcgctcactgaggccgcccgg --description ABM --genome ~/Desktop/WORKS/CODE/download/ucsc_mm10.fa --outfolder ~/Desktop/WORKS/Analisi/Auricchio/Manel/identify/ [07/08 09:20:09AM][INFO][guideseq] Identifying offtarget sites... [07/08 09:20:09AM][INFO][identifyOfftargetSites] Processing SAM file /home/francesco/Desktop/WORKS/CODE/download/AA_1.sam [07/08 09:20:09AM][ERROR][guideseq] Error identifying offtarget sites. [07/08 09:20:09AM][ERROR][guideseq] Traceback (most recent call last): File "/home/francesco/bin/guideseq-1.0.2/guideseq/guideseq.py", line 224, in identifyOfftargetSites identifyOfftargetSites.analyze(samfile, self.reference_genome, self.identified[sample], annotations) File "/home/francesco/bin/guideseq-1.0.2/guideseq/identifyOfftargetSites.py", line 217, in analyze chromosome_position.addPositionBarcode(chromosome, read_position, strand, barcode, primer, count) File "/home/francesco/bin/guideseq-1.0.2/guideseq/identifyOfftargetSites.py", line 66, in addPositionBarcode self.chromosome_barcode_dict[chromosome][position][strand][barcode] += count TypeError: unsupported operand type(s) for +=: 'int' and 'NoneType'

Do you know what can be the problem? I did not use the UMI and started from "align" step

Thanks a lot for youtr time

EMMA-MGH commented 4 years ago

I also have the same issue as you but I follow all the previous steps, no skip of the UMI step. Do you solve this problem?

martinaryee commented 4 years ago

Are you able to a) check how many reads are in the input SAM file, and b) post a few of the lines from the SAM file?

ajm-scan commented 4 years ago

Using the following command /mnt/shared/tools/samtools-1.9/samtools stats /mnt/data/projects/103807/Variants/recalibrate/103807-001-0011.sam > /mnt/data/projects/103807/Variants/recalibrate/103807-001-0011.samstats I retrieved SN raw total sequences: 801526687 SN filtered sequences: 0 SN sequences: 801526687 SN is sorted: 1 SN 1st fragments: 400727290 SN last fragments: 400799397 SN reads mapped: 800336570

For and example please see the file below

103807-001-0011.small.zip

sowmyaiyer commented 4 years ago

Thank you for providing the information. To help debug further, could you please provide your outputs from the (1) UMItag step and (2) the align step?

Thank you.

ajm-scan commented 4 years ago

I did not use the UMItag step and the align step. The raw data I used does not have any UMI data. The github stated the program can be run in individual parts so I only used already aligned data with the guideseq program for identifying off-target sites.

skqxys commented 2 years ago

Hi, I had the same problem. I didn't use UMI. So I just started from "align".

(guideseq) pan:~/offTarget/GUIDEseq_Data/clean_3rd/downstreamAnalysis$ guideseq.py identify --aligned aligned/px_S81_L003_R1_001.sam --genome ~/reference_genome/hg19/hg19.fa --outfolder ./ --target_sequence '' [08/05 09:07:55PM][INFO][guideseq] Identifying offtarget sites... [08/05 09:07:55PM][INFO][identifyOfftargetSites] Processing SAM file ./aligned/px_S81_L003_R1_001.sam [08/05 09:07:55PM][ERROR][guideseq] Error identifying offtarget sites. [08/05 09:07:55PM][ERROR][guideseq] Traceback (most recent call last): File "/home/pan/miniconda3/envs/guideseq/bin/guideseq.py", line 240, in identifyOfftargetSites self.window_size, self.max_score) File "/home/pan/miniconda3/envs/guideseq/bin/identifyOfftargetSites.py", line 314, in analyze chromosome_position.addPositionBarcode(chromosome, read_position, strand, barcode, primer, count) File "/home/pan/miniconda3/envs/guideseq/bin/identifyOfftargetSites.py", line 60, in addPositionBarcode self.chromosome_barcode_dict[chromosome][position][strand][barcode] += count TypeError: unsupported operand type(s) for +=: 'int' and 'NoneType'

Do you solve this problem?

laurahernandez-hernandez commented 1 year ago

Same problem here, Anyone would have an advice to solve it? [08/10 10:55:00PM][INFO][guideseq] Identifying offtarget sites... [08/10 10:55:00PM][INFO][identifyOfftargetSites] Processing SAM file /home/ngs/Documents/NGS_Analysis/CRISPR_offtarget_test-tools/GUIDE-seq/output/aligned/PTPRC_KO.sam [08/10 10:55:00PM][ERROR][guideseq] Error identifying offtarget sites. [08/10 10:55:00PM][ERROR][guideseq] Traceback (most recent call last): File "/home/ngs/Documents/NGS_Analysis/CRISPR_offtarget_test-tools/GUIDE-seq/guideseq/guideseq/guideseq.py", line 222, in identifyOfftargetSites identifyOfftargetSites.analyze(samfile, self.reference_genome, self.identified[sample], annotations) File "/home/ngs/Documents/NGS_Analysis/CRISPR_offtarget_test-tools/GUIDE-seq/guideseq/guideseq/identifyOfftargetSites.py", line 217, in analyze chromosome_position.addPositionBarcode(chromosome, read_position, strand, barcode, primer, count) File "/home/ngs/Documents/NGS_Analysis/CRISPR_offtarget_test-tools/GUIDE-seq/guideseq/guideseq/identifyOfftargetSites.py", line 66, in addPositionBarcode self.chromosome_barcode_dict[chromosome][position][strand][barcode] += count TypeError: unsupported operand type(s) for +=: 'int' and 'NoneType'

thanks

Anna-xu408 commented 1 year ago

Hi, I had the same problem. I didn't use UMI. Do you solve this problem?

laurahernandez-hernandez commented 1 year ago

HI Anna, sorry for not being very helpful but I was not able to find an answer/solution for that. I got frustrated because it seems to be a common problem if you are not using UMIs but nobody could provide a clear solution.

All the best, Laura

El lun, 26 sept 2022 a las 13:57, Anna-xu408 @.***>) escribió:

Hi, I had the same problem. I didn't use UMI. Do you solve this problem?

— Reply to this email directly, view it on GitHub https://github.com/aryeelab/guideseq/issues/55#issuecomment-1258001028, or unsubscribe https://github.com/notifications/unsubscribe-auth/AQR7CTCLWLKE3BYDHYP2D7DWAGMSPANCNFSM4H6YU27Q . You are receiving this because you commented.Message ID: @.***>

--

Laura Hernández Hernández London, UK