Result:
found more than 559 distributions - search limited to the first 2001 files matching your query ( run in 1.186 )


Algorithm-Evolutionary-Fitness

 view release on metacpan or  search on metacpan

lib/Algorithm/Evolutionary/Fitness/ECC.pm  view on Meta::CPAN


"                                                    The ECC problem was presented in
[MW]. We will consider a three-tuple (n, M, d), where n is the length of each codeword
(number of bits), M is the number of codewords, and d is the minimum Hamming
distance between any pair of codewords. Our objective will be to find a code which
has a value for d as large as possible (reflecting greater tolerance to noise and errors),
given previously fixed values for n and M . The problem we have studied is a simplified
version of that in [MW]. In our case we search half of the codewords (M/2) that will
compose the code, and the other half is made up by the complement of the codewords
computed by the algorithm"

 view all matches for this distribution


Algorithm-Evolutionary-Utils

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

2016-03-22  JJ Merelo  <jmerelo@flash>

	* lib/Algorithm/Evolutionary/Utils.pm (consensus): Fixes the consensus string and changes threshold. 
	Covering also default values.
	Improving coverage of conditionals and testing new version.
	Fixes error generating random bitstring: Always generated hashref.

2016-03-21  JJ Merelo  <jmerelo@flash>

	* lib/Algorithm/Evolutionary/Utils.pm: bumping up version to 1.0.1 with generation of seudo-chromosomes
	

Changes  view on Meta::CPAN

	* MANIFEST: Eliminating pod.t also in production code.

2012-07-09  Juan J. Merelo Guervós  <jjmerelo@gmail.com>

	* MANIFEST: Eliminated pod-coverage.t, which is not needed for
	production and causes errors in some systems. 

2012-07-08  Juan J. Merelo Guervós  <jjmerelo@gmail.com>

	* MANIFEST: Adding missing test files

Changes  view on Meta::CPAN


	* lib/Algorithm/Evolutionary/Fitness/Rastrigin.pm (Rastrigin):
	Fixed formula

	* lib/Algorithm/Evolutionary.pm: Starting 0.74_1 with cosmetic
	changes and an attempt to fix sporadic test errors.  

2010-09-24  Juan Julian Merelo Guervos  <jmerelo@usuario-desktop>

	* lib/Algorithm/Evolutionary/Fitness/Rastrigin.pm (Rastrigin): Added first floating-point fitness func.

Changes  view on Meta::CPAN


2009-07-30  Juan Julian Merelo Guervos  <jmerelo@geneura.ugr.es>

	* lib/Algorithm/Evolutionary.pm: Moved a GUI example to the
	scripts dir so that it's installed automatically. Expanded
	documentation to reflect that. Fixed also error (population
	explosion) in Easy_MO.

2009-07-28  Juan Julian Merelo Guervos  <jmerelo@geneura.ugr.es>

	* lib/Algorithm/Evolutionary.pm: Starting 0.70_1 with the

Changes  view on Meta::CPAN


2009-07-24    <jmerelo@localhost.localdomain>

	* lib/Algorithm/Evolutionary.pm: 0.68 was shortlived, but 0.69
	more or less the same. 0.69 included missing file and fixed some
	docs errors; 0.69_1 starts with the same objective, let's see how
	it ends.

