# This file was automatically generated by SWIG (http://www.swig.org).
# Version 4.0.1
#
# Do not make changes to this file unless you know what you are doing--modify
# the SWIG interface file instead.

"""Feedforward Closedloop Learning"""

from sys import version_info as _swig_python_version_info
if _swig_python_version_info < (2, 7, 0):
    raise RuntimeError("Python 2.7 or later required")

# Import the low-level C/C++ module
if __package__ or "." in __name__:
    from . import _feedforward_closedloop_learning
else:
    import _feedforward_closedloop_learning

try:
    import builtins as __builtin__
except ImportError:
    import __builtin__

def _swig_repr(self):
    try:
        strthis = "proxy of " + self.this.__repr__()
    except __builtin__.Exception:
        strthis = ""
    return "<%s.%s; %s >" % (self.__class__.__module__, self.__class__.__name__, strthis,)


def _swig_setattr_nondynamic_instance_variable(set):
    def set_instance_attr(self, name, value):
        if name == "thisown":
            self.this.own(value)
        elif name == "this":
            set(self, name, value)
        elif hasattr(self, name) and isinstance(getattr(type(self), name), property):
            set(self, name, value)
        else:
            raise AttributeError("You cannot add instance attributes to %s" % self)
    return set_instance_attr


def _swig_setattr_nondynamic_class_variable(set):
    def set_class_attr(cls, name, value):
        if hasattr(cls, name) and not isinstance(getattr(cls, name), property):
            set(cls, name, value)
        else:
            raise AttributeError("You cannot add class attributes to %s" % cls)
    return set_class_attr


def _swig_add_metaclass(metaclass):
    """Class decorator for adding a metaclass to a SWIG wrapped class - a slimmed down version of six.add_metaclass"""
    def wrapper(cls):
        return metaclass(cls.__name__, cls.__bases__, cls.__dict__.copy())
    return wrapper


class _SwigNonDynamicMeta(type):
    """Meta class to enforce nondynamic attributes (no new attributes) for a class"""
    __setattr__ = _swig_setattr_nondynamic_class_variable(type.__setattr__)


