primerDesign icon indicating copy to clipboard operation
primerDesign copied to clipboard

error blast

Open frankbioinfo opened this issue 7 years ago • 15 comments

I am using the example file from previous issue that you had uploaded (exampleVar.txt) and config file as described using hg19 fasta i get this error

2017-05-16 17:18:11.326957 Primers to test: 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-16 17:18:11.332841 potUnique 0.01 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-16 17:18:11.338627 potUnique 0.1 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-16 17:18:11.344542 potUnique 1 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-16 17:18:11.350145 potUnique 10 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-16 17:18:11.355408 potUnique 100 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-16 17:18:11.361081 potUnique 10 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-16 17:18:11.366995 potUnique 100 0 unique primers: 0 non-unique primers: 0 forbidden primers: 0 2017-05-16 17:18:11.372512

Not sure what it means

frankbioinfo avatar May 16 '17 22:05 frankbioinfo

Can you please upload the config file you used and post the command you use to run the pipeline. This might help to identify the problem. Thanks!

zichner avatar May 17 '17 20:05 zichner

PrimerDesign 2.cfg.zip exampleVar (1).txt

command: python primerDesign.py PrimerDesign.2.cfg exampleVar.txt results.txt

frankbioinfo avatar May 18 '17 11:05 frankbioinfo

does it help?

frankbioinfo avatar May 19 '17 21:05 frankbioinfo

Thanks for the files. I am currently looking into the issue. Can you please also post the full program output (including the part before the error). Thanks.

zichner avatar May 19 '17 21:05 zichner

The fact that your output says Primers to test: 0 indicates that there might have been a problem with the primer3 step and therefore, no primers were predicted. Was there any error message related to primer3?

zichner avatar May 20 '17 21:05 zichner

No error related to primer3. but here is weird thing I get an output file but still see these error (attached result out file and the full error file. (can i trust the output) primerdesign_full report.txt )

Number of variants left: 1 2017-05-17 11:26:09.789408 Primers to test: 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-17 11:26:09.795314 potUnique 0.01 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-17 11:26:09.801093 potUnique 0.1 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-17 11:26:09.807209 potUnique 1 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-17 11:26:09.813552 potUnique 10 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-17 11:26:09.819844 potUnique 100 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-17 11:26:09.825203 potUnique 10 0 [blast] ERROR: Length of a discontiguous word template (contiguous word if 0) [ask] is bad or out of range [? to ?] 2017-05-17 11:26:09.830575 potUnique 100 0 unique primers: 176 non-unique primers: 0 forbidden primers: 0 results_out.txt

Thank you for looking in to this, appreciate it.

frankbioinfo avatar May 21 '17 16:05 frankbioinfo

The full output shows that the BLAST step (checking whether primers are unique) is not working. As a consequence, the results you get are not correct (the primers are valid but they are not necessarily specific).

In order to make the usage of primerDesign much easier, I now build a Docker container that contains all necessary software tools as well as a BLAST database for human. This should solve the problems. It would be great if you could try it. You can find all details in the README.md file. Please note: The BLAST DB used in the Docker container is based on the human reference genome version hs37d5 (provided by the 1000 genomes project). As a consequence, chromosome names must not contain chr (see the exampleVariants.txt file).

zichner avatar May 21 '17 20:05 zichner

Ah ha!, the docker to rescue again! thank you docker should solve most of the issues. will keep you posted.

frankbioinfo avatar May 22 '17 00:05 frankbioinfo

@zichner is this correct? using stringent25bp and example file as is please see below log and error docker pull zichner/primer-design Using default tag: latest

latest: Pulling from zichner/primer-design b6f892c0043b: Pull complete 55010f332b04: Pull complete 2955fb827c94: Pull complete 3deef3fcbd30: Pull complete cf9722e506aa: Pull complete 5a082b0edddc: Pull complete ad8eeb4b89c8: Pull complete f7f62b705823: Pull complete 93b32fb35380: Pull complete 270f1435739b: Pull complete 3596da27f287: Pull complete Digest: sha256:20e5448e1ab5643907cea7e2d3c7a07fce7bde820d2d75029d415fdc0247fd6d Status: Downloaded newer image for zichner/primer-design:latest

#created a folder primer_design within documents.

