[Bio] / FigKernelPackages / FIGMODELmodel.pm Repository:
ViewVC logotype

Diff of /FigKernelPackages/FIGMODELmodel.pm

Parent Directory Parent Directory | Revision Log Revision Log | View Patch Patch

revision 1.29, Mon Aug 30 02:41:43 2010 UTC revision 1.30, Tue Aug 31 14:40:21 2010 UTC
# Line 2123  Line 2123 
2123                  if ($essentialReactions !~ m/$biomassID/) {                  if ($essentialReactions !~ m/$biomassID/) {
2124                          push(@{$ReactionList},$biomassID);                          push(@{$ReactionList},$biomassID);
2125                  }                  }
2126            } else {
2127                    push(@{$ReactionList},$biomassID);
2128          }          }
2129          #Adding biomass reactions to the model table          #Adding biomass reactions to the model table
2130          foreach my $BOFReaction (@{$ReactionList}) {          foreach my $BOFReaction (@{$ReactionList}) {
# Line 4633  Line 4635 
4635  =cut  =cut
4636  sub PrintModelSimpleReactionTable {  sub PrintModelSimpleReactionTable {
4637          my ($self) = @_;          my ($self) = @_;
   
4638          my $rxntbl = $self->reaction_table();          my $rxntbl = $self->reaction_table();
4639          my $tbl = $self->create_table_prototype("ModelSimpleReactionTable");          my $tbl = $self->create_table_prototype("ModelSimpleReactionTable");
4640            $tbl->prefix($self->id()."\n");
4641          for (my $i=0; $i < $rxntbl->size(); $i++) {          for (my $i=0; $i < $rxntbl->size(); $i++) {
4642                  my $row = $rxntbl->get_row($i);                  my $row = $rxntbl->get_row($i);
4643                  $row->{DATABASE} = $row->{LOAD};                  $row->{DATABASE} = $row->{LOAD};
# Line 4680  Line 4682 
4682  =cut  =cut
4683  sub patch_model {  sub patch_model {
4684          my ($self,$arguments) = @_;          my ($self,$arguments) = @_;
4685          if ($self->id() =~ m/Seed/) {          my $growth = $self->growth();
4686            if (!defined($growth) || $growth == 0) {
4687            #if ($self->id() =~ m/Seed/) {
4688                  print "Model qualifies.";                  print "Model qualifies.";
4689                  #$self->BuildSpecificBiomassReaction();                  #$self->BuildSpecificBiomassReaction();
4690                  #my $reactionTable = $self->reaction_table();                  #my $reactionTable = $self->reaction_table();
# Line 4733  Line 4737 
4737                  $self->error_message("integrateUploadedChanges:could not load uploaded reaction table!");                  $self->error_message("integrateUploadedChanges:could not load uploaded reaction table!");
4738                  return undef;                  return undef;
4739          }          }
4740            if (substr($tbl->prefix(),0,length($self->id())) ne $self->id()) {
4741                    $self->error_message("integrateUploadedChanges:model labeled in uploaded file does not match reference model!");
4742                    return undef;
4743            }
4744          my $newrxntbl = $self->reaction_table(1);          my $newrxntbl = $self->reaction_table(1);
4745          if (!defined($newrxntbl)) {          if (!defined($newrxntbl)) {
4746                  $self->error_message("integrateUploadedChanges:could not load reaction table!");                  $self->error_message("integrateUploadedChanges:could not load reaction table!");
# Line 4765  Line 4773 
4773          $self->PrintModelLPFile(1);          $self->PrintModelLPFile(1);
4774          $self->PrintModelSimpleReactionTable();          $self->PrintModelSimpleReactionTable();
4775          $self->update_model_stats();          $self->update_model_stats();
4776          my $growth = $self->calculate_growth()          $self->calculate_growth()
   
         #;  
                 #if ($growth =~ m/^NOGROWTH/ ||  $growth < 1e-5) {  
                 #       $self->error_message("patch_model:model did not grow, gapfilling!");  
                 #       $self->GapFillModel(1);  
                 #       $growth = $self->calculate_growth();  
                 #       if ($growth =~ m/^NOGROWTH/ ||  $growth < 1e-5) {  
                 #               $self->error_message("patch_model:model still did not grow!");  
                 #               print "Patch failed.\n";  
                 #               return;  
                 #       }  
                 #}  
                 #$self->run_default_model_predictions();  
4777  }  }
4778    
4779  =head3 translate_genes  =head3 translate_genes

Legend:
Removed from v.1.29  
changed lines
  Added in v.1.30

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3