class FeedforwardClosedloopLearning(object):
    r"""Proxy of C++ FeedforwardClosedloopLearning class."""

    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def __init__(self, num_of_inputs: "int", num_of_neurons_per_layer_array: "int *"):
        r"""
        __init__(FeedforwardClosedloopLearning self, int num_of_inputs, int * num_of_neurons_per_layer_array) -> FeedforwardClosedloopLearning

        Parameters
        ----------
        num_of_inputs: int
        num_of_neurons_per_layer_array: int *

        """
        _feedforward_closedloop_learning.FeedforwardClosedloopLearning_swiginit(self, _feedforward_closedloop_learning.new_FeedforwardClosedloopLearning(num_of_inputs, num_of_neurons_per_layer_array))
    __swig_destroy__ = _feedforward_closedloop_learning.delete_FeedforwardClosedloopLearning

    def doStep(self, *args) -> "void":
        r"""
        doStep(FeedforwardClosedloopLearning self, double * input, double * error)

        Parameters
        ----------
        input: double *
        error: double *

        doStep(FeedforwardClosedloopLearning self, double * input, double * error)

        Parameters
        ----------
        input: double *
        error: double *

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_doStep(self, *args)

    def getOutput(self, index: "int") -> "double":
        r"""
        getOutput(FeedforwardClosedloopLearning self, int index) -> double

        Parameters
        ----------
        index: int

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_getOutput(self, index)

    def setLearningRate(self, learningRate: "double") -> "void":
        r"""
        setLearningRate(FeedforwardClosedloopLearning self, double learningRate)

        Parameters
        ----------
        learningRate: double

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_setLearningRate(self, learningRate)

    def setLearningRateDiscountFactor(self, _learningRateDiscountFactor: "double") -> "void":
        r"""
        setLearningRateDiscountFactor(FeedforwardClosedloopLearning self, double _learningRateDiscountFactor)

        Parameters
        ----------
        _learningRateDiscountFactor: double

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_setLearningRateDiscountFactor(self, _learningRateDiscountFactor)

    def setDecay(self, decay: "double") -> "void":
        r"""
        setDecay(FeedforwardClosedloopLearning self, double decay)

        Parameters
        ----------
        decay: double

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_setDecay(self, decay)

    def setMomentum(self, momentum: "double") -> "void":
        r"""
        setMomentum(FeedforwardClosedloopLearning self, double momentum)

        Parameters
        ----------
        momentum: double

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_setMomentum(self, momentum)

    def setActivationFunction(self, _activationFunction: "Neuron::ActivationFunction") -> "void":
        r"""
        setActivationFunction(FeedforwardClosedloopLearning self, Neuron::ActivationFunction _activationFunction)

        Parameters
        ----------
        _activationFunction: enum Neuron::ActivationFunction

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_setActivationFunction(self, _activationFunction)

    def initWeights(self, *args) -> "void":
        r"""
        initWeights(FeedforwardClosedloopLearning self, double max=0.001, int initBias=1, Neuron::WeightInitMethod weightInitMethod=MAX_OUTPUT_RANDOM)

        Parameters
        ----------
        max: double
        initBias: int
        weightInitMethod: enum Neuron::WeightInitMethod

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_initWeights(self, *args)

    def seedRandom(self, s: "int") -> "void":
        r"""
        seedRandom(FeedforwardClosedloopLearning self, int s)

        Parameters
        ----------
        s: int

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_seedRandom(self, s)

    def setBias(self, _bias: "double") -> "void":
        r"""
        setBias(FeedforwardClosedloopLearning self, double _bias)

        Parameters
        ----------
        _bias: double

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_setBias(self, _bias)

    def getNumLayers(self) -> "int":
        r"""getNumLayers(FeedforwardClosedloopLearning self) -> int"""
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_getNumLayers(self)

    def getLayer(self, i: "int") -> "Layer *":
        r"""
        getLayer(FeedforwardClosedloopLearning self, int i) -> Layer

        Parameters
        ----------
        i: int

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_getLayer(self, i)

    def getOutputLayer(self) -> "Layer *":
        r"""getOutputLayer(FeedforwardClosedloopLearning self) -> Layer"""
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_getOutputLayer(self)

    def getNumInputs(self) -> "int":
        r"""getNumInputs(FeedforwardClosedloopLearning self) -> int"""
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_getNumInputs(self)

    def getLayers(self) -> "Layer **":
        r"""getLayers(FeedforwardClosedloopLearning self) -> Layer **"""
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_getLayers(self)

    def saveModel(self, name: "char const *") -> "bool":
        r"""
        saveModel(FeedforwardClosedloopLearning self, char const * name) -> bool

        Parameters
        ----------
        name: char const *

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_saveModel(self, name)

    def loadModel(self, name: "char const *") -> "bool":
        r"""
        loadModel(FeedforwardClosedloopLearning self, char const * name) -> bool

        Parameters
        ----------
        name: char const *

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearning_loadModel(self, name)

# Register FeedforwardClosedloopLearning in _feedforward_closedloop_learning:
_feedforward_closedloop_learning.FeedforwardClosedloopLearning_swigregister(FeedforwardClosedloopLearning)

class FeedforwardClosedloopLearningWithFilterbank(FeedforwardClosedloopLearning):
    r"""Proxy of C++ FeedforwardClosedloopLearningWithFilterbank class."""

    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def __init__(self, num_of_inputs: "int", num_of_neurons_per_layer_array: "int *", num_filtersInput: "int", minT: "double", maxT: "double"):
        r"""
        __init__(FeedforwardClosedloopLearningWithFilterbank self, int num_of_inputs, int * num_of_neurons_per_layer_array, int num_filtersInput, double minT, double maxT) -> FeedforwardClosedloopLearningWithFilterbank

        Parameters
        ----------
        num_of_inputs: int
        num_of_neurons_per_layer_array: int *
        num_filtersInput: int
        minT: double
        maxT: double

        """
        _feedforward_closedloop_learning.FeedforwardClosedloopLearningWithFilterbank_swiginit(self, _feedforward_closedloop_learning.new_FeedforwardClosedloopLearningWithFilterbank(num_of_inputs, num_of_neurons_per_layer_array, num_filtersInput, minT, maxT))
    __swig_destroy__ = _feedforward_closedloop_learning.delete_FeedforwardClosedloopLearningWithFilterbank

    def doStep(self, *args) -> "void":
        r"""
        doStep(FeedforwardClosedloopLearningWithFilterbank self, double * input, double * error)

        Parameters
        ----------
        input: double *
        error: double *

        doStep(FeedforwardClosedloopLearningWithFilterbank self, double * input, double * error)

        Parameters
        ----------
        input: double *
        error: double *

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearningWithFilterbank_doStep(self, *args)

    def getFilterOutput(self, inputIdx: "int", filterIdx: "int") -> "double":
        r"""
        getFilterOutput(FeedforwardClosedloopLearningWithFilterbank self, int inputIdx, int filterIdx) -> double

        Parameters
        ----------
        inputIdx: int
        filterIdx: int

        """
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearningWithFilterbank_getFilterOutput(self, inputIdx, filterIdx)

    def getNFiltersPerInput(self) -> "int":
        r"""getNFiltersPerInput(FeedforwardClosedloopLearningWithFilterbank self) -> int"""
        return _feedforward_closedloop_learning.FeedforwardClosedloopLearningWithFilterbank_getNFiltersPerInput(self)

