示例#1
0
def fuzzyAsynMemTriangle(name):
	g = NodeGroup("AsynFuzzyMemTriangle", True);
	g.addNode(ftriangle,"AsynFuzzyMemTriangle","java");
	module = AsynNeuralModule(name+'_AsynFuzzyMemTriangle', g)
	module.createEncoder("logic/gates/ina", "float", 1)		# x
	module.createEncoder("logic/gates/confa", "float", 1) 	# alpha
	module.createEncoder("logic/gates/confb", "float", 1) 	# beta
	module.createEncoder("logic/gates/confc", "float", 1) 	# gamma
	module.createDecoder("logic/gates/outa", "float", 1)	# y
	return module
示例#2
0
def fuzzyAsynMemTriangle(name):
    g = NodeGroup("AsynFuzzyMemTriangle", True)
    g.addNode(ftriangle, "AsynFuzzyMemTriangle", "java")
    module = AsynNeuralModule(name + '_AsynFuzzyMemTriangle', g)
    module.createEncoder("logic/gates/ina", "float", 1)  # x
    module.createEncoder("logic/gates/confa", "float", 1)  # alpha
    module.createEncoder("logic/gates/confb", "float", 1)  # beta
    module.createEncoder("logic/gates/confc", "float", 1)  # gamma
    module.createDecoder("logic/gates/outa", "float", 1)  # y
    return module
示例#3
0
def make(net,name='NeuralModule which implements FuzzyMembership function - Triangular - projectTemplate', 
independent=True, useQuick=True):

    finder = "org.hanns.myPackage.fuzzy.membership.impl.Triangular";

    # create group with a name
    g = NodeGroup(name, independent);   
    g.addNode(finder, "temp_FuzzyMemTriangular", "java");     

    neuron = NeuralModule(name+"_temp_FuzzyMemTriangular", g) 
    neuron.createEncoder("logic/gates/ina", "float",1)   	# termination = data input x 
    neuron.createEncoder("logic/gates/confa", "float",1)	# termination - config input alpha
    neuron.createEncoder("logic/gates/confb", "float",1)	# termination - config input betaa
    neuron.createEncoder("logic/gates/confc", "float",1)	# termination - config input gamma
    neuron.createDecoder("logic/gates/outa", "float",1)  	# origin = output of neuron = data output y


    many=net.add(neuron)                    # add it into the network