Skip to content

← feature_extraction package

RBFKernelApprox

Approximate an RBF kernel mapping on the given data.

This method will apply a non-linear transformation to the given data which is a reduced-rank approximation of the RBF (Radial Basis Function) kernel known from e.g., Support Vector Machines. The RBF kernel mapping allows linear downstream methods such as logistic regression or discriminant analysis to effectively operate on a non-linear representation of the data, which allows it to learn non-linear decision boundaries, similar to kernel SVM, while retaining the other advantages of the method (e.g., probabilistic outputs etc). The approximate nature of the method means that the accuracy may not exactly match that of the full RBF kernel, but the approach can be much faster, especially in the presence of many training samples (e.g., thousands or tens of thousands). Like most other feature extraction nodes, this node can compute features between elements of an axis of your choice while treating elements of another axis as the observations, trials, or samples. It can also optionally compute multiple separate models on different slices of the data along some axis of choice. It is also possible to pool multiple axes for any of these roles. More Info... Version 0.8.0

Ports/Properties

domain_axes

Axes which form the input domain of the transformation. Features are computed between elements along these axes (or in other words, elements along these axes will be combined with each other to yield features). This is a comma-separated list of axis names (for example: "space, frequency"), possibly empty, or the special string "(all others)", which stands for all axes that are not listed in the other two lists of axes. For time-series data, this is usually the space axis, and if features have already been extracted from the data through some other method, it would be the features axis. In rare cases it can also include other axes, such as frequency, lag, and time. This axis drops out of the data and is replaced by a feature axis that has a number of elements that corresponds to the output feature dimension of the model.

  • verbose name: Compute Features Between Axes
  • default value: (all others)
  • port type: ComboPort
  • value type: str (can be None)

aggregate_axes

Axes that have the statistical observations in them. The elements along these axes are treated as the "trials", "samples", or, equivalently, "observations". Adaptive feature extractors will aggregate statistics along the elements of these axes during training. When the transformer applies to data, this axis remains in the data (if multiple, they will be flattened into one axis, however). This is a comma-separated list of axis names (for example: "time, instance"), possibly empty, or the special string "(all others)", which stands for all axes that are not listed in the other two lists of axes. This is almost always the instance axis (especially if the data has already been segmented, i.e., if the Segmentation node was used), but in some cases it may also be the time axis, or occasionally other axes.

  • verbose name: Treat Elements As Trials/samples Along Axes
  • default value: instance
  • port type: ComboPort
  • value type: str (can be None)

separate_axes

Axes along which to learn separate models. It is possible to use multiple separate feature-extraction models, each of which operates on a different slice of the data. This node does not combine data between elements along these axes in any way (although features between these elements may of course be combined in later stages, for instance in a classifier node). This is a comma-separated list of axis names (for example: "time, frequency"), possibly empty, or the special string "(all others)", which stands for all axes that are not listed in the other two lists of axes. This axis, if any, will also persist in the data.

  • verbose name: Compute Separate Models Along Axes
  • default value:
  • port type: ComboPort
  • value type: str (can be None)

data

Data to process.

  • verbose name: Data
  • default value: None
  • port type: DataPort
  • value type: Packet (can be None)
  • data direction: INOUT

variant

Variant of the kernel approximation to use. The choice between nystroem and fourier may be determined empirically on a case-by-case basis, but see also the citation in the node documentation for some relative tradeoffs. The group-centroids variant instead relies on trials coming in groups, and computes the kernel with respect to the (class-conditional) feature centroids of those groups.

  • verbose name: Variant
  • default value: fourier
  • port type: EnumPort
  • value type: str (can be None)

gamma

Length scale. This is the scale of the kernel, which depends on the scale of non-linear features in the data space. Larger values will result in smoother kernel maps. When using the fourier method, this can also be left empty, in which case it will be set to 1 / (n_features * var(X)).

  • verbose name: Length Scale (Gamma)
  • default value: None
  • port type: FloatPort
  • value type: float (can be None)

dimensionality

Number of output dimensions (features) to generate. Larger numbers will yield more accurate results, but at the cost of increased computation time and memory usage both for the kernel approximation itself and the downstream ML stages. Ignored when using the group-centroids variant.

  • verbose name: Output Dimensionality
  • default value: 100
  • port type: IntPort
  • value type: int (can be None)

group_field

Optionally a field indicating the group from which each trial is sourced. Only used with the group-centroids variant.

  • verbose name: Group Field
  • default value:
  • port type: StringPort
  • value type: str (can be None)

cond_field

The name of the instance data field that contains the conditions (classes) to be discriminated. Only used with the group-centroids variant.

  • verbose name: Condition Field
  • default value: TargetValue
  • port type: StringPort
  • value type: str (can be None)

random_seed

Random seed. Different values will yield different results.

  • verbose name: Random Seed
  • default value: 12345
  • port type: IntPort
  • value type: int (can be None)

set_breakpoint

Set a breakpoint on this node. If this is enabled, your debugger (if one is attached) will trigger a breakpoint.

  • verbose name: Set Breakpoint (Debug Only)
  • default value: False
  • port type: BoolPort
  • value type: bool (can be None)

metadata

User-definable meta-data associated with the node. Usually reserved for technical purposes.

  • verbose name: Metadata
  • default value: {}
  • port type: DictPort
  • value type: dict (can be None)