Back to Aurora Vision Library website

You are here: Start » Function Reference » Profile » Profile Point Transforms » NormalizeProfile

NormalizeProfile


Header: AVL.h
Namespace: avl
Module: FoundationPro

Rescales a profile linearly, so that its minimum becomes inNewMinimum and its maximum becomes inNewMaximum.

Syntax

C++
C#
 
void avl::NormalizeProfile
(
	const avl::Profile& inProfile,
	atl::Optional<const avl::Range&> inRange,
	atl::Optional<float> inNewMinimum,
	atl::Optional<float> inNewMaximum,
	const float inSaturateHighestFraction,
	const float inSaturateLowestFraction,
	avl::Profile& outProfile,
	float& outA,
	float& outB
)

Parameters

Name Type Range Default Description
Input value inProfile const Profile& Input profile
Input value inRange Optional<const Range&> NIL
Input value inNewMinimum Optional<float> NIL Desired minimum value of the resulting profile (if set to Nil, the minimum of the input profile is used)
Input value inNewMaximum Optional<float> NIL Desired maximum value of the resulting profile (if set to Nil, the maximum of the input profile is used)
Input value inSaturateHighestFraction const float 0.0 - 1.0 0.0f Fraction of the highest values skipped during normalization
Input value inSaturateLowestFraction const float 0.0 - 1.0 0.0f Fraction of the lowest values skipped during normalization
Output value outProfile Profile& Normalized profile
Output value outA float& Multiplicative parameter of the applied linear transformation
Output value outB float& Additive parameter of the applied linear transformation

Errors

List of possible exceptions:

Error type Description
DomainError Range exceeds inProfile in NormalizeProfile.
DomainError The sum of inSaturateHighestFraction and inSaturateLowestFraction can't be greater than 1 in NormalizeProfile.