2009-07-24  Juan Julian Merelo Guervos  <jmerelo@geneura.ugr.es>

	* TODO: 0.68 ends with several new test functions added (Trap,

 view all matches for this distribution


Algorithm-Evolutionary

 view release on metacpan or  search on metacpan

lib/Algorithm/Evolutionary/Fitness/ECC.pm  view on Meta::CPAN

Extracted from article "Effects of scale-free and small-world topologies on binary coded self-adaptive CEA", by Giacobini et al [Ga]. Quoting:
"                                                    The ECC problem was presented in
[MW]. We will consider a three-tuple (n, M, d), where n is the length of each codeword
(number of bits), M is the number of codewords, and d is the minimum Hamming
distance between any pair of codewords. Our objective will be to find a code which
has a value for d as large as possible (reflecting greater tolerance to noise and errors),
given previously fixed values for n and M . The problem we have studied is a simplified
version of that in [MW]. In our case we search half of the codewords (M/2) that will
compose the code, and the other half is made up by the complement of the codewords
computed by the algorithm"

 view all matches for this distribution


Algorithm-ExpectationMaximization

 view release on metacpan or  search on metacpan

lib/Algorithm/ExpectationMaximization.pm  view on Meta::CPAN

        my @num_strings = split /  /, $cluster_strings[$i];
        my @cluster_mean = map {/$_num_regex/;$_} split / /, $num_strings[0];
        $data_dimension = @cluster_mean;
        push @means, \@cluster_mean;
        my @covariance_nums = map {/$_num_regex/;$_} split / /, $num_strings[1];
        croak "dimensionality error" if @covariance_nums != 
                                      ($data_dimension ** 2);
        my $cluster_covariance;
        foreach my $j (0..$data_dimension-1) {
            foreach my $k (0..$data_dimension-1) {        
                $cluster_covariance->[$j]->[$k] = 

 view all matches for this distribution


Algorithm-FEC

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

	- apply fix for newer perl versions and additional testing patch by
          Father Chrysostomos.

1.0   Sun Dec 23 16:43:02 CET 2007
	- more small doc fixes.
        - fix a crash occuring while generating an error message.

0.5   Mon Jun 21 15:06:15 CEST 2004
	- check filesize and croak if mmap extends. also laid
          the foundation for auto-extending short segments.
        - small doc corrections by Jochen Stenzel.

 view all matches for this distribution


Algorithm-FastPermute

 view release on metacpan or  search on metacpan

FastPermute.pm  view on Meta::CPAN

=head1 DESCRIPTION

Algorithm::FastPermute generates all the permutations of an array. You pass a
block of code, which will be executed for each permutation. The array will be
changed in place, and then changed back again before C<permute> returns. During
the execution of the callback, the array is read-only and you'll get an error
if you try to change its length. (You I<can> change its elements, but the
consequences are liable to confuse you and may change in future versions.)

You have to pass an array, it can't just be a list. It B<does> work with
special arrays and tied arrays, though unless you're doing something

 view all matches for this distribution


Algorithm-FeatureSelection

 view release on metacpan or  search on metacpan

inc/Module/Install.pm  view on Meta::CPAN

	# Whether or not inc::Module::Install is actually loaded, the
	# $INC{inc/Module/Install.pm} is what will still get set as long as
	# the caller loaded module this in the documented manner.
	# If not set, the caller may NOT have loaded the bundled version, and thus
	# they may not have a MI version that works with the Makefile.PL. This would
	# result in false errors or unexpected behaviour. And we don't want that.
	my $file = join( '/', 'inc', split /::/, __PACKAGE__ ) . '.pm';
	unless ( $INC{$file} ) { die <<"END_DIE" }

Please invoke ${\__PACKAGE__} with:

inc/Module/Install.pm  view on Meta::CPAN

		# If the modification time is only slightly in the future,
		# sleep briefly to remove the problem.
		my $a = $s - time;
		if ( $a > 0 and $a < 5 ) { sleep 5 }

		# Too far in the future, throw an error.
		my $t = time;
		if ( $s > $t ) { die <<"END_DIE" }

Your installer $0 has a modification time in the future ($s > $t).

inc/Module/Install.pm  view on Meta::CPAN

			# I'm still wondering if we should slurp Makefile.PL to
			# get some context or not ...
			my ($package, $file, $line) = caller;
			die <<"EOT";
Unknown function is found at $file line $line.
Execution of $file aborted due to runtime errors.

If you're a contributor to a project, you may need to install
some Module::Install extensions from CPAN (or other repository).
If you're a user of a module, please contact the author.
EOT

 view all matches for this distribution


Algorithm-FloodControl

 view release on metacpan or  search on metacpan

inc/Module/AutoInstall.pm  view on Meta::CPAN

        return
          unless system( 'sudo', $^X, $0, "--config=$config",
            "--installdeps=$missing" );

        print << ".";
*** The 'sudo' command exited with error!  Resuming...
.
    }

    return _prompt(
        qq(

 view all matches for this distribution


Algorithm-FuzzyCmeans

 view release on metacpan or  search on metacpan

inc/Module/Install.pm  view on Meta::CPAN

# Whether or not inc::Module::Install is actually loaded, the
# $INC{inc/Module/Install.pm} is what will still get set as long as
# the caller loaded module this in the documented manner.
# If not set, the caller may NOT have loaded the bundled version, and thus
# they may not have a MI version that works with the Makefile.PL. This would
# result in false errors or unexpected behaviour. And we don't want that.
my $file = join( '/', 'inc', split /::/, __PACKAGE__ ) . '.pm';
unless ( $INC{$file} ) { die <<"END_DIE" }

Please invoke ${\__PACKAGE__} with:

inc/Module/Install.pm  view on Meta::CPAN

	# If the modification time is only slightly in the future,
	# sleep briefly to remove the problem.
	my $a = $s - time;
	if ( $a > 0 and $a < 5 ) { sleep 5 }

	# Too far in the future, throw an error.
	my $t = time;
	if ( $s > $t ) { die <<"END_DIE" }

Your installer $0 has a modification time in the future ($s > $t).

 view all matches for this distribution


Algorithm-GDiffDelta

 view release on metacpan or  search on metacpan

GDiffDelta.pm  view on Meta::CPAN

This generates a binary delta describing the changes from I<$file1>
to I<$file2>.  The delta will allow I<$file2> to be reconstructed
from I<$file1> later.

No value is returned.  Errors will cause this function to croak
with a suitable error message.

=item gdiff_delta(I<$file1>, I<$delta_file>, I<$file2>)

Takes three file handles.  The first two are read from, and it must
be possible to seek in them.  The third is written to.

The delta is used to reconstruct I<$file2> from I<$file1>.
The delta must be a valid GDIFF file.

No value is returned.  Errors will cause this function to croak
with a suitable error message.

=back

=head1 ALGORITHM AND DELTA FORMAT

 view all matches for this distribution


Algorithm-Genetic-Diploid

 view release on metacpan or  search on metacpan

lib/Algorithm/Genetic/Diploid/Logger.pm  view on Meta::CPAN


sub FATAL () { 0 }

=item ERROR

Possibly unrecoverable errors are transmitted.

=cut

sub ERROR () { 1 }

lib/Algorithm/Genetic/Diploid/Logger.pm  view on Meta::CPAN

sub DEBUG () { 4 }

# constants mapped to string for AUTOLOAD
my %levels = (
	'fatal' => FATAL,
	'error' => ERROR,
	'warn'  => WARN,
	'info'  => INFO,
	'debug' => DEBUG,
);

 view all matches for this distribution


Algorithm-GooglePolylineEncoding

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

	- stable release with changes in 0.05_50

0.05_50	2017-12-31
	- fix encode_level for large integers (by using
	  Math::BigInt's as_bin)
	  This should fix the test errors seen on 32bit
	  systems.

0.05	2017-06-10
	- fix link in documentation

 view all matches for this distribution


Algorithm-Graphs-TransitiveClosure

 view release on metacpan or  search on metacpan

t/000_tests.t  view on Meta::CPAN

    else {
        print "not ok ", $test_num ++, "\n";
    }
};

if ($@) {print "... error: $@\n";}

eval {
    my $graph = {
        one   => {one => 1},
        two   => {two => 1, three => 1, four => 1},

t/000_tests.t  view on Meta::CPAN

    else {
        print "not ok ", $test_num ++, "\n";
    }
};

if ($@) {print "... error: $@\n";}

 view all matches for this distribution


Algorithm-Gutter

 view release on metacpan or  search on metacpan

lib/Algorithm/Gutter.pm  view on Meta::CPAN

to water accumulating and then dripping out of a rain gutter.

The cells are held in an array reference (the B<gutter>); the caller may
need to fiddle around with the cells directly simulate various effects.

Various methods may throw errors, for example if a cell lacks an update
callback function. Such callbacks are not mandatory to give the caller
flexibility in wiring up the gutter in fancy ways.

=head1 FIELDS

lib/Algorithm/Gutter.pm  view on Meta::CPAN


=back

=head1 BUGS

These probably should be called errors, not bugs.

=head1 SEE ALSO

L<Object::Pad>

 view all matches for this distribution


Algorithm-HITS-Lite

 view release on metacpan or  search on metacpan

inc/Module/Install.pm  view on Meta::CPAN

# Whether or not inc::Module::Install is actually loaded, the
# $INC{inc/Module/Install.pm} is what will still get set as long as
# the caller loaded module this in the documented manner.
# If not set, the caller may NOT have loaded the bundled version, and thus
# they may not have a MI version that works with the Makefile.PL. This would
# result in false errors or unexpected behaviour. And we don't want that.
my $file = join( '/', 'inc', split /::/, __PACKAGE__ ) . '.pm';
unless ( $INC{$file} ) {
    die <<"END_DIE";
Please invoke ${\__PACKAGE__} with:

 view all matches for this distribution


Algorithm-HITS

 view release on metacpan or  search on metacpan

Changes  view on Meta::CPAN

0.01  Sat, 21 Aug 2004 07:22:53 +0800
	- original version


0.02  Sat, 21 Aug 2004 11:52:52 +0800
	- corrected my previous moronic computation error

0.03  Sun, 22 Aug 2004 17:29:40 +0800
	- update in test

0.04  Sun, 14 Aug 2005 13:10:10 +0800

 view all matches for this distribution


Algorithm-Hamming-Perl

 view release on metacpan or  search on metacpan

Perl.pm  view on Meta::CPAN

# 	with memory and CPU efficiencu in mind (without resorting to C).
#
sub unhamming_err {
	my $data = shift;	# input data
	my $pos;		# counter to step through data string
	my $err;		# corrected bit error
	my $chars_in;		# input bytes
	my $ham_text;		# hamming code in binary text "0101..", 2 bytes
	my $ham_text1;		# hamming code for first byte
	my $ham_text2;		# hamming code for second byte
	my $char_out1;		# output data byte 1
	my $char_out2;		# output data byte 2
	my $output = "";	# full output data as bytes
	my $err_all = 0;	# count of corrected bit errors

	my $length = length($data);
	
	# 
	#  Step through the $data 3 bytes at a time, decoding it back into

Perl.pm  view on Meta::CPAN

#		occured.
#
sub unhamchar {
	my $text = shift;
	my $pos = 0;				# counter
	my $err = 0;				# error bit position
	my ($bit);

	### If okay, return now
	if (defined $Hamming8rev{$text}) {
		return ($Hamming8rev{$text},0);
	}

	### Find error bit
	my $copy = $text;
	while ($copy ne "") {
		$pos++;
		$bit = chop($copy);
		if ($bit eq "1") {
			$err = $err ^ $pos;
		}
	}

	### Correct error bit
	$copy = $text;
	if ($err <= 12) {
		$bit = substr($copy,-$err,1);
		if ($bit eq "0") { $bit = "1"; }
		 else { $bit = "0"; }

Perl.pm  view on Meta::CPAN

# Below is stub documentation for your module. You better edit it!

=head1 NAME

Algorithm::Hamming::Perl - Perl implementation of ECC Hamming encoding, 
for single bit auto error correction.

=head1 SYNOPSIS

use Algorithm::Hamming::Perl  qw(hamming unhamming);

$code = hamming($data);              # Encode $data

$data = unhamming($code);            # Decode and fix errors
($data,$errors) = unhamming($code);  #  + return error count


=head1 DESCRIPTION

This is an Error Correction Code module, implementing Hamming encoding
(8 bits data, 4 bits Hamming - ie increases data size by 50%). Data can
be encoded so that single bit errors within a byte are auto-corrected.

This may be useful as a precaution before storing or sending data where
single bit errors are expected.

Hamming encoding was invented by Richard Hamming, Bell Labs, during 1948.

=head1 EXPORT SUBROUTINES

Perl.pm  view on Meta::CPAN


Returns the Hamming code from the provided input data.

=item unhamming (SCALAR)

Returns the original data from the provided Hamming code. Single bit errors
are auto corrected.

=item unhamming_err (SCALAR)

Returns the original data from the provided Hamming code, and a number counting
the number of bytes that were corrected. Single bit errors are auto corrected. 

=back

=head1 OTHER SUBROUTINES

Perl.pm  view on Meta::CPAN

   $original = unhamming($hamcode);

=head1 LIMITATIONS

This is Perl only and can be slow. The Hamming encoding used can only
repair a single bit error within a byte - ie if two bits are damaged within
the one byte then this encoding cannot auto correct the error.

=head1 BUGS

Try not to join Hamming encoded strings together - this may give results
that look like a bug. If an odd number of input byes is encoded, the output

 view all matches for this distribution


Algorithm-Heapify-XS

 view release on metacpan or  search on metacpan

ppport.h  view on Meta::CPAN

  --diff=program              use diff program and options

  --compat-version=version    provide compatibility with Perl version
  --cplusplus                 accept C++ comments

  --quiet                     don't output anything except fatal errors
  --nodiag                    don't show diagnostics
  --nohints                   don't show hints
  --nochanges                 don't suggest changes
  --nofilter                  don't filter input files

ppport.h  view on Meta::CPAN

Using this option instructs F<ppport.h> to leave C++
comments untouched.

=head2 --quiet

Be quiet. Don't print anything except fatal errors.

=head2 --nodiag

Don't output any diagnostic messages. Only portability
alerts will be printed.

ppport.h  view on Meta::CPAN

PL_defgv|5.004050||p
PL_diehook|5.004050||p
PL_dirty|5.004050||p
PL_dowarn|||pn
PL_errgv|5.004050||p
PL_error_count|5.014000||p
PL_expect|5.014000||p
PL_hexdigit|5.005000||p
PL_hints|5.005000||p
PL_in_my_stash|5.014000||p
PL_in_my|5.014000||p

ppport.h  view on Meta::CPAN

PUTBACK|||
PerlIO_clearerr||5.007003|
PerlIO_close||5.007003|
PerlIO_context_layers||5.009004|
PerlIO_eof||5.007003|
PerlIO_error||5.007003|
PerlIO_fileno||5.007003|
PerlIO_fill||5.007003|
PerlIO_flush||5.007003|
PerlIO_get_base||5.007003|
PerlIO_get_bufsiz||5.007003|

ppport.h  view on Meta::CPAN

put_byte|||
pv_display|5.006000||p
pv_escape|5.009004||p
pv_pretty|5.009004||p
pv_uni_display||5.007003|
qerror|||
qsortsvu|||
re_compile||5.009005|
re_croak2|||
re_dup_guts|||
re_intuit_start||5.009005|

ppport.h  view on Meta::CPAN

warner_nocontext|||vn
warner|5.006000|5.004000|pv
warn|||v
watch|||
whichsig|||
with_queued_errors|||
write_no_mem|||
write_to_stderr|||
xmldump_all_perl|||
xmldump_all|||
xmldump_attr|||

ppport.h  view on Meta::CPAN

xmldump_sub_perl|||
xmldump_sub|||
xmldump_vindent|||
xs_apiversion_bootcheck|||
xs_version_bootcheck|||
yyerror|||
yylex|||
yyparse|||
yyunlex|||
yywarn|||
);

ppport.h  view on Meta::CPAN


  if ($file{changes}) {
    if (exists $opt{copy}) {
      my $newfile = "$filename$opt{copy}";
      if (-e $newfile) {
        error("'$newfile' already exists, refusing to write copy of '$filename'");
      }
      else {
        local *F;
        if (open F, ">$newfile") {
          info("Writing copy of '$filename' with changes to '$newfile'");
          print F $c;
          close F;
        }
        else {
          error("Cannot open '$newfile' for writing: $!");
        }
      }
    }
    elsif (exists $opt{patch} || $opt{changes}) {
      if (exists $opt{patch}) {
        unless ($patch_opened) {
          if (open PATCH, ">$opt{patch}") {
            $patch_opened = 1;
          }
          else {
            error("Cannot open '$opt{patch}' for writing: $!");
            delete $opt{patch};
            $opt{changes} = 1;
            goto fallback;
          }
        }

ppport.h  view on Meta::CPAN

  if (!defined $diff) {
    $diff = run_diff('diff', $file, $str);
  }

  if (!defined $diff) {
    error("Cannot generate a diff. Please install Text::Diff or use --copy.");
    return;
  }

  print F $diff;
}

ppport.h  view on Meta::CPAN

    }

    unlink $tmp;
  }
  else {
    error("Cannot open '$tmp' for writing: $!");
  }

  return undef;
}

ppport.h  view on Meta::CPAN

{
  $opt{quiet} and return;
  print "*** ", @_, "\n";
}

sub error
{
  print "*** ERROR: ", @_, "\n";
}

my %given_hints;

ppport.h  view on Meta::CPAN


/* It is very unlikely that anyone will try to use this with Perl 6
   (or greater), but who knows.
 */
#if PERL_REVISION != 5
#  error ppport.h only works with Perl version 5
#endif /* PERL_REVISION != 5 */
#ifndef dTHR
#  define dTHR                           dNOOP
#endif
#ifndef dTHX

ppport.h  view on Meta::CPAN

#  define PL_defgv                  defgv
#  define PL_diehook                diehook
#  define PL_dirty                  dirty
#  define PL_dowarn                 dowarn
#  define PL_errgv                  errgv
#  define PL_error_count            error_count
#  define PL_expect                 expect
#  define PL_hexdigit               hexdigit
#  define PL_hints                  hints
#  define PL_in_my                  in_my
#  define PL_laststatval            laststatval

ppport.h  view on Meta::CPAN

# define PL_lex_state      D_PPP_my_PL_parser_var(lex_state)
# define PL_lex_stuff      D_PPP_my_PL_parser_var(lex_stuff)
# define PL_tokenbuf       D_PPP_my_PL_parser_var(tokenbuf)
# define PL_in_my          D_PPP_my_PL_parser_var(in_my)
# define PL_in_my_stash    D_PPP_my_PL_parser_var(in_my_stash)
# define PL_error_count    D_PPP_my_PL_parser_var(error_count)


#else

/* ensure that PL_parser != NULL and cannot be dereferenced */

ppport.h  view on Meta::CPAN


/* Replace perl_eval_pv with eval_pv */

#ifndef eval_pv
#if defined(NEED_eval_pv)
static SV* DPPP_(my_eval_pv)(char *p, I32 croak_on_error);
static
#else
extern SV* DPPP_(my_eval_pv)(char *p, I32 croak_on_error);
#endif

#ifdef eval_pv
#  undef eval_pv
#endif

ppport.h  view on Meta::CPAN

#define Perl_eval_pv DPPP_(my_eval_pv)

#if defined(NEED_eval_pv) || defined(NEED_eval_pv_GLOBAL)

SV*
DPPP_(my_eval_pv)(char *p, I32 croak_on_error)
{
    dSP;
    SV* sv = newSVpv(p, 0);

    PUSHMARK(sp);

ppport.h  view on Meta::CPAN


    SPAGAIN;
    sv = POPs;
    PUTBACK;

    if (croak_on_error && SvTRUE(GvSV(errgv)))
	croak(SvPVx(GvSV(errgv), na));

    return sv;
}

 view all matches for this distribution


Algorithm-Huffman

 view release on metacpan or  search on metacpan

Huffman.pm  view on Meta::CPAN

}


sub __validate_counting_hash {
    my $c = shift;
    my $error_msg = undef;
    defined $c        
        or croak "Undefined counting hash";
    ref($c) eq 'HASH' 
        or croak "The argument for the counting hash is not a hash reference, as expected";
    scalar(keys %$c) >= 2

Huffman.pm  view on Meta::CPAN

  a => 1
  b => 01
  c => 00
  
and wanted to code 'abc'. The right coding is '10100'.
But '1010' (the last 0 is missing) will produce the error message:
C<Unknown bit sequence starting at index 3 in the bitstring>.

=item $huff->decode($bitvector)

Decodes a packed bitvector (encoded with the ->encode method).

 view all matches for this distribution


Algorithm-HyperLogLog

 view release on metacpan or  search on metacpan

lib/Algorithm/HyperLogLog.pm  view on Meta::CPAN

}

sub new_from_file {
    my ( $class, $filename ) = @_;
    open my $fh, '<', $filename or die $!;
    my $on_error = sub { close $fh; croak "Invalid dump file($filename)"; };

    binmode $fh;
    my ( @dumpdata, $buf, $readed );

    # Read register size data
    $readed = read( $fh, $buf, 1 );
    $on_error->() if $readed != 1;
    my $k = unpack 'C', $buf;

    # Read register content data
    my $m = 2**$k;
    $readed = read $fh, $buf, $m;
    $on_error->() if $readed != $m;
    close $fh;
    @dumpdata = unpack 'C*', $buf;
    my $self = $class->_new_from_dump( $k, \@dumpdata );
    return $self;
}

 view all matches for this distribution


Algorithm-IRCSRP2

 view release on metacpan or  search on metacpan

lib/Algorithm/IRCSRP2.pm  view on Meta::CPAN

use Crypt::OpenSSL::AES;

# local
use Algorithm::IRCSRP2::Utils qw(:all);

has 'error' => (
    'isa' => 'Str',
    'is'  => 'rw',
);

has 'nickname' => (

lib/Algorithm/IRCSRP2.pm  view on Meta::CPAN


=item * B<cbc_blocksize> (ro, Int) - CBC blocksize. Defaults to '16'.

=item * B<debug_cb> (rw, CodeRef) - Debug callback. Defaults to C<print()>

=item * B<error> (rw, Str) - If set, there was an error.

=item * B<nickname> (rw, Str) - Child class will set this. Defaults to 'unknown'.

=back

lib/Algorithm/IRCSRP2.pm  view on Meta::CPAN


=item * B<encrypt_message($msg, $who)> - Returns encrypted message with
plaintext C<$msg> from nickname C<$who>.

=item * B<decrypt_message($msg)> - Returns decrypted text from encrypted
C<$msg>. C<die()>s on errors.

=back

=head1 SEE ALSO

 view all matches for this distribution


Algorithm-IncludeExclude

 view release on metacpan or  search on metacpan

inc/Module/AutoInstall.pm  view on Meta::CPAN

        return
          unless system( 'sudo', $^X, $0, "--config=$config",
            "--installdeps=$missing" );

        print << ".";
*** The 'sudo' command exited with error!  Resuming...
.
    }

    return _prompt(
        qq(

 view all matches for this distribution


Algorithm-KMeans

 view release on metacpan or  search on metacpan

lib/Algorithm/KMeans.pm  view on Meta::CPAN

        my @num_strings = split /  /, $cluster_strings[$i];
        my @cluster_mean = map {/$_num_regex/;$_} split / /, $num_strings[0];
        $data_dimension = @cluster_mean;
        push @means, \@cluster_mean;
        my @covariance_nums = map {/$_num_regex/;$_} split / /, $num_strings[1];
        croak "dimensionality error" if @covariance_nums != 
                                      ($data_dimension ** 2);
        my $cluster_covariance;
        foreach my $j (0..$data_dimension-1) {
            foreach my $k (0..$data_dimension-1) {        
                $cluster_covariance->[$j]->[$k] = 

lib/Algorithm/KMeans.pm  view on Meta::CPAN

=head1 CHANGES

Version 2.05 removes the restriction on the version of Perl that is required.  This
is based on Srezic's recommendation.  He had no problem building and testing the
previous version with Perl 5.8.9.  Version 2.05 also includes a small augmentation of
the code in the method C<read_data_from_file_csv()> for guarding against user errors
in the specification of the mask that tells the module which columns of the data file
are to be used for clustering.

Version 2.04 allows you to use CSV data files for clustering.

lib/Algorithm/KMeans.pm  view on Meta::CPAN


Version 2.02 downshifts the version of Perl that is required for this module.  The
module should work with versions 5.10 and higher of Perl.  The implementation code
for the module remains unchanged.

Version 2.01 removes many errors in the documentation. The changes made to the module
in Version 2.0 were not reflected properly in the documentation page for that
version.  The implementation code remains unchanged.

Version 2.0 includes significant additional functionality: (1) You now have the
option to cluster using the Mahalanobis distance metric (the default is the Euclidean

 view all matches for this distribution


Algorithm-KNN-XS

 view release on metacpan or  search on metacpan

lib/Algorithm/KNN/XS.pm  view on Meta::CPAN


The default value is 0.

=item * epsilon

The relative error bound for approximate nearest neighbor searching. Please
refer the libANN manual for more information.

The default value is 0.

=item * Return value

lib/Algorithm/KNN/XS.pm  view on Meta::CPAN


The default value is 0.

=item * epsilon

The relative error bound for approximate nearest neighbor searching. Please
refer the libANN manual for more information.

The default value is 0.

=item * Return value

lib/Algorithm/KNN/XS.pm  view on Meta::CPAN


The default value is 0.

=item * epsilon

The relative error bound for approximate nearest neighbor searching. Please
refer the libANN manual for more information.

The default value is 0.

=item * radius

lib/Algorithm/KNN/XS.pm  view on Meta::CPAN


A list of points which must be the same dimension as the tree.

=item * epsilon

The relative error bound for approximate nearest neighbor searching. Please
refer the libANN manual for more information.

The default value is 0.

=item * radius

 view all matches for this distribution


Algorithm-Kademlia

 view release on metacpan or  search on metacpan

README.md  view on Meta::CPAN

## `mark_failed( $id_bin )`

Marks a node as failed (e.g., RPC timeout).

```
# After a timeout or connection error:
$search->mark_failed($peer_id);
```

## `is_finished()`

 view all matches for this distribution


Algorithm-KernelKMeans

 view release on metacpan or  search on metacpan

inc/Module/Install.pm  view on Meta::CPAN

	# Whether or not inc::Module::Install is actually loaded, the
	# $INC{inc/Module/Install.pm} is what will still get set as long as
	# the caller loaded module this in the documented manner.
	# If not set, the caller may NOT have loaded the bundled version, and thus
	# they may not have a MI version that works with the Makefile.PL. This would
	# result in false errors or unexpected behaviour. And we don't want that.
	my $file = join( '/', 'inc', split /::/, __PACKAGE__ ) . '.pm';
	unless ( $INC{$file} ) { die <<"END_DIE" }

Please invoke ${\__PACKAGE__} with:

inc/Module/Install.pm  view on Meta::CPAN

		# If the modification time is only slightly in the future,
		# sleep briefly to remove the problem.
		my $a = $s - time;
		if ( $a > 0 and $a < 5 ) { sleep 5 }

		# Too far in the future, throw an error.
		my $t = time;
		if ( $s > $t ) { die <<"END_DIE" }

Your installer $0 has a modification time in the future ($s > $t).

inc/Module/Install.pm  view on Meta::CPAN

			# I'm still wondering if we should slurp Makefile.PL to
			# get some context or not ...
			my ($package, $file, $line) = caller;
			die <<"EOT";
Unknown function is found at $file line $line.
Execution of $file aborted due to runtime errors.

If you're a contributor to a project, you may need to install
some Module::Install extensions from CPAN (or other repository).
If you're a user of a module, please contact the author.
EOT

 view all matches for this distribution


Algorithm-Kmeanspp

 view release on metacpan or  search on metacpan

inc/Module/Install.pm  view on Meta::CPAN

# Whether or not inc::Module::Install is actually loaded, the
# $INC{inc/Module/Install.pm} is what will still get set as long as
# the caller loaded module this in the documented manner.
# If not set, the caller may NOT have loaded the bundled version, and thus
# they may not have a MI version that works with the Makefile.PL. This would
# result in false errors or unexpected behaviour. And we don't want that.
my $file = join( '/', 'inc', split /::/, __PACKAGE__ ) . '.pm';
unless ( $INC{$file} ) { die <<"END_DIE" }

Please invoke ${\__PACKAGE__} with:

inc/Module/Install.pm  view on Meta::CPAN

	# If the modification time is only slightly in the future,
	# sleep briefly to remove the problem.
	my $a = $s - time;
	if ( $a > 0 and $a < 5 ) { sleep 5 }

	# Too far in the future, throw an error.
	my $t = time;
	if ( $s > $t ) { die <<"END_DIE" }

Your installer $0 has a modification time in the future ($s > $t).

 view all matches for this distribution


Algorithm-Kuhn-Munkres

 view release on metacpan or  search on metacpan

lib/Algorithm/Kuhn/Munkres.pm  view on Meta::CPAN


=back

=head1 DIAGNOSTICS

    Ideally, I would list every single error and warning message that the module can
    generate (even the ones that will "never happen"), with a full
    explanation of each problem, one or more likely causes, and any
    suggested remedies. I'm not that good a person right now.


 view all matches for this distribution


Algorithm-LBFGS

 view release on metacpan or  search on metacpan

inc/Module/AutoInstall.pm  view on Meta::CPAN

        return
          unless system( 'sudo', $^X, $0, "--config=$config",
            "--installdeps=$missing" );

        print << ".";
*** The 'sudo' command exited with error!  Resuming...
.
    }

    return _prompt(
        qq(

 view all matches for this distribution


Algorithm-LUHN

 view release on metacpan or  search on metacpan

lib/Algorithm/LUHN.pm  view on Meta::CPAN

  use Algorithm::LUHN qw/check_digit is_valid/;

  $c = check_digit("43881234567");
  print "It works\n" if is_valid("43881234567$c");

  $c = check_digit("A2C4E6G8"); # this will cause an error

  print "Valid LUHN characters are:\n";
  my %vc = Algorithm::LUHN::valid_chars();
  for (sort keys %vc) {
    print "$_ => $vc{$_}\n";

 view all matches for this distribution


( run in 1.186 second using v1.01-cache-2.11-cpan-c966e8aa7e8 )