org.apache.ignite.ml.dataset.feature.extractor

## Class Vectorizer.VectorizerAdapter<K,V,C extends Serializable,L>

- java.lang.Object
- - org.apache.ignite.ml.dataset.feature.extractor.Vectorizer<K,V,C,L>
  - - org.apache.ignite.ml.dataset.feature.extractor.Vectorizer.VectorizerAdapter<K,V,C,L>

- Type Parameters:
    `K` - Type of key.
    `V` - Type of value.
    `C` - Type of coordinate.
    `L` - Type od label.
  All Implemented Interfaces:
    Serializable, BiFunction<K,V,LabeledVector>, IgniteBiFunction<K,V,LabeledVector>, Preprocessor<K,V>, FeatureLabelExtractor<K,V,L>
  Enclosing class:
    Vectorizer<K,V,C extends Serializable,L>

      public abstract static class Vectorizer.VectorizerAdapter<K,V,C extends Serializable,L>
      extends Vectorizer<K,V,C,L>

  Utility class for convenient overridings.
  See Also:
    Serialized Form

- - ### Nested Class Summary

    - ### Nested classes/interfaces inherited from class org.apache.ignite.ml.dataset.feature.extractor.Vectorizer

      `Vectorizer.LabelCoordinate, Vectorizer.VectorizerAdapter<K,V,C extends Serializable,L>`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `VectorizerAdapter()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `protected List<C>` | `allCoords(K key, V value)` Returns list of all coordinate with feature values.
    `protected Double` | `feature(C coord, K key, V value)` Extracts feature value by given coordinate.
    `protected L` | `label(C coord, K key, V value)` Extract label value by given coordinate.
    `protected L` | `zero()` Returns default label value for unlabeled data.

    - ### Methods inherited from class org.apache.ignite.ml.dataset.feature.extractor.Vectorizer

      `apply, createVector, exclude, extract, labeled, labeled`

    - ### Methods inherited from class java.lang.Object

      `clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait`

    - ### Methods inherited from interface org.apache.ignite.ml.trainers.FeatureLabelExtractor

      `extractFeatures, extractLabel`

    - ### Methods inherited from interface org.apache.ignite.ml.preprocessing.Preprocessor

      `map`

    - ### Methods inherited from interface org.apache.ignite.ml.math.functions.IgniteBiFunction

      `andThen`

    - ### Methods inherited from interface java.util.function.BiFunction

      `andThen`

- - ### Constructor Detail

    - #### VectorizerAdapter

          public VectorizerAdapter()

  - ### Method Detail

    - #### feature

          protected Double feature(C coord,
                                   K key,
                                   V value)

      Extracts feature value by given coordinate.
      Specified by:
        `feature` in class `Vectorizer<K,V,C extends Serializable,L>`
      Parameters:
        `coord` - Coordinate.
        `key` - Key.
        `value` - Value.
      Returns:
        feature value.

    - #### label

          protected L label(C coord,
                            K key,
                            V value)

      Extract label value by given coordinate.
      Specified by:
        `label` in class `Vectorizer<K,V,C extends Serializable,L>`
      Parameters:
        `coord` - Coordinate.
        `key` - Key.
        `value` - Value.
      Returns:
        label value.

    - #### zero

          protected L zero()

      Returns default label value for unlabeled data.
      Specified by:
        `zero` in class `Vectorizer<K,V,C extends Serializable,L>`
      Returns:
        label value.

    - #### allCoords

          protected List<C> allCoords(K key,
                                      V value)

      Returns list of all coordinate with feature values.
      Specified by:
        `allCoords` in class `Vectorizer<K,V,C extends Serializable,L>`
      Parameters:
        `key` - Key.
        `value` - Value.
      Returns:
        all coordinates list.

2021 Copyright © Apache Software Foundation
| Follow @ApacheIgnite
Ignite Database and Caching Platform | : ver. 2.11.0
Release Date | : September 11 2021