Ensembl Perl API:非常容易的例子冻结

时间:2016-03-16 07:18:52

标签: perl

我正在尝试一个来自Ensembl Perl API Tutorial page的非常简单的例子来获取成绩单的序列,但是当我尝试这样做时它会冻结......没有错误没有任何错误。 但是,如果我尝试做其他事情,例如提取外显子,它可以正常工作。 任何时候我想得到任何东西的序列,它就会冻结。

有人遇到过这种情况吗?

这是我正在使用的MWE:

#!/usr/bin/perl -w
use warnings;
use strict;
use Bio::EnsEMBL::Registry;

my $registry = 'Bio::EnsEMBL::Registry';
$registry->load_registry_from_db(
    -host => 'ensembldb.ensembl.org',
    -user => 'anonymous'
);
my $transcript_adaptor = $registry->get_adaptor( 'Human', 'Core', 'Transcript' );

my $stable_id = 'ENST00000528762';
my $transcript = $transcript_adaptor->fetch_by_stable_id($stable_id);
print "$stable_id\n";

my $spseq=$transcript->spliced_seq();
print "$spseq\n";

尝试评论最后两行并添加以下内容以了解如何提取外显子不会导致冻结

foreach my $exon(@{$transcript->get_all_Exons()}){
    my $ex_id=$exon->stable_id();
    print "\tExon $ex_id\n";
}

谢谢!

修改<!/强>

在程序运行(冻结)约3小时后,退出时出现以下错误:

[dcarbajo@bioserver1 src]$ perl test.pl 
ENST00000528762
DBD::mysql::st execute failed: Lost connection to MySQL server during query at /home/dcarbajo/Documents/Postdoc_SIgN/src/ensembl/modules/Bio/EnsEMBL/Utils/SqlHelper.pm line 1022.

-------------------- EXCEPTION --------------------
MSG: Cannot run 'SELECT UPPER(SUBSTR(d.sequence, ?, ?))
FROM dna d
WHERE d.seq_region_id =?
' with params 'ARRAY(0x277af40) ARRAY(0x27d4db8) ARRAY(0x27d4e18)' due to error: DBD::mysql::st execute failed: Lost connection to MySQL server during query at /home/dcarbajo/Documents/Postdoc_SIgN/src/ensembl/modules/Bio/EnsEMBL/Utils/SqlHelper.pm line 1022.

STACK Bio::EnsEMBL::Utils::SqlHelper::_base_execute /home/dcarbajo/Documents/Postdoc_SIgN/src/ensembl/modules/Bio/EnsEMBL/Utils/SqlHelper.pm:1026
STACK Bio::EnsEMBL::Utils::SqlHelper::_execute /home/dcarbajo/Documents/Postdoc_SIgN/src/ensembl/modules/Bio/EnsEMBL/Utils/SqlHelper.pm:971
STACK Bio::EnsEMBL::Utils::SqlHelper::execute_simple /home/dcarbajo/Documents/Postdoc_SIgN/src/ensembl/modules/Bio/EnsEMBL/Utils/SqlHelper.pm:317
STACK Bio::EnsEMBL::Utils::SqlHelper::execute_single_result /home/dcarbajo/Documents/Postdoc_SIgN/src/ensembl/modules/Bio/EnsEMBL/Utils/SqlHelper.pm:510
STACK Bio::EnsEMBL::DBSQL::SequenceAdaptor::_fetch_raw_seq /home/dcarbajo/Documents/Postdoc_SIgN/src/ensembl/modules/Bio/EnsEMBL/DBSQL/SequenceAdaptor.pm:426
STACK Bio::EnsEMBL::DBSQL::BaseSequenceAdaptor::_fetch_seq /home/dcarbajo/Documents/Postdoc_SIgN/src/ensembl/modules/Bio/EnsEMBL/DBSQL/BaseSequenceAdaptor.pm:308
STACK Bio::EnsEMBL::DBSQL::SequenceAdaptor::fetch_by_Slice_start_end_strand /home/dcarbajo/Documents/Postdoc_SIgN/src/ensembl/modules/Bio/EnsEMBL/DBSQL/SequenceAdaptor.pm:204
STACK Bio::EnsEMBL::Slice::subseq /home/dcarbajo/Documents/Postdoc_SIgN/src/ensembl/modules/Bio/EnsEMBL/Slice.pm:719
STACK Bio::EnsEMBL::Exon::seq /home/dcarbajo/Documents/Postdoc_SIgN/src/ensembl/modules/Bio/EnsEMBL/Exon.pm:1469
STACK Bio::EnsEMBL::Transcript::spliced_seq /home/dcarbajo/Documents/Postdoc_SIgN/src/ensembl/modules/Bio/EnsEMBL/Transcript.pm:870
STACK toplevel test.pl:17
Date (localtime)    = Wed Mar 16 17:33:15 2016
Ensembl API version = 83
---------------------------------------------------

0 个答案:

没有答案