[Bio] / Babel / bin / load_subsystems_data.pl Repository:
ViewVC logotype

Diff of /Babel/bin/load_subsystems_data.pl

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

revision 1.1, Mon Sep 27 16:43:28 2010 UTC revision 1.2, Thu Sep 30 19:32:29 2010 UTC
# Line 9  Line 9 
9  use Getopt::Long;  use Getopt::Long;
10    
11  use FIG_Config;  use FIG_Config;
12  use Babel;  use Babel::lib::Babel;
13    
14  my $usage       = "$0 [--verbose] [--dbtype TYPE] [--dbname NAME] [--dbuser USER] [--dbhost HOST] --subsystem SUBSYSTEM_FILE\n";  my $usage       = "$0 [--verbose] [--dbtype TYPE] [--dbname NAME] [--dbuser USER] [--dbhost HOST] --subsystem SUBSYSTEM_FILE\n";
15  my $source_file = '';  my $source_file = '';
# Line 44  Line 44 
44  my ($dbh, $babel);  my ($dbh, $babel);
45  if ($dbname && $dbuser && $dbhost && $dbtype) {  if ($dbname && $dbuser && $dbhost && $dbtype) {
46    $dbh   = DBI->connect("DBI:$dbtype:dbname=$dbname;host=$dbhost", $dbuser, '');    $dbh   = DBI->connect("DBI:$dbtype:dbname=$dbname;host=$dbhost", $dbuser, '');
47    $babel = Babel->new($dbh);    $babel = Babel::lib::Babel->new($dbh);
48  }  }
49  else {  else {
50    $babel = new Babel;    $babel = new Babel;
# Line 85  Line 85 
85    my $ach_func2id = $md5_func_sets->{$md5};    my $ach_func2id = $md5_func_sets->{$md5};
86    
87    while ( my ($ach_f, $ach_id) = each %$ach_func2id ) {    while ( my ($ach_f, $ach_id) = each %$ach_func2id ) {
88        $ach_f =~ s/\[SS\]//;
89        $ach_f =~ s/^\s+//;
90        $ach_f =~ s/\s+$//;
91      if (exists $ss_func2ids->{$ach_f}) {      if (exists $ss_func2ids->{$ach_f}) {
92        foreach my $ss_id ( @{$ss_func2ids->{$ach_f}} ) {        foreach my $ss_id ( @{$ss_func2ids->{$ach_f}} ) {
93          $funcid_ssids->{$ach_id}->{$ss_id} = 1;          $funcid_ssids->{$ach_id}->{$ss_id} = 1;

Legend:
Removed from v.1.1  
changed lines
  Added in v.1.2

MCS Webmaster
ViewVC Help
Powered by ViewVC 1.0.3