# Register FeedforwardClosedloopLearningWithFilterbank in _feedforward_closedloop_learning:
_feedforward_closedloop_learning.FeedforwardClosedloopLearningWithFilterbank_swigregister(FeedforwardClosedloopLearningWithFilterbank)

NUM_THREADS = _feedforward_closedloop_learning.NUM_THREADS

class LayerThread(object):
    r"""Proxy of C++ LayerThread class."""

    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")

    def __init__(self, *args, **kwargs):
        raise AttributeError("No constructor defined - class is abstract")
    __repr__ = _swig_repr
    __swig_destroy__ = _feedforward_closedloop_learning.delete_LayerThread

    def addNeuron(self, neuron: "Neuron") -> "void":
        r"""
        addNeuron(LayerThread self, Neuron neuron)

        Parameters
        ----------
        neuron: Neuron *

        """
        return _feedforward_closedloop_learning.LayerThread_addNeuron(self, neuron)

    def start(self) -> "void":
        r"""start(LayerThread self)"""
        return _feedforward_closedloop_learning.LayerThread_start(self)

    def join(self) -> "void":
        r"""join(LayerThread self)"""
        return _feedforward_closedloop_learning.LayerThread_join(self)

    def run(self) -> "void":
        r"""run(LayerThread self)"""
        return _feedforward_closedloop_learning.LayerThread_run(self)

# Register LayerThread in _feedforward_closedloop_learning:
_feedforward_closedloop_learning.LayerThread_swigregister(LayerThread)

class CalcOutputThread(LayerThread):
    r"""Proxy of C++ CalcOutputThread class."""

    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")

    def __init__(self, *args, **kwargs):
        raise AttributeError("No constructor defined")
    __repr__ = _swig_repr
    __swig_destroy__ = _feedforward_closedloop_learning.delete_CalcOutputThread

# Register CalcOutputThread in _feedforward_closedloop_learning:
_feedforward_closedloop_learning.CalcOutputThread_swigregister(CalcOutputThread)

class LearningThread(LayerThread):
    r"""Proxy of C++ LearningThread class."""

    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")

    def __init__(self, *args, **kwargs):
        raise AttributeError("No constructor defined")
    __repr__ = _swig_repr
    __swig_destroy__ = _feedforward_closedloop_learning.delete_LearningThread

# Register LearningThread in _feedforward_closedloop_learning:
_feedforward_closedloop_learning.LearningThread_swigregister(LearningThread)

