__header__

Description

The Score Param Collection tool finds the file with the highest score in a set of files.

Understanding "Scores" and "Weights"

Suppose several measurements are done on a part. Based on the result characteristics that part will be compared to a set of master part files to determine what the part is.  When comparing the result characteristics to the characteristics in the master files it is possible to "weight" the characteristics based on which are more important.  The weight is the level of importance that characteristic will have when determining similarity.  The "score" is the overall level of similarity between the characteristics of the measured part and the characteristics in master file they are compared to.

For example: A part is measured for three characteristics, A, B, and C.  A is given a weight of 2, B is given a weight of 3 and C is given a weight of 5.  In this case C will amount for 50% of the final score, B for 30% and A for 20%.  The score is also given in terms of a percentage, so a perfect match will yield a score of 1.

Using the Score Param Collection Tool

On the Score Param Collection Tool's inputs page there are three inputs that need to be defined.  

The FileCollection is any set of files.  These characteristics in these files will be compared to the result characteristics.

Results is the set of result characteristics.  To add the results to this section of the inputs page it is necessary to use the Results to Parameters tool.

Tolerances refers to a set of parameters that the user will define.  If a characteristic in a file in the collection does not meet the defined tolerance then that file will not be scored.

When the tool is run it shows what it has found on its parameters page.

ScoreField is not yet functional.

NumberFilesFound is the number of files that fell within the tolerances.

FoundCollection is the complete collection of files that fell within the tolerances.  This collection can be used as an input for other tools.

BestScore is the highest score found for all the files in the collection.

BestMatch is the file with the highest score.  This file can be used as an input for other tools.

Defining the Tolerances

A tolerance set can be created by dragging the Parameters Creatable tool onto the ROT to create a new set of global parameters. Once the new parameter collection has been added to the ROT parameters (tolerances) can be defined.  For the tolerances to work they must have the exact name of the characteristic they are related to.

If the all the result characteristics are within the tolerance range for a file in the file collection then that file will be considered for scoring.

Once the tolerances are defined the parameter collection that holds the tolerances will need to be added to the Tolerances section of the Score Param Collection tool's inputs page.

Note: Only the characteristics that have weights will be compared to the tolerances.

Defining the Weights

The weight for each characteristic is defined in the files in the file collection by adding a new characteristic with the same name and a suffix.  The suffix is define on the Score Param Collection tool's parameters page in the WeightSuffix box.

For example:  Suppose the WeightSuffix is defined as _weight.  We have measured characteristics "length" and "width".  The length should be given twice the weight as the width.  In the master files we will have predefined "length" and "width" characteristics.  To add weights to each characteristic we will add a "length_weight" characteristic and give it a value of 2 and a "width_weight" and give it a value of 1.

Since each file holds its own set of weights every master file can have a unique set of weights.  Only the characteristics that have a weight value will be considered when applying the tolerances and when scoring.

Inputs

FileCollection

Parameters

Weights

Parameters

DistanceMeasure

NumberFilesFound

FoundCollection

BestScore

BestMatch

__footer__