adding kfn

This commit is contained in:
ton
2023-07-06 17:20:46 +07:00
parent c08b821a29
commit d427875679
3 changed files with 49 additions and 34 deletions

View File

@@ -1,8 +1,12 @@
module type
# export
export
# struct
kfn
using CUDA, Random
# function
using Random
#------------------------------------------------------------------------------------------------100
@@ -25,40 +29,13 @@ Base.@kwdef mutable struct kfn <: knowledgeFn
end
function kfn(kfnParams::Dict)
kfn = kfn()
kfn.kfnParams = kfnParams
kfn.knowledgeFnName = kfn.kfnParams[:knowledgeFnName]
kfn_1 = kfn()
kfn_1.params = kfnParams
if kfn.kfnParams[:computeNeuronNumber] < kfn.kfnParams[:totalInputPort]
if kfn_1.params[:computeNeuronNumber] < kfn_1.params[:totalInputPort]
throw(error("number of compute neuron must be greater than input neuron"))
end
error("debug end")
end