[Biojava-l] Exception on Running BlastLikeSearchBuilder with null query SequenceDB

Jianjun Wang jwang at biohealthbase.org
Tue Sep 4 14:17:02 UTC 2007


Oh, no, not PsiBlast. I'm using ncbi blastn. Thx.
  _____  

From: Mark Schreiber [mailto:markjschreiber at gmail.com]
To: Jianjun Wang [mailto:jwang at biohealthbase.org]
Cc: biojava-l at lists.open-bio.org
Sent: Tue, 04 Sep 2007 10:05:46 -0400
Subject: Re: [Biojava-l] Exception on Running BlastLikeSearchBuilder with null query SequenceDB

Hello -
  
  Just out of interest what type of blast were you running. Some of the
  more exotic forms like PSIBlast probably don't work well.
  
  - Mark
  
  On 9/4/07, Jianjun Wang <jwang at biohealthbase.org> wrote:
  > Hi Colleagues,
  >
  > I used the Blast parsing example from the Biojava tutorial and ran into this problem:
  > ######################
  > Failed to build SeqSimilaritySearchResult:
  > org.biojava.bio.BioException: Running BlastLikeSearchBuilder with null query SequenceDB
  >     at org.biojava.bio.program.ssbind.BlastLikeSearchBuilder.makeSearchResult(BlastLikeSearchBuilder.java:239)
  >     at org.biojava.bio.program.ssbind.BlastLikeSearchBuilder.endSearch(BlastLikeSearchBuilder.java:319)
  >     at org.biojava.bio.program.ssbind.SeqSimilarityStAXAdapter.endElement(SeqSimilarityStAXAdapter.java:119)
  >     at org.biojava.utils.stax.SAX2StAXAdaptor.endElement(SAX2StAXAdaptor.java:153)
  >     at org.biojava.bio.program.ssbind.SeqSimilarityAdapter.endElement(SeqSimilarityAdapter.java:136)
  >     at org.biojava.bio.program.sax.AbstractNativeAppSAXParser.endElement(AbstractNativeAppSAXParser.java:300)
  >     at org.biojava.bio.program.sax.BlastSAXParser.parse(BlastSAXParser.java:181)
  >     at org.biojava.bio.program.sax.BlastLikeSAXParser.onNewDataSet(BlastLikeSAXParser.java:311)
  >     at org.biojava.bio.program.sax.BlastLikeSAXParser.interpret(BlastLikeSAXParser.java:274)
  >     at org.biojava.bio.program.sax.BlastLikeSAXParser.parse(BlastLikeSAXParser.java:160)
  >
  > ###########################
  >
  > I  experimented with both supported Blast versions such as 2.2.3 and later  ones, such as 2.2.13, and with the lazymode both on and off, and  concluded that this problem is independent of Blast version and the  lazymode. My debugging didn't yield much fruit, except that the obvious  cause of the exception was BlastLikeSearchBuilder.querySeqHolder being  null. Can someone shed some light on this?
  >
  > Here is the relevant section of my code:
  >
  >         try {
  >               StringReader sr = new StringReader(in);
  >               BlastLikeSAXParser parser = new BlastLikeSAXParser();
  >               //works for 2.2.13?
  >               //parser.setModeLazy();
  >
  >               //make the SAX event adapter that will pass events to a Handler.
  >               SeqSimilarityAdapter adapter = new SeqSimilarityAdapter();
  >
  >               //set the parsers SAX event adapter
  >               parser.setContentHandler(adapter);
  >
  >               //The list to hold the SeqSimilaritySearchResults
  >               //List results = new ArrayList();
  >
  >               //create the SearchContentHandler that will build SeqSimilaritySearchResults
  >               //in the results List
  >               SearchContentHandler builder = new BlastLikeSearchBuilder(results);
  >
  >               //register builder with adapter
  >               adapter.setSearchContentHandler(builder);
  >
  >               //parse the file, after this the result List will be populated with SeqSimilaritySearchResults
  >               parser.parse(new InputSource(sr));
  >
  >               //output some blast details - expect 1 result only
  >               ......
  >
  > Thanks,
  > Jianjun
  > _______________________________________________
  > Biojava-l mailing list  -  Biojava-l at lists.open-bio.org
  > http://lists.open-bio.org/mailman/listinfo/biojava-l
  >
    



More information about the Biojava-l mailing list