docker run -v /Users/s/Documents/primer_design/ zichner/primer-design /Users/s/Documents/primer_design/primer_design_config_docker.cfg /Users/s/Documents/primer_design/examplevariants_docker.txt /Users/s/Documents/primer_design/results.txt 2017-05-31 15:24:15.968219 Traceback (most recent call last): File "/opt/primerDesign/primerDesign.py", line 471, in main() File "/opt/primerDesign/primerDesign.py", line 24, in main maxSeqDist = config.getint("PrimerDesign", "max_dist_for_sequencing") File "/usr/lib/python2.7/ConfigParser.py", line 359, in getint return self._get(section, int, option) File "/usr/lib/python2.7/ConfigParser.py", line 356, in _get return conv(self.get(section, option)) File "/usr/lib/python2.7/ConfigParser.py", line 607, in get raise NoSectionError(section) ConfigParser.NoSectionError: No section: 'PrimerDesign'

frankbioinfo avatar May 31 '17 15:05 frankbioinfo

Docker run with multiple options #1 docker run zichner/primer-design python primerDesign.py 2017-05-31 16:16:44.930912 Traceback (most recent call last): File "/opt/primerDesign/primerDesign.py", line 471, in main() File "/opt/primerDesign/primerDesign.py", line 24, in main maxSeqDist = config.getint("PrimerDesign", "max_dist_for_sequencing") File "/usr/lib/python2.7/ConfigParser.py", line 359, in getint return self._get(section, int, option) File "/usr/lib/python2.7/ConfigParser.py", line 356, in _get return conv(self.get(section, option)) File "/usr/lib/python2.7/ConfigParser.py", line 607, in get raise NoSectionError(section)

#2 docker run zichner/primer-design python /opt/primerDesign/primerDesign.py 2017-05-31 16:18:11.307375 Traceback (most recent call last): File "/opt/primerDesign/primerDesign.py", line 471, in main() File "/opt/primerDesign/primerDesign.py", line 24, in main maxSeqDist = config.getint("PrimerDesign", "max_dist_for_sequencing") File "/usr/lib/python2.7/ConfigParser.py", line 359, in getint return self._get(section, int, option) File "/usr/lib/python2.7/ConfigParser.py", line 356, in _get return conv(self.get(section, option)) File "/usr/lib/python2.7/ConfigParser.py", line 607, in get raise NoSectionError(section) ConfigParser.NoSectionError: No section: 'PrimerDesign'

#3 docker run zichner/primer-design 2017-05-31 16:18:53.189541 Traceback (most recent call last): File "/opt/primerDesign/primerDesign.py", line 471, in main() File "/opt/primerDesign/primerDesign.py", line 23, in main config.read(sys.argv[1]) IndexError: list index out of range

frankbioinfo avatar May 31 '17 16:05 frankbioinfo

When you use a docker container and want to access files from your normal file system, you have to map a directory of your file system to a directory inside the docker container. Afterwards you can access the files as if they were inside the container (ie., you have to use the directory structure as it is in the container).

So, in your case the command should be:

docker run -v /Users/s/Documents/primer_design:/data/ zichner/primer-design /data/primer_design_config_docker.cfg /data/examplevariants_docker.txt /data/results.txt

However, /data/ is specified as the working directory in the container, so you can omit it in the file paths and just do:

docker run -v /Users/s/Documents/primer_design:/data/ zichner/primer-design primer_design_config_docker.cfg examplevariants_docker.txt results.txt

Both commands assume that you have the files primer_design_config_docker.cfg and examplevariants_docker.txt in the directory /Users/s/Documents/primer_design.

I hope this helps.

zichner avatar May 31 '17 21:05 zichner

results.txt Option1 worked! Thanks attached result and log, any red flags? primerdesign.log.txt

frankbioinfo avatar May 31 '17 22:05 frankbioinfo

Thank you for your help, I have one last question what was your approach to build the example variant file do you have a snippet of the input and output for that file if you do not mind educating me. Appreciate your help.

frankbioinfo avatar May 31 '17 22:05 frankbioinfo

The log file you sent seems ok. To be sure that the predicted primers are correct, you can blast/blat a few of them by hand to check whether they map to the expected location in the genome.

Regarding your question about the example variant file, I am not entirely sure what you mean. The example file is just a list of completely arbitrary genomic regions and SV types.

zichner avatar Jun 04 '17 14:06 zichner

Just a thank you note - the docker version will be useful for my students etc! christos

proukakis avatar Jul 17 '17 08:07 proukakis