class MaxDetThread(LayerThread):
    r"""Proxy of C++ MaxDetThread class."""

    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")

    def __init__(self, *args, **kwargs):
        raise AttributeError("No constructor defined")
    __repr__ = _swig_repr
    __swig_destroy__ = _feedforward_closedloop_learning.delete_MaxDetThread

# Register MaxDetThread in _feedforward_closedloop_learning:
_feedforward_closedloop_learning.MaxDetThread_swigregister(MaxDetThread)

class Layer(object):
    r"""Proxy of C++ Layer class."""

    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def __init__(self, _nNeurons: "int", _nInputs: "int"):
        r"""
        __init__(Layer self, int _nNeurons, int _nInputs) -> Layer

        Parameters
        ----------
        _nNeurons: int
        _nInputs: int

        """
        _feedforward_closedloop_learning.Layer_swiginit(self, _feedforward_closedloop_learning.new_Layer(_nNeurons, _nInputs))
    __swig_destroy__ = _feedforward_closedloop_learning.delete_Layer
    WEIGHT_NORM_NONE = _feedforward_closedloop_learning.Layer_WEIGHT_NORM_NONE
    
    WEIGHT_NORM_LAYER_EUCLEDIAN = _feedforward_closedloop_learning.Layer_WEIGHT_NORM_LAYER_EUCLEDIAN
    
    WEIGHT_NORM_NEURON_EUCLEDIAN = _feedforward_closedloop_learning.Layer_WEIGHT_NORM_NEURON_EUCLEDIAN
    
    WEIGHT_NORM_LAYER_MANHATTAN = _feedforward_closedloop_learning.Layer_WEIGHT_NORM_LAYER_MANHATTAN
    
    WEIGHT_NORM_NEURON_MANHATTAN = _feedforward_closedloop_learning.Layer_WEIGHT_NORM_NEURON_MANHATTAN
    
    WEIGHT_NORM_LAYER_INFINITY = _feedforward_closedloop_learning.Layer_WEIGHT_NORM_LAYER_INFINITY
    
    WEIGHT_NORM_NEURON_INFINITY = _feedforward_closedloop_learning.Layer_WEIGHT_NORM_NEURON_INFINITY
    

    def calcOutputs(self) -> "void":
        r"""calcOutputs(Layer self)"""
        return _feedforward_closedloop_learning.Layer_calcOutputs(self)

    def doLearning(self) -> "void":
        r"""doLearning(Layer self)"""
        return _feedforward_closedloop_learning.Layer_doLearning(self)

    def setError(self, *args) -> "void":
        r"""
        setError(Layer self, double _error)

        Parameters
        ----------
        _error: double

        setError(Layer self, int i, double _error)

        Parameters
        ----------
        i: int
        _error: double

        """
        return _feedforward_closedloop_learning.Layer_setError(self, *args)

    def setErrors(self, _errors: "double *") -> "void":
        r"""
        setErrors(Layer self, double * _errors)

        Parameters
        ----------
        _errors: double *

        """
        return _feedforward_closedloop_learning.Layer_setErrors(self, _errors)

    def getError(self, i: "int") -> "double":
        r"""
        getError(Layer self, int i) -> double

        Parameters
        ----------
        i: int

        """
        return _feedforward_closedloop_learning.Layer_getError(self, i)

    def setBias(self, _bias: "double") -> "void":
        r"""
        setBias(Layer self, double _bias)

        Parameters
        ----------
        _bias: double

        """
        return _feedforward_closedloop_learning.Layer_setBias(self, _bias)

    def setInput(self, inputIndex: "int", input: "double") -> "void":
        r"""
        setInput(Layer self, int inputIndex, double input)

        Parameters
        ----------
        inputIndex: int
        input: double

        """
        return _feedforward_closedloop_learning.Layer_setInput(self, inputIndex, input)

    def setInputs(self, _inputs: "double *") -> "void":
        r"""
        setInputs(Layer self, double * _inputs)

        Parameters
        ----------
        _inputs: double *

        """
        return _feedforward_closedloop_learning.Layer_setInputs(self, _inputs)

    def setLearningRate(self, _learningRate: "double") -> "void":
        r"""
        setLearningRate(Layer self, double _learningRate)

        Parameters
        ----------
        _learningRate: double

        """
        return _feedforward_closedloop_learning.Layer_setLearningRate(self, _learningRate)

    def setActivationFunction(self, _activationFunction: "Neuron::ActivationFunction") -> "void":
        r"""
        setActivationFunction(Layer self, Neuron::ActivationFunction _activationFunction)

        Parameters
        ----------
        _activationFunction: enum Neuron::ActivationFunction

        """
        return _feedforward_closedloop_learning.Layer_setActivationFunction(self, _activationFunction)

    def setMomentum(self, _momentum: "double") -> "void":
        r"""
        setMomentum(Layer self, double _momentum)

        Parameters
        ----------
        _momentum: double

        """
        return _feedforward_closedloop_learning.Layer_setMomentum(self, _momentum)

    def setDecay(self, _decay: "double") -> "void":
        r"""
        setDecay(Layer self, double _decay)

        Parameters
        ----------
        _decay: double

        """
        return _feedforward_closedloop_learning.Layer_setDecay(self, _decay)

    def initWeights(self, *args) -> "void":
        r"""
        initWeights(Layer self, double _max=1, int initBiasWeight=1, Neuron::WeightInitMethod weightInitMethod=MAX_OUTPUT_RANDOM)

        Parameters
        ----------
        _max: double
        initBiasWeight: int
        weightInitMethod: enum Neuron::WeightInitMethod

        """
        return _feedforward_closedloop_learning.Layer_initWeights(self, *args)

    def getOutput(self, index: "int") -> "double":
        r"""
        getOutput(Layer self, int index) -> double

        Parameters
        ----------
        index: int

        """
        return _feedforward_closedloop_learning.Layer_getOutput(self, index)

    def getNeuron(self, index: "int") -> "Neuron *":
        r"""
        getNeuron(Layer self, int index) -> Neuron

        Parameters
        ----------
        index: int

        """
        return _feedforward_closedloop_learning.Layer_getNeuron(self, index)

    def getNneurons(self) -> "int":
        r"""getNneurons(Layer self) -> int"""
        return _feedforward_closedloop_learning.Layer_getNneurons(self)

    def getNinputs(self) -> "int":
        r"""getNinputs(Layer self) -> int"""
        return _feedforward_closedloop_learning.Layer_getNinputs(self)

    def setConvolution(self, width: "int", height: "int") -> "void":
        r"""
        setConvolution(Layer self, int width, int height)

        Parameters
        ----------
        width: int
        height: int

        """
        return _feedforward_closedloop_learning.Layer_setConvolution(self, width, height)

    def setMaxDetLayer(self, _m: "int") -> "void":
        r"""
        setMaxDetLayer(Layer self, int _m)

        Parameters
        ----------
        _m: int

        """
        return _feedforward_closedloop_learning.Layer_setMaxDetLayer(self, _m)

    def setNormaliseWeights(self, _normaliseWeights: "Layer::WeightNormalisation") -> "void":
        r"""
        setNormaliseWeights(Layer self, Layer::WeightNormalisation _normaliseWeights)

        Parameters
        ----------
        _normaliseWeights: enum Layer::WeightNormalisation

        """
        return _feedforward_closedloop_learning.Layer_setNormaliseWeights(self, _normaliseWeights)

    def setDebugInfo(self, layerIndex: "int") -> "void":
        r"""
        setDebugInfo(Layer self, int layerIndex)

        Parameters
        ----------
        layerIndex: int

        """
        return _feedforward_closedloop_learning.Layer_setDebugInfo(self, layerIndex)

    def setStep(self, step: "long") -> "void":
        r"""
        setStep(Layer self, long step)

        Parameters
        ----------
        step: long

        """
        return _feedforward_closedloop_learning.Layer_setStep(self, step)

    def getWeightDistanceFromInitialWeights(self) -> "double":
        r"""getWeightDistanceFromInitialWeights(Layer self) -> double"""
        return _feedforward_closedloop_learning.Layer_getWeightDistanceFromInitialWeights(self)

    def doNormaliseWeights(self) -> "void":
        r"""doNormaliseWeights(Layer self)"""
        return _feedforward_closedloop_learning.Layer_doNormaliseWeights(self)

    def setUseThreads(self, _useThreads: "int") -> "void":
        r"""
        setUseThreads(Layer self, int _useThreads)

        Parameters
        ----------
        _useThreads: int

        """
        return _feedforward_closedloop_learning.Layer_setUseThreads(self, _useThreads)

    def saveWeightMatrix(self, filename: "char *") -> "int":
        r"""
        saveWeightMatrix(Layer self, char * filename) -> int

        Parameters
        ----------
        filename: char *

        """
        return _feedforward_closedloop_learning.Layer_saveWeightMatrix(self, filename)

