Data Preparation

Configure feature bounds before incremental training. Normalization and complement coding requirements depend on the model; see the model guide.

Index

Configuration

DataConfig

AdaptiveResonance.DataConfig — Type
mutable struct DataConfig

Summary

Container to standardize training/testing data configuration.

This container declares if a data configuration has been setup, what the original and complement coded dimensions are, and what the minimums and maximums of the values along each feature dimension are.

Fields

  • setup::Bool: Flag if data has been setup yet or not.
  • mins::Vector{Float64}: List of minimum values for each feature.
  • maxs::Vector{Float64}: List of maximum values for each feature.
  • dim::Int64: Dimensionality of the feature vectors (i.e., number of features).
  • dim_comp::Int64: Complement coded feature dimensionality, twice the size of dim.
source

data_setup!

AdaptiveResonance.data_setup! — Function
data_setup!(
    config::DataConfig,
    data::AbstractMatrix{T} where T<:Real
)

Summary

Sets up the data config for the ART module before training.

This function crucially gets the original and complement-coded dimensions of the data, and it infers the bounds of the data (minimums and maximums) by the largest and smallest values along each feature dimension.

Arguments

  • config::DataConfig: the ART/ARTMAP module's data configuration object.
  • data::RealMatrix: the 2-D batch of data to use for creating the data configuration.

Method List / Definition Locations

data_setup!(config, data)

defined at /home/runner/work/AdaptiveResonance.jl/AdaptiveResonance.jl/src/lib/common.jl:268.

source
data_setup!(
    art::ARTModule,
    data::AbstractMatrix{T} where T<:Real
)

Summary

Convenience method for setting up the DataConfig of an ART module in advance.

Arguments

  • art::ARTModule: the ART/ARTMAP module to manually configure the data config for.
  • data::RealArray: the 2-D batch of data used to create the data config.

Method List / Definition Locations

data_setup!(art, data)

defined at /home/runner/work/AdaptiveResonance.jl/AdaptiveResonance.jl/src/lib/common.jl:295.

source

get_data_characteristics

AdaptiveResonance.get_data_characteristics — Function
get_data_characteristics(
    data::AbstractMatrix{T} where T<:Real;
    config
) -> NTuple{4, Any}

Summary

Get the characteristics of the data, taking account if a data config is passed.

If no DataConfig is passed, then the data characteristics come from the array itself. Otherwise, use the config for the statistics of the data and the data array for the number of samples.

Arguments

  • data::RealMatrix: the 2-D data to be complement coded.
  • config::DataConfig=DataConfig(): the data configuration for the ART/ARTMAP module.

Method List / Definition Locations

get_data_characteristics(data; config)

defined at /home/runner/work/AdaptiveResonance.jl/AdaptiveResonance.jl/src/lib/common.jl:310.

source

Transformations

linear_normalization

AdaptiveResonance.linear_normalization — Function
linear_normalization(
    data::AbstractVector{T} where T<:Real;
    config
) -> Vector{Float64}

Summary

Normalize the data to the range [0, 1] along each feature.

Arguments

  • data::RealVector: the 1-D sample of data to normalize.
  • config::DataConfig=DataConfig(): the data configuration from the ART/ARTMAP module.

Method List / Definition Locations

linear_normalization(data; config)

defined at /home/runner/work/AdaptiveResonance.jl/AdaptiveResonance.jl/src/lib/common.jl:339.

source
linear_normalization(
    data::AbstractMatrix{T} where T<:Real;
    config
) -> Any

Summary

Normalize the data to the range [0, 1] along each feature.

Arguments

  • data::RealMatrix: the 2-D batch of data to normalize.
  • config::DataConfig=DataConfig(): the data configuration from the ART/ARTMAP module.

Method List / Definition Locations

linear_normalization(data; config)

defined at /home/runner/work/AdaptiveResonance.jl/AdaptiveResonance.jl/src/lib/common.jl:369.

source

complement_code

AdaptiveResonance.complement_code — Function
complement_code(
    data::AbstractArray{T} where T<:Real;
    config
) -> Any

Summary

Normalizes the data x to [0, 1] and returns the augmented vector [x, 1 - x].

Arguments

  • data::RealArray: the 1-D or 2-D data to be complement coded.
  • config::DataConfig=DataConfig(): the data configuration for the ART/ARTMAP module.

Method List / Definition Locations

complement_code(data; config)

defined at /home/runner/work/AdaptiveResonance.jl/AdaptiveResonance.jl/src/lib/common.jl:402.

source