io.siddhi.extension.execution.streamingml.classification.perceptron

## Class PerceptronClassifierUpdaterStreamProcessorExtension

- java.lang.Object
- - io.siddhi.core.query.processor.stream.AbstractStreamProcessor<S>
  - - io.siddhi.core.query.processor.stream.StreamProcessor<io.siddhi.extension.execution.streamingml.classification.perceptron.PerceptronClassifierUpdaterStreamProcessorExtension.ExtensionState>
    - - io.siddhi.extension.execution.streamingml.classification.perceptron.PerceptronClassifierUpdaterStreamProcessorExtension

- All Implemented Interfaces:
    io.siddhi.core.query.processor.Processor, io.siddhi.core.util.extension.holder.ExternalReferencedHolder

      public class PerceptronClassifierUpdaterStreamProcessorExtension
      extends io.siddhi.core.query.processor.stream.StreamProcessor<io.siddhi.extension.execution.streamingml.classification.perceptron.PerceptronClassifierUpdaterStreamProcessorExtension.ExtensionState>

  Build or update a linear binary classification Perceptron model and emit the weights of the features in the order of the attributes.

- - ### Field Summary

    - ### Fields inherited from class io.siddhi.core.query.processor.stream.AbstractStreamProcessor

      `attributeExpressionExecutors, attributeExpressionLength, complexEventPopulater, inputDefinition, metaStreamEvent, nextProcessor, siddhiQueryContext, stateHolder, streamEventClonerHolder`

  - ### Constructor Summary

    Constructors
    Constructor and Description
    `PerceptronClassifierUpdaterStreamProcessorExtension()`

  - ### Method Summary

    All Methods Instance Methods Concrete Methods
    Modifier and Type | Method and Description
    --- | ---
    `io.siddhi.core.query.processor.ProcessingMode` | `getProcessingMode()`
    `List<io.siddhi.query.api.definition.Attribute>` | `getReturnAttributes()`
    `protected io.siddhi.core.util.snapshot.state.StateFactory<io.siddhi.extension.execution.streamingml.classification.perceptron.PerceptronClassifierUpdaterStreamProcessorExtension.ExtensionState>` | `init(io.siddhi.core.event.stream.MetaStreamEvent metaStreamEvent, io.siddhi.query.api.definition.AbstractDefinition abstractDefinition, io.siddhi.core.executor.ExpressionExecutor[] expressionExecutors, io.siddhi.core.util.config.ConfigReader configReader, io.siddhi.core.event.stream.holder.StreamEventClonerHolder streamEventClonerHolder, boolean b, boolean b1, io.siddhi.core.config.SiddhiQueryContext siddhiQueryContext)`
    `protected void` | `process(io.siddhi.core.event.ComplexEventChunk<io.siddhi.core.event.stream.StreamEvent> complexEventChunk, io.siddhi.core.query.processor.Processor processor, io.siddhi.core.event.stream.StreamEventCloner streamEventCloner, io.siddhi.core.event.stream.populater.ComplexEventPopulater complexEventPopulater, io.siddhi.extension.execution.streamingml.classification.perceptron.PerceptronClassifierUpdaterStreamProcessorExtension.ExtensionState extensionState)`
    `void` | `start()`
    `void` | `stop()`

    - ### Methods inherited from class io.siddhi.core.query.processor.stream.StreamProcessor

      `processEventChunk`

    - ### Methods inherited from class io.siddhi.core.query.processor.stream.AbstractStreamProcessor

      `constructStreamEventPopulater, getNextProcessor, initProcessor, process, setNextProcessor, setStreamEventCloner, setToLast`

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

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

- - ### Constructor Detail

    - #### PerceptronClassifierUpdaterStreamProcessorExtension

          public PerceptronClassifierUpdaterStreamProcessorExtension()

  - ### Method Detail

    - #### init

          protected io.siddhi.core.util.snapshot.state.StateFactory<io.siddhi.extension.execution.streamingml.classification.perceptron.PerceptronClassifierUpdaterStreamProcessorExtension.ExtensionState> init(io.siddhi.core.event.stream.MetaStreamEvent metaStreamEvent,
                                                                                                                                                                                                                 io.siddhi.query.api.definition.AbstractDefinition abstractDefinition,
                                                                                                                                                                                                                 io.siddhi.core.executor.ExpressionExecutor[] expressionExecutors,
                                                                                                                                                                                                                 io.siddhi.core.util.config.ConfigReader configReader,
                                                                                                                                                                                                                 io.siddhi.core.event.stream.holder.StreamEventClonerHolder streamEventClonerHolder,
                                                                                                                                                                                                                 boolean b,
                                                                                                                                                                                                                 boolean b1,
                                                                                                                                                                                                                 io.siddhi.core.config.SiddhiQueryContext siddhiQueryContext)

      Specified by:
        `init` in class `io.siddhi.core.query.processor.stream.AbstractStreamProcessor<io.siddhi.extension.execution.streamingml.classification.perceptron.PerceptronClassifierUpdaterStreamProcessorExtension.ExtensionState>`

    - #### getReturnAttributes

          public List<io.siddhi.query.api.definition.Attribute> getReturnAttributes()

      Specified by:
        `getReturnAttributes` in class `io.siddhi.core.query.processor.stream.AbstractStreamProcessor<io.siddhi.extension.execution.streamingml.classification.perceptron.PerceptronClassifierUpdaterStreamProcessorExtension.ExtensionState>`

    - #### getProcessingMode

          public io.siddhi.core.query.processor.ProcessingMode getProcessingMode()

      Specified by:
        `getProcessingMode` in class `io.siddhi.core.query.processor.stream.AbstractStreamProcessor<io.siddhi.extension.execution.streamingml.classification.perceptron.PerceptronClassifierUpdaterStreamProcessorExtension.ExtensionState>`

    - #### start

          public void start()

    - #### stop

          public void stop()

    - #### process

          protected void process(io.siddhi.core.event.ComplexEventChunk<io.siddhi.core.event.stream.StreamEvent> complexEventChunk,
                                 io.siddhi.core.query.processor.Processor processor,
                                 io.siddhi.core.event.stream.StreamEventCloner streamEventCloner,
                                 io.siddhi.core.event.stream.populater.ComplexEventPopulater complexEventPopulater,
                                 io.siddhi.extension.execution.streamingml.classification.perceptron.PerceptronClassifierUpdaterStreamProcessorExtension.ExtensionState extensionState)

      Specified by:
        `process` in class `io.siddhi.core.query.processor.stream.StreamProcessor<io.siddhi.extension.execution.streamingml.classification.perceptron.PerceptronClassifierUpdaterStreamProcessorExtension.ExtensionState>`

Copyright © 2019 WSO2. All rights reserved.