# Register Layer in _feedforward_closedloop_learning:
_feedforward_closedloop_learning.Layer_swigregister(Layer)

class Neuron(object):
    r"""Proxy of C++ Neuron class."""

    thisown = property(lambda x: x.this.own(), lambda x, v: x.this.own(v), doc="The membership flag")
    __repr__ = _swig_repr

    def __init__(self, _nInputs: "int"):
        r"""
        __init__(Neuron self, int _nInputs) -> Neuron

        Parameters
        ----------
        _nInputs: int

        """
        _feedforward_closedloop_learning.Neuron_swiginit(self, _feedforward_closedloop_learning.new_Neuron(_nInputs))
    __swig_destroy__ = _feedforward_closedloop_learning.delete_Neuron

    def calcOutput(self) -> "void":
        r"""calcOutput(Neuron self)"""
        return _feedforward_closedloop_learning.Neuron_calcOutput(self)

    @staticmethod
    def calcOutputThread(object: "void *") -> "void *":
        r"""
        calcOutputThread(void * object) -> void *

        Parameters
        ----------
        object: void *

        """
        return _feedforward_closedloop_learning.Neuron_calcOutputThread(object)

    def doLearning(self) -> "void":
        r"""doLearning(Neuron self)"""
        return _feedforward_closedloop_learning.Neuron_doLearning(self)

    @staticmethod
    def doLearningThread(object: "void *") -> "void *":
        r"""
        doLearningThread(void * object) -> void *

        Parameters
        ----------
        object: void *

        """
        return _feedforward_closedloop_learning.Neuron_doLearningThread(object)

    def doMaxDet(self) -> "void":
        r"""doMaxDet(Neuron self)"""
        return _feedforward_closedloop_learning.Neuron_doMaxDet(self)

    @staticmethod
    def doMaxDetThread(object: "void *") -> "void *":
        r"""
        doMaxDetThread(void * object) -> void *

        Parameters
        ----------
        object: void *

        """
        return _feedforward_closedloop_learning.Neuron_doMaxDetThread(object)
    MAX_OUTPUT_RANDOM = _feedforward_closedloop_learning.Neuron_MAX_OUTPUT_RANDOM
    
    MAX_WEIGHT_RANDOM = _feedforward_closedloop_learning.Neuron_MAX_WEIGHT_RANDOM
    
    MAX_OUTPUT_CONST = _feedforward_closedloop_learning.Neuron_MAX_OUTPUT_CONST
    
    CONST_WEIGHTS = _feedforward_closedloop_learning.Neuron_CONST_WEIGHTS
    

    def initWeights(self, *args) -> "void":
        r"""
        initWeights(Neuron self, double _max=1, int initBias=1, Neuron::WeightInitMethod _wm=MAX_OUTPUT_RANDOM)

        Parameters
        ----------
        _max: double
        initBias: int
        _wm: enum Neuron::WeightInitMethod

        """
        return _feedforward_closedloop_learning.Neuron_initWeights(self, *args)
    LINEAR = _feedforward_closedloop_learning.Neuron_LINEAR
    
    TANH = _feedforward_closedloop_learning.Neuron_TANH
    
    RELU = _feedforward_closedloop_learning.Neuron_RELU
    
    REMAXLU = _feedforward_closedloop_learning.Neuron_REMAXLU
    
    TANHLIMIT = _feedforward_closedloop_learning.Neuron_TANHLIMIT
    

    def setActivationFunction(self, _activationFunction: "Neuron::ActivationFunction") -> "void":
        r"""
        setActivationFunction(Neuron self, Neuron::ActivationFunction _activationFunction)

        Parameters
        ----------
        _activationFunction: enum Neuron::ActivationFunction

        """
        return _feedforward_closedloop_learning.Neuron_setActivationFunction(self, _activationFunction)

    def dActivation(self) -> "double":
        r"""dActivation(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_dActivation(self)

    def getMinWeightValue(self) -> "double":
        r"""getMinWeightValue(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_getMinWeightValue(self)

    def getMaxWeightValue(self) -> "double":
        r"""getMaxWeightValue(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_getMaxWeightValue(self)

    def getWeightDistanceFromInitialWeights(self) -> "double":
        r"""getWeightDistanceFromInitialWeights(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_getWeightDistanceFromInitialWeights(self)

    def getOutput(self) -> "double":
        r"""getOutput(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_getOutput(self)

    def getSum(self) -> "double":
        r"""getSum(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_getSum(self)

    def getWeight(self, _index: "int") -> "double":
        r"""
        getWeight(Neuron self, int _index) -> double

        Parameters
        ----------
        _index: int

        """
        return _feedforward_closedloop_learning.Neuron_getWeight(self, _index)

    def setWeight(self, _index: "int", _weight: "double") -> "void":
        r"""
        setWeight(Neuron self, int _index, double _weight)

        Parameters
        ----------
        _index: int
        _weight: double

        """
        return _feedforward_closedloop_learning.Neuron_setWeight(self, _index, _weight)

    def setError(self, _error: "double") -> "void":
        r"""
        setError(Neuron self, double _error)

        Parameters
        ----------
        _error: double

        """
        return _feedforward_closedloop_learning.Neuron_setError(self, _error)

    def getError(self) -> "double":
        r"""getError(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_getError(self)

    def setInput(self, _index: "int", _value: "double") -> "void":
        r"""
        setInput(Neuron self, int _index, double _value)

        Parameters
        ----------
        _index: int
        _value: double

        """
        return _feedforward_closedloop_learning.Neuron_setInput(self, _index, _value)

    def getInput(self, _index: "int") -> "double":
        r"""
        getInput(Neuron self, int _index) -> double

        Parameters
        ----------
        _index: int

        """
        return _feedforward_closedloop_learning.Neuron_getInput(self, _index)

    def getBiasWeight(self) -> "double":
        r"""getBiasWeight(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_getBiasWeight(self)

    def setBiasWeight(self, _biasweight: "double") -> "void":
        r"""
        setBiasWeight(Neuron self, double _biasweight)

        Parameters
        ----------
        _biasweight: double

        """
        return _feedforward_closedloop_learning.Neuron_setBiasWeight(self, _biasweight)

    def setBias(self, _bias: "double") -> "void":
        r"""
        setBias(Neuron self, double _bias)

        Parameters
        ----------
        _bias: double

        """
        return _feedforward_closedloop_learning.Neuron_setBias(self, _bias)

    def setLearningRate(self, _learningrate: "double") -> "void":
        r"""
        setLearningRate(Neuron self, double _learningrate)

        Parameters
        ----------
        _learningrate: double

        """
        return _feedforward_closedloop_learning.Neuron_setLearningRate(self, _learningrate)

    def setMomentum(self, _momentum: "double") -> "void":
        r"""
        setMomentum(Neuron self, double _momentum)

        Parameters
        ----------
        _momentum: double

        """
        return _feedforward_closedloop_learning.Neuron_setMomentum(self, _momentum)

    def setDecay(self, _decay: "double") -> "void":
        r"""
        setDecay(Neuron self, double _decay)

        Parameters
        ----------
        _decay: double

        """
        return _feedforward_closedloop_learning.Neuron_setDecay(self, _decay)

    def getDecay(self) -> "double":
        r"""getDecay(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_getDecay(self)

    def getNinputs(self) -> "int":
        r"""getNinputs(Neuron self) -> int"""
        return _feedforward_closedloop_learning.Neuron_getNinputs(self)

    def setGeometry(self, _width: "int", _height: "int") -> "void":
        r"""
        setGeometry(Neuron self, int _width, int _height)

        Parameters
        ----------
        _width: int
        _height: int

        """
        return _feedforward_closedloop_learning.Neuron_setGeometry(self, _width, _height)

    def setMask(self, *args) -> "void":
        r"""
        setMask(Neuron self, int x, int y, unsigned char c)

        Parameters
        ----------
        x: int
        y: int
        c: unsigned char

        setMask(Neuron self, unsigned char c)

        Parameters
        ----------
        c: unsigned char

        """
        return _feedforward_closedloop_learning.Neuron_setMask(self, *args)

    def getMask(self, *args) -> "unsigned char":
        r"""
        getMask(Neuron self, int x, int y) -> unsigned char

        Parameters
        ----------
        x: int
        y: int

        getMask(Neuron self, int index) -> unsigned char

        Parameters
        ----------
        index: int

        """
        return _feedforward_closedloop_learning.Neuron_getMask(self, *args)

    def getSumOfSquaredWeightVector(self) -> "double":
        r"""getSumOfSquaredWeightVector(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_getSumOfSquaredWeightVector(self)

    def getEuclideanNormOfWeightVector(self) -> "double":
        r"""getEuclideanNormOfWeightVector(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_getEuclideanNormOfWeightVector(self)

    def getManhattanNormOfWeightVector(self) -> "double":
        r"""getManhattanNormOfWeightVector(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_getManhattanNormOfWeightVector(self)

    def getInfinityNormOfWeightVector(self) -> "double":
        r"""getInfinityNormOfWeightVector(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_getInfinityNormOfWeightVector(self)

    def getAverageOfWeightVector(self) -> "double":
        r"""getAverageOfWeightVector(Neuron self) -> double"""
        return _feedforward_closedloop_learning.Neuron_getAverageOfWeightVector(self)

    def normaliseWeights(self, norm: "double") -> "void":
        r"""
        normaliseWeights(Neuron self, double norm)

        Parameters
        ----------
        norm: double

        """
        return _feedforward_closedloop_learning.Neuron_normaliseWeights(self, norm)

    def saveInitialWeights(self) -> "void":
        r"""saveInitialWeights(Neuron self)"""
        return _feedforward_closedloop_learning.Neuron_saveInitialWeights(self)

    def setDebugInfo(self, _layerIndex: "int", _neuronIndex: "int") -> "void":
        r"""
        setDebugInfo(Neuron self, int _layerIndex, int _neuronIndex)

        Parameters
        ----------
        _layerIndex: int
        _neuronIndex: int

        """
        return _feedforward_closedloop_learning.Neuron_setDebugInfo(self, _layerIndex, _neuronIndex)

    def setStep(self, _step: "long") -> "void":
        r"""
        setStep(Neuron self, long _step)

        Parameters
        ----------
        _step: long

        """
        return _feedforward_closedloop_learning.Neuron_setStep(self, _step)

# Register Neuron in _feedforward_closedloop_learning:
_feedforward_closedloop_learning.Neuron_swigregister(Neuron)

def Neuron_calcOutputThread(object: "void *") -> "void *":
    r"""
    Neuron_calcOutputThread(void * object) -> void *

    Parameters
    ----------
    object: void *

    """
    return _feedforward_closedloop_learning.Neuron_calcOutputThread(object)

def Neuron_doLearningThread(object: "void *") -> "void *":
    r"""
    Neuron_doLearningThread(void * object) -> void *

    Parameters
    ----------
    object: void *

    """
    return _feedforward_closedloop_learning.Neuron_doLearningThread(object)

def Neuron_doMaxDetThread(object: "void *") -> "void *":
    r"""
    Neuron_doMaxDetThread(void * object) -> void *

    Parameters
    ----------
    object: void *

    """
    return _feedforward_closedloop_learning.Neuron_doMaxDetThread(object)



