@options = qw(
in_file|i=s
genome|g=s
+ seed_size|s=s
mismatches|m=s
gap_size|G=s
cpus|c=s
my ( $genome, $tmp_in, $tmp_out, $fh_in, $fh_out, $record, $line, @fields, $entry );
+ $options->{ "seed_size" } ||= 10;
$options->{ "mismatches" } ||= 2;
$options->{ "gap_size" } ||= 0;
$options->{ "cpus" } ||= 1;
close $fh_out;
- Maasha::Common::run( "soap", "-r 2 -a $tmp_in -v $options->{ 'mismatches' } -g $options->{ 'gap_size' } -p $options->{ 'cpus' } -d $options->{ 'in_file' } -o $tmp_out > /dev/null 2>&1", 1 );
+ Maasha::Common::run( "soap", "-s $options->{ 'seed_size' } -r 2 -a $tmp_in -v $options->{ 'mismatches' } -g $options->{ 'gap_size' } -p $options->{ 'cpus' } -d $options->{ 'in_file' } -o $tmp_out > /dev/null 2>&1", 1 );
unlink $tmp_in;
$sid = $2;
$pid = $3;
- if ( not Maasha::Common::process_running( $pid ) )
+ if ( $user eq Maasha::Common::get_user() )
{
- # print STDERR "Removing stale dir: $dir\n";
- Maasha::Common::dir_remove( $dir );
- }
- elsif ( $pid == $curr_pid )
- {
- # print STDERR "Removing current dir: $dir\n";
- Maasha::Common::dir_remove( $dir );
+ if ( not Maasha::Common::process_running( $pid ) )
+ {
+ # print STDERR "Removing stale dir: $dir\n";
+ Maasha::Common::dir_remove( $dir );
+ }
+ elsif ( $pid == $curr_pid )
+ {
+ # print STDERR "Removing current dir: $dir\n";
+ Maasha::Common::dir_remove( $dir );
+ }
}
}
}