iCub-main
Loading...
Searching...
No Matches
Public Member Functions | List of all members
iCub::learningmachine::NullScaler Class Reference

The NullScaler is a scaler that does nothing, the output of the transform function is equal to its input. More...

#include <IScaler.h>

+ Inheritance diagram for iCub::learningmachine::NullScaler:

Public Member Functions

 NullScaler ()
 Constructor.
 
virtual double transform (double val)
 Transforms a single sample value according to the state of the scaler.
 
virtual double unTransform (double val)
 Untransforms a single sample value according to the state of the scaler.
 
virtual NullScalerclone ()
 Asks the scaler to return a new object of its type.
 
- Public Member Functions inherited from iCub::learningmachine::IScaler
 IScaler (double s=1., double o=0.)
 Constructor.
 
virtual ~IScaler ()
 Destructor (empty).
 
virtual void update (double val)
 Feeds a single sample into the scaler, so that it can use this sample to update the offset and scale.
 
virtual std::string getInfo ()
 Asks the learning machine to return a string containing statistics on its operation so far.
 
std::string getName () const
 Retrieve the name of this scaler.
 
void setName (std::string name)
 Set the name of this machine learning technique.
 
virtual void setUpdateEnabled (bool u)
 Mutator for the update state.
 
virtual bool getUpdateEnabled ()
 Accessor for the update state.
 
virtual std::string toString ()
 Asks the scaler to return a string serialization.
 
virtual bool fromString (const std::string &str)
 Asks the scaler to initialize from a string serialization.
 
virtual bool configure (yarp::os::Searchable &config)
 

Additional Inherited Members

- Protected Member Functions inherited from iCub::learningmachine::IScaler
virtual void writeBottle (yarp::os::Bottle &bot)
 Writes a serialization of the scaler into a bottle.
 
virtual void readBottle (yarp::os::Bottle &bot)
 Unserializes a scaler from a bottle.
 
- Protected Attributes inherited from iCub::learningmachine::IScaler
double offset
 The offset for the linear transformation.
 
double scale
 The scale for the linear transformation.
 
std::string name
 The name of this type of scaler.
 
bool updateEnabled
 Boolean indicating whether the scaler has to update each sample.
 

Detailed Description

The NullScaler is a scaler that does nothing, the output of the transform function is equal to its input.

The use is so that the ScaleTransformer can 'disable' transformation on certain inputs.

See also
iCub::learningmachine:IScaler
iCub::learningmachine:ScaleTransformer
Author
Arjan Gijsberts

Definition at line 197 of file IScaler.h.

Constructor & Destructor Documentation

◆ NullScaler()

iCub::learningmachine::NullScaler::NullScaler ( )
inline

Constructor.

Definition at line 203 of file IScaler.h.

Member Function Documentation

◆ clone()

virtual NullScaler * iCub::learningmachine::NullScaler::clone ( )
inlinevirtual

Asks the scaler to return a new object of its type.

Returns
a fresh instance of the specified type

Implements iCub::learningmachine::IScaler.

Definition at line 224 of file IScaler.h.

◆ transform()

virtual double iCub::learningmachine::NullScaler::transform ( double  val)
inlinevirtual

Transforms a single sample value according to the state of the scaler.

This state is usually made up out of a desired offset and scale.

Parameters
valthe sample
Returns
the resulting, transformed sample

Reimplemented from iCub::learningmachine::IScaler.

Definition at line 210 of file IScaler.h.

◆ unTransform()

virtual double iCub::learningmachine::NullScaler::unTransform ( double  val)
inlinevirtual

Untransforms a single sample value according to the state of the scaler.

This operation is the inverse of the transform operation.

Parameters
valthe sample
Returns
the resulting, transformed sample

Reimplemented from iCub::learningmachine::IScaler.

Definition at line 217 of file IScaler.h.


The documentation for this class was generated from the following file: