Main > Free Download Search >

Free 0.2 inches to mm software for linux

0.2 inches to mm

Sponsored Links
Sponsored Links
Secleted [ 0 ] software to compare
Results 1 - 15 of about 1806
Music::Scales 0.07

Music::Scales 0.07


Music::Scales can supply necessary notes / offsets for musical scales. more>>
Music::Scales can supply necessary notes / offsets for musical scales.

SYNOPSIS

use Music::Scales;

my @maj = get_scale_notes(Eb); # defaults to major
print join(" ",@maj); # "Eb F G Ab Bb C D"
my @blues = get_scale_nums(bl); # bl,blu,blue,blues
print join(" ",@blues); # "0 3 5 6 7 10"
my %min = get_scale_offsets (G,mm,1); # descending melodic minor
print map {"$_=$min{$_} "} sort keys %min; # "A=0 B=-1 C=0 D=0 E=-1 F=0 G=0"

Given a keynote A-G(#/b) and a scale-name, will return the scale, either as an array of notenames or as a hash of semitone-offsets for each note.

METHODS

get_scale_nums($scale[,$descending])

returns an array of semitone offsets for the requested scale, ascending/descending the given scale for one octave. The descending flag determines the direction of the scale, and also affects those scales (such as melodic minor) where the notes vary depending upon the direction. Scaletypes and valid values for $scale are listed below.

get_scale_notes($notename[,$scale,$descending,$keypref])

returns an array of notenames, starting from the given keynote. Enharmonic equivalencies (whether to use F# or Gb, for instance) are calculated based on the keynote and the scale. Basically, it attempts to do the Right Thing if the scale is an 8-note one, (the 7th in G harmonic minor being F# rather than Gb, although G minor is a flat key), but for any other scales, (Chromatic, blues etc.) it picks equivalencies based upon the keynote. This can be overidden with $keypref, setting to be either # or b for sharps and flats respectively. Cruftiness abounds here.

get_scale_offsets($notename[,$scale,$descending,$keypref])

as get_scale_notes(), except it returns a hash of notenames with the values being a semitone offset (-1, 0 or 1) as shown in the synopsis.

get_scale_MIDI($notename,$octave[,$scale,$descending])

as get_scale_notes(), but returns an array of MIDI note-numbers, given an octave number (-1..9).

get_scale_PDL($notename,$octave[,$scale,$descending])

as get_scale_MIDI(), but returns an array of PDL-format notes.

is_scale($scalename)

returns true if $scalename is a valid scale name used in this module.

<<less
Download (0.013MB)
Added: 2007-08-11 License: Perl Artistic License Price:
806 downloads
Geo::Distance 0.11

Geo::Distance 0.11


Geo::Distance is a Perl module that can calculate distances and closest locations. more>>
Geo::Distance is a Perl module that can calculate distances and closest locations.

SYNOPSIS

use Geo::Distance;
my $geo = new Geo::Distance;
$geo->formula(hsin);
$geo->reg_unit( toad_hop, 200120 );
$geo->reg_unit( frog_hop => 6 => toad_hop );
my $distance = $geo->distance( unit_type, $lon1,$lat1 => $lon2,$lat2 );
my $locations = $geo->closest(
dbh => $dbh,
table => $table,
lon => $lon,
lat => $lat,
unit => $unit_type,
distance => $dist_in_unit
);

This perl library aims to provide as many tools to make it as simple as possible to calculate distances between geographic points, and anything that can be derived from that. Currently there is support for finding the closest locations within a specified distance, to find the closest number of points to a specified point, and to do basic point-to-point distance calculations.

METHODS

new

my $geo = new Geo::Distance;
my $geo = new Geo::Distance( no_units=>1 );

Returns a blessed Geo::Distance object. The new constructor accepts one optional argument.

no_units - Whether or not to load the default units. Defaults to 0 (false).
kilometer, kilometre, meter, metre, centimeter, centimetre, millimeter,
millimetre, yard, foot, inch, light second, mile, nautical mile,
poppy seed, barleycorn, rod, pole, perch, chain, furlong, league,
fathom

formula

if($geo->formula eq hsin){ ... }
$geo->formula(cos);

Allows you to retrieve and set the formula that is currently being used to calculate distances. The availabel formulas are hsin, polar, cos, and mt. hsin is the default and mt/cos are depreciated in favor of hsin. polar should be used when calculating coordinates near the poles.

reg_unit
$geo->reg_unit( $radius, $key );
$geo->reg_unit( $key1 => $key2 );
$geo->reg_unit( $count1, $key1 => $key2 );
$geo->reg_unit( $key1 => $count2, $key2 );
$geo->reg_unit( $count1, $key1 => $count2, $key2 );

This method is used to create custom unit types. There are several ways of calling it, depending on if you are defining the unit from scratch, or if you are basing it off of an existing unit (such as saying 12 inches = 1 foot ). When defining a unit from scratch you pass the name and rho (radius of the earth in that unit) value.

So, if you wanted to do your calculations in human adult steps you would have to have an average human adult walk from the crust of the earth to the core (ignore the fact that this is impossible). So, assuming we did this and we came up with 43,200 steps, youd do something like the following.

# Define adult step unit.
$geo->reg_unit( 43200, adult step );
# This can be read as "It takes 43,200 adult_steps to walk the radius of the earth".

Now, if you also wanted to do distances in baby steps you might think "well, now I gotta get a baby to walk to the center of the earth". But, you dont have to! If you do some research youll find (no research was actually conducted) that there are, on average, 4.7 baby steps in each adult step.

# Define baby step unit.
$geo->reg_unit( 4.7, baby step => adult step );
# This can be read as "4.7 baby steps is the same as one adult step".

And if we were doing this in reverse and already had the baby step unit but not the adult step, you would still use the exact same syntax as above.
distance

my $distance = $geo->distance( unit_type, $lon1,$lat1 => $lon2,$lat2 );

Calculates the distance between two lon/lat points.
closest

my $locations = $geo->closest(
dbh => $dbh,
table => $table,
lon => $lon,
lat => $lat,
unit => $unit_type,
distance => $dist_in_unit
);

This method finds the closest locations within a certain distance and returns an array reference with a hash for each location matched.

The closest method requires the following arguments:

dbh - a DBI database handle
table - a table within dbh that contains the locations to search
lon - the longitude of the center point
lat - the latitude of the center point
unit - the unit of measurement to use, such as "meter"
distance - the distance, in units, from the center point to find locations

The following arguments are optional:

lon_field - the name of the field in the table that contains the longitude, defaults to "lon"
lat_field - the name of the field in the table that contains the latitude, defaults to "lat"
fields - an array reference of extra field names that you would like returned with each location
where - additional rules for the where clause of the sql
bind - an array reference of bind variables to go with the placeholders in where
sort - whether to sort the locations by their distance, making the closest location the first returned
count - return at most these number of locations (implies sort => 1)

This method uses some very simplistic calculations to SQL select out of the dbh. This means that the SQL should work fine on almost any database (only tested on MySQL and SQLite so far) and this also means that it is fast. Once this sub set of locations has been retrieved then more precise calculations are made to narrow down the result set. Remember, though, that the farther out your distance is, and the more locations in the table, the slower your searches will be.

<<less
Download (0.010MB)
Added: 2007-07-24 License: Perl Artistic License Price:
824 downloads
KXStitch 0.8

KXStitch 0.8


KXStitch can be used to create cross stitch patterns. more>>
KXStitchs aim is to create software to allow the creation and editing of cross stitch patterns. Although software for this type of application has existed on the Windows platform for many years, there has never been an application written specifically for the Linux platform.
KXStitch will be developed for Linux using KDE/QT.
Main features:
- Creation of new patterns
- User defined size
- Selection of material type
- Selection of material colour
- Importing of various picture formats
- Importing images from a scanner
- Importing options will allow
- Limiting colours to a specific palette
- Limiting the number of colours
- Setting of the finished size
- Cropping of the image
- Support for transparancy in images
- Use of an image background for tracing
- Editing of existing patterns
- Editing tools will include
- Open and filled recangles
- Open and filled ellipses
- Filled polylines
- Lines
- Erasing stitches and backstitches
- Colour selection from existing stitch
- Swap colours
- Replace colour
- Cut, copy and paste of rectangular regions
- Stitch type and colour masks can be used to limit the selection
- Undo, Redo
- Mirroring
- Rotation
- Scaling
- Resizing of the canvas
- Extending canvas left, top, right, bottom
- Cropping canvas to the pattern
- Cropping canvas to selection
- Inserting rows and columns
- Centering current pattern on the canvas
- Conversion between floss schemes
- Display scales in Stitches,CM and inches
- Use of various floss palettes, DMC, Anchor, Madeira
- Creation of custom palettes
- Creation of new colours
- Use of standard stitches
- Creation of custom stitches
- Free use of backstitching
- Printing of patterns and floss keys
- (implemented, but needs to be enhanced)
- Mapping of symbols to flosses
- Calibration of floss colours
- Adding notes to patterns
- Full previews with layout tools
- Pattern library
Enhancements:
- Added a new palette manager to replace add floss and remove flosses dialogs
- New palette manager allows allocation of strands for stitches and backstitches
- New palette manager allows allocation of symbols for flosses
- Import / Export of library patterns
- Undo / Redo partially implemented
- Faster rendering speed
- Mouse tracking display in the status bar
- Selection tool and drawing tools scroll the editor screen
- Bug fix for using background images not on the local file system
- Bug fix for filenames used on the command line
- Bug fix page page wrapping
<<less
Download (0.71MB)
Added: 2006-07-03 License: GPL (GNU General Public License) Price:
700 downloads
OSSP mm 1.4.2

OSSP mm 1.4.2


OSSP mm is a 2-layer abstraction library which simplifies the usage of shared memory between forked. more>>
OSSP mm is a 2-layer abstraction library which simplifies the usage of shared memory between forked (and this way strongly related) processes under Unix platforms.
On the first layer it hides all platform dependent implementation details (allocation and locking) when dealing with shared memory segments and on the second layer it provides a high-level malloc(3)-style API for a convenient and well known way to work with data structures inside those shared memory segments.
Enhancements:
- A trailing whitespace in mm.pod that confused pod2html(1) and generated bad output was fixed.
<<less
Download (0.33MB)
Added: 2006-08-16 License: GPL (GNU General Public License) Price:
1166 downloads
ImageInfo 1.9

ImageInfo 1.9


ImageInfo is a free Java class to retrieve properties from image files. more>>
ImageInfo is a free Java class to retrieve properties from image files.

The following file formats are currently supported: JPEG, PNG, GIF, BMP, PCX, IFF, RAS, PBM, PGM, PPM and PSD (read why TIFF is not included). ImageInfo can recognize these formats, and in addition determine image width, height and color depth (bits per pixel).

Also check out ffident, my file format (group) and MIME type identification library. It extracts less information than ImageInfo (it only recognizes the format, no metadata), but it supports more formats and new formats can be added by editing a text file. Similar to file(1) / magic(5).

Using ImageInfo from within a Java application or applet

The image file can be any InputStream object or an instance of a class implementing DataInput (like RandomAccessFile). Here is some sample code on how to use the class:

ImageInfo ii = new ImageInfo();
// in can be InputStream or RandomAccessFile (or DataInput)
ii.setInput(in);
/* if you want to know how many images there are in a file,
uncomment the following line; will slow down ImageInfo
with animated GIFs */
//ii.setDetermineImageNumber(true);

// check does the actual work, you wont get results before
// you have called it
if (!ii.check())
{
System.err.println("Not a supported image file format.");
}
else
{
System.out.println(
ii.getFormatName() + ", " +
ii.getMimeType() + ", " +
ii.getWidth() + " x " + ii.getHeight() + " pixels, " +
ii.getBitsPerPixel() + " bits per pixel, " +
ii.getNumberOfImages() + " image(s).");
// there are other properties, check out the API documentation
}

Using ImageInfo as a command line program

ImageInfo also has a main method that makes it a command line tool. Assuming that ImageInfo.class is in your classpath, giving the class to java with some file names as arguments will be sufficient. Here is an example call including output:

$ java ImageInfo test.jpg
test.jpg
File format: JPEG
MIME type: image/jpeg
Width (pixels): 1556
Height (pixels): 2048
Bits per pixel: 24
Progressive: false
Number of images: 1
Physical width (dpi): 300
Physical height (dpi): 300
Physical width (inches): 5.1866665
Physical height (inches): 6.826667

<<less
Download (0.027MB)
Added: 2006-11-14 License: Public Domain Price:
1085 downloads
GNU barcode 0.98 Beta

GNU barcode 0.98 Beta


GNU Barcode is a tool to convert text strings to printed bars. more>>
GNU Barcode is a tool to convert text strings to printed bars. GNU barcode supports a variety of standard codes to represent the textual strings and creates postscript output.
Main features:
- Available as both a library and an executable program
- Supports UPC, EAN, ISBN, CODE39 and other encoding standards
- Postscript and Encapsulated Postscript output
- Accepts sizes and positions as inches, centimeters, millimeters
- Can create tables of barcodes (to print labels on sticker pages)
<<less
Download (0.32MB)
Added: 2006-06-07 License: GPL (GNU General Public License) Price:
1240 downloads
online.php 1.0

online.php 1.0


online.php analyses /var/log/ppp-usage and displays connection statistics. more>>
online.php analyses /var/log/ppp-usage and displays connection statistics. It also prints some information about your current PPP connection.
Well, I was inspired by the script Onlinecalc by Michael Schlenstedt (Michael@adsl4linux.de). His script is heavily based upon "calc" by Ulrich Schmitz.
Since Onlinecalc did not fit my needs, I did a complete rewrite in php.
Main features:
- reads /var/log/ppp-usage and prints a table with a row for each month.
- also calculates the values of the current connection.
- completely written in PHP.
- display connect-time as dd:hh:mm:ss
- display volumes as 123 456 789,12 MB
- displays chronologically (maybe I will change the sorting later to reverse)
<<less
Download (0.004MB)
Added: 2006-06-30 License: GPL (GNU General Public License) Price:
1228 downloads
MP4::Info 1.11

MP4::Info 1.11


MP4::Info is a Perl module that can fetch info from MPEG-4 files (.mp4, .m4a, .m4p, .3gp). more>>
MP4::Info is a Perl module that can fetch info from MPEG-4 files (.mp4, .m4a, .m4p, .3gp).

SYNOPSIS

#!perl -w
use MP4::Info;
my $file = Pearls_Before_Swine.m4a;

my $tag = get_mp4tag($file) or die "No TAG info";
printf "$file is a %s trackn", $tag->{GENRE};

my $info = get_mp4info($file);
printf "$file length is %d:%dn", $info->{MM}, $info->{SS};

my $mp4 = new MP4::Info $file;
printf "$file length is %s, title is %sn",
$mp4->time, $mp4->title;

The MP4::Info module can be used to extract tag and meta information from MPEG-4 audio (AAC) and video files. It is designed as a drop-in replacement for MP3::Info.

<<less
Download (0.13MB)
Added: 2006-11-15 License: Perl Artistic License Price:
1120 downloads
MP3::Info 1.20

MP3::Info 1.20


MP3::Info is a Perl module that can manipulate / fetch info from MP3 audio files. more>>
MP3::Info is a Perl module that can manipulate / fetch info from MP3 audio files.

SYNOPSIS

#!perl -w
use MP3::Info;
my $file = Pearls_Before_Swine.mp3;
set_mp3tag($file, Pearls Before Swine, q"77s",
Sticks and Stones, 1990,
q"(c) 1990 77s LTD.", rock & roll);

my $tag = get_mp3tag($file) or die "No TAG info";
$tag->{GENRE} = rock;
set_mp3tag($file, $tag);

my $info = get_mp3info($file);
printf "$file length is %d:%dn", $info->{MM}, $info->{SS};
my $mp3 = new MP3::Info $file;
$mp3->title(Perls Before Swine);
printf "$file length is %s, title is %sn",
$mp3->time, $mp3->title;

$mp3 = MP3::Info->new(FILE)

OOP interface to the rest of the module. The same keys available via get_mp3info and get_mp3tag are available via the returned object (using upper case or lower case; but note that all-caps "VERSION" will return the module version, not the MP3 version).

Passing a value to one of the methods will set the value for that tag in the MP3 file, if applicable.

use_mp3_utf8([STATUS])

Tells MP3::Info to (or not) return TAG info in UTF-8. TRUE is 1, FALSE is 0. Default is TRUE, if available.

Will only be able to turn it on if Encode is available. ID3v2 tags will be converted to UTF-8 according to the encoding specified in each tag; ID3v1 tags will be assumed Latin-1 and converted to UTF-8.

Function returns status (TRUE/FALSE). If no argument is supplied, or an unaccepted argument is supplied, function merely returns status.

This function is not exported by default, but may be exported with the :utf8 or :all export tag.

use_winamp_genres()

Puts WinAmp genres into @mp3_genres and %mp3_genres (adds 68 additional genres to the default list of 80). This is a separate function because these are non-standard genres, but they are included because they are widely used.

You can import the data structures with one of:
use MP3::Info qw(:genres);
use MP3::Info qw(:DEFAULT :genres);
use MP3::Info qw(:all);

remove_mp3tag (FILE [, VERSION, BUFFER])

Can remove ID3v1 or ID3v2 tags. VERSION should be 1 for ID3v1 (the default), 2 for ID3v2, and ALL for both.

For ID3v1, removes last 128 bytes from file if those last 128 bytes begin with the text TAG. File will be 128 bytes shorter.

For ID3v2, removes ID3v2 tag. Because an ID3v2 tag is at the beginning of the file, we rewrite the file after removing the tag data. The buffer for rewriting the file is 4MB. BUFFER (in bytes) ca change the buffer size.

Returns the number of bytes removed, or -1 if no tag removed, or undef if there is an error.

set_mp3tag (FILE, TITLE, ARTIST, ALBUM, YEAR, COMMENT, GENRE [, TRACKNUM])

set_mp3tag (FILE, $HASHREF)

Adds/changes tag information in an MP3 audio file. Will clobber any existing information in file.

Fields are TITLE, ARTIST, ALBUM, YEAR, COMMENT, GENRE. All fields have a 30-byte limit, except for YEAR, which has a four-byte limit, and GENRE, which is one byte in the file. The GENRE passed in the function is a case-insensitive text string representing a genre found in @mp3_genres.

Will accept either a list of values, or a hashref of the type returned by get_mp3tag.
If TRACKNUM is present (for ID3v1.1), then the COMMENT field can only be 28 bytes.

ID3v2 support may come eventually. Note that if you set a tag on a file with ID3v2, the set tag will be for ID3v1[.1] only, and if you call get_mp3tag on the file, it will show you the (unchanged) ID3v2 tags, unless you specify ID3v1.

get_mp3tag (FILE [, VERSION, RAW_V2])

Returns hash reference containing tag information in MP3 file. The keys returned are the same as those supplied for set_mp3tag, except in the case of RAW_V2 being set.
If VERSION is 1, the information is taken from the ID3v1 tag (if present). If VERSION is 2, the information is taken from the ID3v2 tag (if present). If VERSION is not supplied, or is false, the ID3v1 tag is read if present, and then, if present, the ID3v2 tag information will override any existing ID3v1 tag info.

If RAW_V2 is 1, the raw ID3v2 tag data is returned, without any manipulation of text encoding. The key name is the same as the frame ID (ID to name mappings are in the global %v2_tag_names).

If RAW_V2 is 2, the ID3v2 tag data is returned, manipulating for Unicode if necessary, etc. It also takes multiple values for a given key (such as comments) and puts them in an arrayref.

If the ID3v2 version is older than ID3v2.2.0 or newer than ID3v2.4.0, it will not be read.

Strings returned will be in Latin-1, unless UTF-8 is specified (use_mp3_utf8), (unless RAW_V2 is 1).

Also returns a TAGVERSION key, containing the ID3 version used for the returned data (if TAGVERSION argument is 0, may contain two versions).
get_mp3info (FILE)

Returns hash reference containing file information for MP3 file. This data cannot be changed. Returned data:

VERSION MPEG audio version (1, 2, 2.5)
LAYER MPEG layer description (1, 2, 3)
STEREO boolean for audio is in stereo

VBR boolean for variable bitrate
BITRATE bitrate in kbps (average for VBR files)
FREQUENCY frequency in kHz
SIZE bytes in audio stream
OFFSET bytes offset that stream begins

SECS total seconds
MM minutes
SS leftover seconds
MS leftover milliseconds
TIME time in MM:SS

COPYRIGHT boolean for audio is copyrighted
PADDING boolean for MP3 frames are padded
MODE channel mode (0 = stereo, 1 = joint stereo,
2 = dual channel, 3 = single channel)
FRAMES approximate number of frames
FRAME_LENGTH approximate length of a frame
VBR_SCALE VBR scale from VBR header
On error, returns nothing and sets $@.

<<less
Download (0.097MB)
Added: 2006-06-23 License: GPL (GNU General Public License) Price:
1222 downloads
Kukkaisvoima 7

Kukkaisvoima 7


Kukkaisvoima is a lightweight weblog system licensed under GNU GPL version 2. more>>
Kukkaisvoima is a lightweight weblog system licensed under GNU GPL version 2. The project is made with Python programming language.
It stores all blog entries as plain text files so you can easily write and edit those with your favorite editor. Motivation for Kukkaisvoima was to do simple everything in one package weblog with Python.
Main features:
- Multiple categories for one entry
- No external dependencies outside Pythons standard library (no need for database engine etc.)
- Comments
- RSS feed for all entries and for every category
Install instructions:
After downloading the latest version of Kukkaisvoima. Move the package to your webdirectory and do the following steps:
tar xvfz kukkaisvoima-(versionnumber).tar.gz
cd kukkaisvoima-(versionnumber)
chmod +x index.cgi
mkdir temp
You may need to modify the index.cgi script suffix (change .cgi to .py) or use different permissions for the index.cgi script or for the temp directory. Temp directory should be writable by the script. For more information and help consult your webserver manual or local Python/Unix guru.
Configuring and using:
Edit the Config variables found in kukkaisvoima_settings.py. After configuring you can write blog entries as html formatted text files in directory specified in config file. Kukkaisvoima will generate the blog from these entries. Every entry must be in the format of
nameoftheantry:YYYY-MM-DD:category1,category2.txt
For example:
helloworld:2006-12-28:general.txt
As seen in the example entry can have multiple categories separeted with comma.
Enhancements:
- This release introduced a spam question to prevent spam comments and an admin interface for deleting comments.
<<less
Download (0.016MB)
Added: 2007-04-26 License: GPL (GNU General Public License) Price:
911 downloads
bkp 0.2

bkp 0.2


bkp is a command line backup tool intended for local storing written in bash under GPL license. more>>
bkp is a command line backup tool intended for local storing written in bash under GPL license. It allows you to make a solid backup of your data, keeping original files permissions.
bkp has a date (dd-mm-YY) support, so you will be able to know when you have made your backups. In this way you can upgrade them. It also support : gzip compression, background mode, md5 checking, events logging (and managing) and default directory.
This program can convert relative pathname of file or directory to its absolute pathname; in this way bkp can also rebuild original directory tree.
Usage : bkp.sh < files > | < directories > [[ option ]]
Enhancements:
- added --encrypt option : is now possible to encrypt backup using gpg.
- some functions have been reimplemented due to support --encrypt option.
- fixed --import option, now this option adds correctly backup to database and uses scp transfer method.
- added --export option : in now possible to export bakcup on a remote
- host using scp transfer method.
- added --verbose option.
- function help_option () now gives more details (users errors info).
- made some generic changes to program output.
- made some generic optimization.
- fixed some generic errors.
<<less
Download (0.015MB)
Added: 2007-02-28 License: GPL (GNU General Public License) Price:
972 downloads
IDS::Algorithm::MM 1.02

IDS::Algorithm::MM 1.02


IDS::Algorithm::MM is a Perl module created to learn or test using a first-order Markov Model (MM). more>>
IDS::Algorithm::MM is a Perl module created to learn or test using a first-order Markov Model (MM).

SYNOPSIS

A usage synopsis would go here. Since it is not here, read on.
In section 4.2 in Kruegel and Vignas paper, they ignored the probability information that the MM provided, and produced a binary result. In effect, they were using the constructed MM as a {N,D}FA.

Someday more will be here.

Ideally, we would be using the algorithm from stolcke94bestfirst. Constructing a DFA rather than a NFA in effect has performed most of the state merging that stolcke93hidden do.

Consider also a java or C/C++ implementaion: http://www.ghmm.org/ http://www.run.montefiore.ulg.ac.be/~francois/software/jahmm/

Useful information: http://www.cs.brown.edu/research/ai/dynamics/tutorial/Documents/HiddenMarkovModels.html http://www.comp.leeds.ac.uk/roger/HiddenMarkovModels/html_dev/main.html L R Rabiner and B H Juang, `An introduction to HMMs, IEEE ASSP Magazine, 3, 4-16.

printvcg

printvcg(filehandle)

Print in a form usable by VCG for printing the DFA.

If the filehandle is specified, print there; otherwise, print to STDOUT.
This code was stolen from DFA, and does not know about the probabilities.
load(filehandle)

Load a MM from a file; this is the inverse of "print", and the format we expect is that used in $self->print.

test(tokensref, string, instance)

Test the string of tokens and calculate the probability of the string being seen. At each stage, we get a p in [0,1]. The result is the product of these probabilities.
Note that if a transition cannot be made, we return a 0 probability.

add(tokensref, string, instance)

The collection of tokens (in the list referenced by tokensref) is a complete example of a list that should be accepted by the DFA.

string and instance are IDS::Test framework arguments that we ignore because we do not need them.

WE add the transition from the last token to the (ACCEPT) state.

add_transition(from, token)

Add a transition from one state to another when the specified token is received. It is not an error to try to add an existing transition. In that event, this function quietly returns. If no such transition exists, we look for a transition on the token; if so, we add an edge to the destination node for the existing edge. Finally, if there is no other choice, we create a new state and add the edge.

generalize()

Reduce the number of states in the model.

Our building a DFA rather than a NFA has in effect performed most of the state merging that would have occurred.

XXX We should still be doing some checks for additional merge possibilities.
XXX A proof that the DFA is effectively the NFA with merged states would be useful.

<<less
Download (0.032MB)
Added: 2007-06-18 License: Perl Artistic License Price:
858 downloads
Hugin 0.7 Beta 4

Hugin 0.7 Beta 4


Hugin is a toolkit for stitching photographs and assembling panoramas, together with an easy to use graphical front end. more>>
Hugin is a panorama tools GUI.

Goal: an easy to use cross-platform GUI for Panorama Tools.

With hugin you can assemble a mosiac of photographs into a complete immersive panorama, stitch any series of overlapping pictures and much more.

Main Window

This window consists of a toolbar that provides quick access to important functions. It also contains the Images, Lens, Control Point, Optimizer and Panorama Tab, which will be explained below.

Images Tab

Images can either be added with the Add button, or via drag and drop. To change the orientation of one or more images, select them in the list on the left. The image will be show in the preview area, and its orientation (yaw, pitch and roll values) can be edited on the left.

It is possible to select multiple images at the same time. Changes in orientation will be applied to all selected images

Lens Tab

The lens tab looks a lot like the Images tab, except that the lens settings can be edited here. As in the Images Tab, multiselection can be used to change the parameters for multiple images.

Currently only one lens is supported. The idea is that the Lens describes the process that was used to create the image. The most important parameters are the Lens type and the HFOV (Horizontal Field of View). Hugin will read the EXIF information in jpg files created by digital cameras, so usually it is filled out correctly.

Photographers do not use a HFOV in degrees, but the focal length. The focal length can be entered and it will be converted to HFOV in degrees, like the panorama tool require it. The focal length entered is taken to be for 35 mm film cameras.

Usually images are more or less distorted. This can be seen especially if there are long straight lines close to the image border, which are usually not completely straight but bent a little. The a b and c parameters are used to remove that distortion. They are applied radially from the image center, which can be moved by changing the d and e parameters.

During image capture, it is possible that the parameters vary, that is are not the same for each image. This can have many reasons, one of the could be a scanner that cuts a way a few pixel more at one side than the other. Other parameters stay the same, like usually the a,b and c parameters (if the zoom and focus for the images is the same).

The inherit checkmark means that this parameter doesnt vary between the images that were captures with that lens setting. If a parameter is inheritied it is forced to be the same for all images. When inherited parameters are optimized they are kept the same for all images, whereas parameters that are not inherited can get values specific for a single picture.

Control Point Tab

Control Points are probably the most important thing when using panorama tools. The Tab consists of two image displays and tab bars to switch images to be editied. The bottom contains a list view where Points can be selected and some fields to edit a selected point. Points can also be selected by clicking or dragging on them in the images. It is possible to zoom out to show the full image.

Adding a control point works by clicking into one image to select a point and then into the other image. If auto add is not set, the points can be moved by clicking at some other place in the images. They are added to the list of control points by pressing the right mouse button. If you press the right mouse button when only one point is slected, the point selection will be aborted. auto add adds the control point as soon as both points have been specified.

Control point creation is influenced by the following checkboxes:

auto fine tune hugin helps you to find the second point by looking for it in a search region (shown by a rectange around the cursor). This might not always work, but usually is reliable, if the image distortions are not too big. Try and play with it.
auto add A control point is automatically added when both points are know. You wont have time to refine the selection before adding the point.
auto estimate Tries to estimate the position of the second point by estimating the translation between the two images. This is very crude and probably only works for single row panoramas created from rectilinear images.

All these flags can be combined. I typically use auto fine tune and auto estimate at the same time. Then hugin usually automatically selects the second point correctly. Well for single row panos that is...

The images are zoomed out, the first click zooms to a temporary 100% view to give you the chance to refine your selection. Note that only the second click will trigger the auto estimate.

The Fine Tune button can be used to find a better position for the point in the right image for already selected point. Contrary to auto fine tune it only looks in a very small area around the point. This function is especially useful if you moved both points by hand, but want to have fine tuned control points.

Press the middle mouse button to pan the image. If you press shift key while paning, both images will move.

This window supports some keyboard shortcuts:

a add a new point that has been selected in both images, and the auto add is switched off.
cursor keys scroll image under the mouse cursor
shift + cursor keys scroll both images at the same time
f fine tune currently selected control point pair. Same as the Fine Tune button
Del Remove currently selected control point.
0 Zoom out to full view.
1 100% view.
Mouse function
Function
control key + mouse movement Scroll image under cursor
shift key + mouse movement Scroll both images
left button Use left mouse button to select new points or drag existing points.
right mouse button Add control point, if auto add is switched off
middle mouse button Scroll image under cursor
shift + middle mouse button Scroll both images

Optimizer Tab

The optimizer moves the images into the right position, so that they can be assembled into a hopefully seamless panorama.

To select what the optimiser should try to estimate, use the Optimize combo box, then click the Optimize Button. If you select the "custom" setting, you can change

Pano Panel

Options concerning the output panorama can be set here.

<<less
Download (2.2MB)
Added: 2007-02-05 License: GPL (GNU General Public License) Price:
1008 downloads
File::MMagic 1.27

File::MMagic 1.27


File::MMagic is a Perl module to guess file type. more>>
File::MMagic is a Perl module to guess file type.

SYNOPSIS

use File::MMagic;
use FileHandle;

$mm = new File::MMagic; # use internal magic file
# $mm = File::MMagic->new(/etc/magic); # use external magic file
# $mm = File::MMagic->new(/usr/share/etc/magic); # if you use Debian
$res = $mm->checktype_filename("/somewhere/unknown/file");

$fh = new FileHandle "< /somewhere/unknown/file2";
$res = $mm->checktype_filehandle($fh);

$fh->read($data, 0x8564);
$res = $mm->checktype_contents($data);

<<less
Download (0.021MB)
Added: 2007-01-11 License: Perl Artistic License Price:
1017 downloads
Math::NumberCruncher 5.00

Math::NumberCruncher 5.00


Math::NumberCruncher Perl module contains a collection of useful math-related functions. more>>
Math::NumberCruncher Perl module contains a collection of useful math-related functions.

SYNOPSIS

It should be noted that as of v4.0, there is now an OO interface to Math::NumberCruncher. For backwards compatibility, however, the previous, functional style will always be supported.

# OO Style

use Math::NumberCruncher;

$ref = Math::NumberCruncher->new();

# From this point on, all of the subroutines shown below will be available # through $ref (i.e., ( $high,$low ) = $ref->Range( @array )). For the sake # of brevity, consult the functional documentation (below) for the use # of specific functions.

# Functional Style

use Math::NumberCruncher;

($high, $low) = Math::NumberCruncher::Range(@array);
$mean = Math::NumberCruncher::Mean(@array);
$median = Math::NumberCruncher::Median(@array [, $decimal_places]);
$odd_median = Math::NumberCruncher::OddMedian(@array);
$mode = Math::NumberCruncher::Mode(@array);
$covariance = Math::NumberCruncher::Covariance(@array1, @array2);
$correlation = Math::NumberCruncher::Correlation(@array1, @array2);
($slope, $y_intercept) = Math::NumberCruncher::BestFit(@array1, @array2 [, $decimal_places]);
$distance = Math::NumberCruncher::Distance($x1,$y1,$z1,$x2,$y2,$z2 [, $decimal_places]);
$distance = Math::NumberCruncher::Distance($x1,$y1,$x1,$x2 [, $decimal_places]);
$distance = Math::NumberCruncher::ManhattanDistance($x1,$y1,$x2,$y2);
$probAll = Math::NumberCruncher::AllOf(0.3,0.25,0.91,0.002);
$probNone = Math::NumberCruncher::NoneOf(0.4,0.5772,0.212);
$probSome = Math::NumberCruncher::SomeOf(0.11,0.56,0.3275);
$factorial = Math::NumberCruncher::Factorial($some_number);
$permutations = Math::NumberCruncher::Permutation($n);
$permutations = Math::NumberCruncher::Permutation($n,$k);
$roll = Math::NumberCruncher::Dice(3,12,4);
$randInt = Math::NumberCruncher::RandInt(10,50);
$randomElement = Math::NumberCruncher::RandomElement(@array);
Math::NumberCruncher::ShuffleArray(@array);
@unique = Math::NumberCruncher::Unique(@array);
@a_only = Math::NumberCruncher::Compare(@a,@b);
@union = Math::NumberCruncher::Union(@a,@b);
@intersection = Math::NumberCruncher::Intersection(@a,@b);
@difference = Math::NumberCruncher::Difference(@a,@b);
$gaussianRand = Math::NumberCruncher::GaussianRand();
$ways = Math::NumberCruncher::Choose($n,$k);
$binomial = Math::NumberCruncher::Binomial($attempts,$successes,$probability);
$gaussianDist = Math::NumberCruncher::GaussianDist($x,$mean,$variance);
$StdDev = Math::NumberCruncher::StandardDeviation(@array [, $decimal_places]);
$variance = Math::NumberCruncher::Variance(@array [, $decimal_places]);
@scores = Math::NumberCruncher::StandardScores(@array [, $decimal_places]);
$confidence = Math::NumberCruncher::SignSignificance($trials,$hits,$probability);
$e = Math::Numbercruncher::EMC2( "m512", "miles" [, $decimal_places] );
$m = Math::NumberCruncher::EMC2( "e987432" "km" [, $decimal_places] );
$force = Math::NumberCruncher::FMA( "m12", "a73.5" [, $decimal_places] );
$mass = Math::NumberCruncher::FMA( "a43", "f1324" [, $decimal_places] );
$acceleration = Math::NumberCruncher::FMA( "f53512", "m356" [, $decimal_places] );
$predicted_value = Math::NubmerCruncher::Predict( $slope, $y_intercept, $proposed_x [, $decimal_places] );
$area = Math::NumberCruncher::TriangleHeron( $a, $b, $c [, $decimal_places] );
$area = Math::NumberCruncher::TriangleHeron( 1,3, 5,7, 8,2 [, $decimal_places] );
$perimeter = Math::NumberCruncher::PolygonPerimeter( $x0,$y0, $x1,$y1, $x2,$y2, ... [, p$decimal_places]);
$direction = Math::NumberCruncher::Clockwise( $x0,$y0, $x1,$y1, $x2,$y2 );
$collision = Math::NumberCruncher::InPolygon( $x, $y, @xy );
@points = Math::NumberCruncher::BoundingBox_Points( $d, @p );
$in_triangle = Math::NumberCruncher::InTriangle( $x,$y, $x0,$y0, $x1,$y1, $x2,$y2 );
$area = Math::NumberCruncher::PolygonArea( 0, 1, 1, 0, 2, 0, 3, 2, 2, 3 [, p$decimal_places] );
$area = Math::NumberCruncher::CircleArea( $diameter [, $decimal_places] );
$circumference = Math::NumberCruncher::Circumference( $diameter [, $decimal_places] );
$volume = Math::NumberCruncher::SphereVolume( $radius [, $decimal_places] );
$surface_area = Math::NumberCruncher::SphereSurface( $radius [, $decimal_places] );
$years = Math::NumberCruncher::RuleOf72( $interest_rate [, $decimal_places] );
$volume = Math::NumberCruncher::CylinderVolume( $radius, $height [, $decimal_places] );
$volume = Math::NumberCruncher::ConeVolume( $lowerBaseArea, $height [, $decimal_places] );
$radians = Math::NumberCruncher::deg2rad( $degrees [, $decimal_places] );
$degrees = Math::NumberCruncher::rad2deg( $radians [, $decimal_places] );
$Fahrenheit = Math::NumberCruncher::C2F( $Celsius [, $decimal_places] );
$Celsius = Math::NumberCruncher::F2C( $Fahrenheit [, $decimal_places] );
$cm = Math::NumberCruncher::in2cm( $inches [, $decimal_places] );
$inches = Math::NumberCruncher::cm2in( $cm [, $decimal_places] );
$ft = Math::NumberCruncher::m2ft( $m [, $decimal_places] );
$m = Math::NumberCruncher::ft2m( $ft [, $decimal_places] );
$miles = Math::NumberCruncher::km2miles( $km [, $decimal_places] );
$km = Math::NumberCruncher::miles2km( $miles [, $decimal_places] );
$lb = Math::NumberCruncher::kg2lb( $kg [, $decimal_places] );
$kg = Math::NumberCruncher::lb2kg( $lb [, $decimal_places] );
$RelativeStride = Math::NumberCruncher::RelativeStride( $stride_length, $leg_length [, $decimal_places] );
$RelativeStride = Math::NumberCruncher::RelativeStride_2( $DimensionlessSpeed [, $decimal_places] );
$DimensionlessSpeed = Math::NumberCruncher::DimensionlessSpeed( $RelativeStride [, $decimal_places] );
$DimensionlessSpeed = Math::NumberCruncher::DimensionlessSpeed_2( $ActualSpeed, $leg_length [, $decimal_places]);
$ActualSpeed = Math::NumberCruncher::ActualSpeed( $leg_length, $DimensionlessSpeed [, $decimal_places] );
$eccentricity = Math::NumberCruncher::Eccentricity( $half_major_axis, $half_minor_axis [, $decimal_places] );
$LatusRectum = Math::NumberCruncher::LatusRectum( $half_major_axis, $half_minor_axis [, $decimal_places] );
$EllipseArea = Math::NumberCruncher::EllipseArea( $half_major_axis, $half_minor_axis [, $decimal_places] );
$OrbitalVelocity = Math::NumberCruncher::OrbitalVelocity( $r, $a, $M [, $decimal_places] );
$sine = Math::NumberCruncher::sin( $x [, $decimal_places] );
$cosine = Math::NumberCruncher::cos( $x [, $decimal_places] );
$tangent = Math::NumberCruncher::tan( $x [, $decimal_places] );
$arcsin = Math::NumberCruncher::asin( $x [, $decimal_places] );
$arccos = Math::NumberCruncher::acos( $x [, $decimal_places] );
$arctan = Math::NumberCruncher::atan( $x [, $decimal_places] );
$cotangent = Math::NumberCruncher::cot( $x [, $decimal_places] );
$arccot = Math::NumberCruncher::acot( $x [, $decimal_places] );
$secant = Math::NumberCruncher::sec( $x [, $decimal_places] );
$arcsec = Math::NumberCruncher::asec( $x [, $decimal_places] );
$cosecant = Math::NumberCruncher::csc( $x [, $decimal_places] );
$arccosecant = Math::NumberCruncher::acsc( $x [, $decimal_places] );
$exsecant = Math::NumberCruncher::exsec( $x [, $decimal_places] );
$versine = Math::NumberCruncher::vers( $x [, $decimal_places] );
$coversine = Math::NumberCruncher::covers( $x [, $decimal_places] );
$haversine = Math::NumberCruncher::hav( $x [, $decimal_places] );
$grouped = Math::NumberCruncher::Commas( $number );
$SqrRoot = Math::NumberCruncher::SqrRoot( $number [, $decimal_places] );
$square_root = Math::NumberCruncher::sqrt( $x [, $decimal_places] );
$root = Math::NumberCruncher::Root( 55, 3 [, $decimal_places] );
$root = Math::NumberCruncher::Root2( 55, 3 [, $decimal_places] );
$log = Math::NumberCruncher::Ln( 100 [, $decimal_places] );
$log = Math::NumberCruncher::log( $num [, $decimal_places] );
$num = Math::NumberCruncher::Exp( 0.111 [, $decimal_places] );
$num = Math::NumberCruncher::exp( $log [, $decimal_places] );
$Pi = Math::NumberCruncher::PICONST( $decimal_places );
$E = Math::NumberCruncher::ECONST( $decimal_places );
( $A, $B, $C ) = Math::NumberCruncher::PythagTriples( $x, $y [, $decimal_places] );
$z = Math::NumberCruncher::PythagTriplesSeq( $x, $y [, $decimal_places] );
@nums = Math::NumberCruncher::SIS( [$start, $numbers, $increment] );
$inverse = Math::NumberCruncher::Inverse( $number [, $decimal_places] );
@constants = Math::NumberCruncher::CONSTANTS( all [, $decimal_places] );
$bernoulli = Math::NumberCruncher::Bernoulli( $num [, $decimal_places] );
@bernoulli = Math::NumberCruncher::Bernoulli( $num );

<<less
Download (0.080MB)
Added: 2007-07-05 License: Perl Artistic License Price:
842 downloads
Secleted [ 0 ] software to compare
  • Page: 1 of 5
  • 1
  • 2
  • 3
  • 4
  • 5