亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频

? 歡迎來到蟲蟲下載站! | ?? 資源下載 ?? 資源專輯 ?? 關于我們
? 蟲蟲下載站

?? alphaneuron.cpp

?? amygdata的神經網絡算法源代碼
?? CPP
?? 第 1 頁 / 共 2 頁
字號:
/***************************************************************************                          alphaneuron.cpp  -  description                             -------------------    copyright            : (C) 2001 by Matt Grover    email                : mgrover@amygdala.org ***************************************************************************//*************************************************************************** *                                                                         * *   This program is free software; you can redistribute it and/or modify  * *   it under the terms of the GNU General Public License as published by  * *   the Free Software Foundation; either version 2 of the License, or     * *   (at your option) any later version.                                   * *                                                                         * ***************************************************************************/#include <cmath>#include "alphaneuron.h"#include "euler.h"#include "network.h"#include "functionlookup.h"#include "dendrite.h"#include "logging.h"#include "utilities.h"#include <iostream>using namespace std;using namespace Amygdala;unsigned int AlphaNeuron::pspStepSize = 0;unsigned int AlphaNeuron::pspLSize = 0;///////////////////////////////////////////////////////// AlphaNeuronProperties/////////////////////////////////////////////////////AlphaNeuronProperties::AlphaNeuronProperties():	SpikingNeuronProperties(){}AlphaNeuronProperties::AlphaNeuronProperties(bool initializePhysicalProps):	SpikingNeuronProperties(initializePhysicalProps){}AlphaNeuronProperties::AlphaNeuronProperties(const AlphaNeuronProperties& rhs):	SpikingNeuronProperties(rhs){	memTimeConst = rhs.memTimeConst;	eSynTimeConst = rhs.eSynTimeConst;	iSynTimeConst = rhs.iSynTimeConst;}AlphaNeuronProperties::~AlphaNeuronProperties(){}AlphaNeuronProperties* AlphaNeuronProperties::Copy() const{	return new AlphaNeuronProperties(*this);}void AlphaNeuronProperties::SetProperty(string& name, string& value){    // Properties:    // memTimeConst    // eSynTimeConst    // iSynTimeConst    if (!name.compare("membraneTimeConst")) {        memTimeConst = atof(value.c_str());    }    else if (!name.compare("eSynapticTimeConst")) {        eSynTimeConst = atof(value.c_str());    }    else if (!name.compare("iSynapticTimeConst")) {        iSynTimeConst = atof(value.c_str());    }    else {        NeuronProperties::SetProperty(name, value);    }}map< string, string > AlphaNeuronProperties::GetPropertyMap() const{    map< string, string > propMap = NeuronProperties::GetPropertyMap();    propMap["membraneTimeConst"] = Utilities::ftostr(memTimeConst);    propMap["eSynapticTimeConst"] = Utilities::ftostr(eSynTimeConst);    propMap["iSynapticTimeConst"] = Utilities::ftostr(iSynTimeConst);        return propMap;}///////////////////////////////////////////////////////// AlphaNeuron/////////////////////////////////////////////////////AlphaNeuron::AlphaNeuron(AmIdInt neuronId, const AlphaNeuronProperties& neuronProps):    SpikingNeuron(neuronId, neuronProps),    histBeginIdx(0),    maxThreshCrs(0),    convergeRes(0){    epspLookup = 0;    edPspLookup = 0;    ipspLookup = 0;    idPspLookup = 0;        if (!pspStepSize) {	    Init();    }        InitLookup();}AlphaNeuron::~AlphaNeuron(){}void AlphaNeuron::Init(){	//pspStepSize = Network::TimeStepSize()/10;	pspStepSize = Network::TimeStepSize();	pspLSize = 100000/pspStepSize;		// 100ms / step size		LOGGER(3, "pspStepSize: " << pspStepSize << " pspLSize: " << pspLSize)}void AlphaNeuron::SetProperties(AlphaNeuronProperties* props){	delete neuronProps;	neuronProps = props->Copy();}void AlphaNeuron::SpikeCleanup(){	// reset inputHist vector	inputHist.clear();	histBeginIdx = 0;}void AlphaNeuron::ProcessInput(const AmTimeInt& inTime){    unsigned int i, iterate, converged, histSize, tblIndex;    AmTimeInt calcTime, funcTime;    float currState = 0.0;    float currDeriv = 0.0;    float funcWeight = 0.0;    float stateDelta = 0.0;    float threshCrs = 0.0;    float lstThreshCrs = 0.0;    InputHist tmpInput;    // If the neuron is within a refractory period,    if ( (inTime - spikeTime) <= refPeriod ) {        if (inTime > refPeriod) {	        dendrite->ResetTrigger();            return;        }    }    iterate = 1;    converged = 0;    calcTime = 0;    funcTime = 0;    histSize = 0;    if (!maxThreshCrs) {        maxThreshCrs = pspLSize * pspStepSize;        LOGGER(5, "maxThreshCrs = " << maxThreshCrs)        // find the convergence resolution (the resolution at which two values        // of threshCrs are considered to be identical) -- must be <= simStepSize        if (simStepSize > pspStepSize) {            if (pspStepSize > (simStepSize / 2.0)) {                convergeRes = pspStepSize;            }            else {                convergeRes = simStepSize / 2.0;            }        }        else {            convergeRes = simStepSize;        }    }    calcTime = inTime;    inputTime = inTime;    currTime = inTime;    float inWeightPos, inWeightNeg;    dendrite->GetStimulationLevel(inWeightPos, inWeightNeg);    /*if (trainingMode) {        //inWeight = inputHeader->SumQueue(true, synapseHist, inTime);        dendrite->GetStimulationLevel(inWeightPos, inWeightNeg);    }    else {        //inWeight = inputHeader->SumQueue(true);        dendrite->GetStimulationLevel(inWeightPos, inWeightNeg);    }*/    tmpInput.time = inTime;    if (inWeightPos) {        tmpInput.weight = inWeightPos;        inputHist.push_back(tmpInput);    }    if (inWeightNeg) {        tmpInput.weight = inWeightNeg;        inputHist.push_back(tmpInput);    }        histSize = inputHist.size();    //LOG_WEIGHT_HIST(6)        i = 0;    // Use Newton's method to determine if and when the spike will occur    /**************************************************************************    *    1) Determine the membrane potential (currState) at time (calcTime -    *       inTimeHist[i]) by summing the state of each inTimeHist[]    *       (use pspLookup).    *    2) Find the derivative of the function for calcTime (dPspLookup).    *    3) Calculate intercept with thresholdPtnl.    *    4) Set new calcTime to time of intercept.    *    5) Repeat until:    *        a) Two successive iterations result in no change in calcTime.    *            (Converges)    *        b) The derivative of the function becomes negative.    *            (Does not converge)    **************************************************************************/    LOGGER(6, "NEURON " << nId << " Starting main loop...")    lstThreshCrs = float(calcTime);    while (iterate) {        currState = 0.0;        currDeriv = 0.0;        Utilities::RoundTime(calcTime, pspStepSize);        LOGGER(6, "calcTime: " << calcTime)        for (i=histBeginIdx; i<histSize; i++) {            tmpInput = inputHist[i];            funcTime = calcTime - tmpInput.time;            funcWeight = tmpInput.weight;            LOGGER(6, "funcTime: " << funcTime << "\n\tfuncWeight: " << funcWeight)            tblIndex = (funcTime / pspStepSize);            LOGGER(6, "tblIndex for psp lookups: " << tblIndex)            if (tblIndex < pspLSize) {                if ( funcWeight > 0.0 ) {                    currState = currState + (funcWeight * (epspLookup[tblIndex]));                    currDeriv = currDeriv + (funcWeight * (edPspLookup[tblIndex]));                }                else {                    currState = currState + (funcWeight * (ipspLookup[tblIndex]));                    currDeriv = currDeriv + (funcWeight * (idPspLookup[tblIndex]));                }            }            else {                if (calcTime <= inTime)                    ++histBeginIdx;            }        }        LOGGER(6, "currState: " << currState << "\n\tcurrDerive: " << currDeriv)        if ( (currDeriv < 0.0) && (currState < 1.0) ) {

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
亚洲欧美日韩精品久久久久| 麻豆国产精品一区二区三区| 日本午夜一本久久久综合| 国产精品亚洲视频| 欧美一区三区四区| 中文字幕一区在线观看视频| 美女在线视频一区| 色88888久久久久久影院野外| 日韩一区二区在线观看视频播放| 国产精品久久久久影院老司| 麻豆国产一区二区| 337p亚洲精品色噜噜| 亚洲图片激情小说| 国产.欧美.日韩| 久久只精品国产| 麻豆精品在线播放| 欧美浪妇xxxx高跟鞋交| 亚洲精品第1页| 91视频91自| 亚洲婷婷综合色高清在线| 国产一区二区三区免费播放| 欧美精品黑人性xxxx| 亚洲一区二区三区四区中文字幕| 北条麻妃一区二区三区| 久久亚洲二区三区| 久草这里只有精品视频| 欧美日韩国产成人在线免费| 亚洲精品亚洲人成人网在线播放| av日韩在线网站| 国产精品人人做人人爽人人添| 国内精品国产三级国产a久久| 欧美一区二区二区| 日日欢夜夜爽一区| 欧美高清激情brazzers| 婷婷国产v国产偷v亚洲高清| 欧美人狂配大交3d怪物一区| 亚洲最色的网站| 欧美午夜视频网站| 天天色 色综合| 在线不卡一区二区| 久久成人麻豆午夜电影| 日韩精品影音先锋| 国产在线播放一区三区四| 精品欧美一区二区在线观看| 国产一区二区精品在线观看| 久久久久久久久久久电影| 国产风韵犹存在线视精品| 国产欧美综合在线观看第十页| 国产99久久精品| 亚洲乱码国产乱码精品精98午夜 | 粉嫩在线一区二区三区视频| 国产日韩欧美综合在线| 99精品视频在线播放观看| 一个色综合av| 欧美精品丝袜久久久中文字幕| 乱一区二区av| 国产精品无人区| 在线视频综合导航| 日本亚洲欧美天堂免费| 久久久精品影视| 色老头久久综合| 久久se精品一区二区| 欧美激情一区二区三区全黄| 91片黄在线观看| 青青草精品视频| 国产精品免费久久久久| 欧美日韩在线播放三区| 国产在线不卡一卡二卡三卡四卡| 中文字幕综合网| 日韩欧美你懂的| jiyouzz国产精品久久| 日韩精品91亚洲二区在线观看 | 亚洲日本乱码在线观看| 欧美日韩视频在线第一区| 韩国毛片一区二区三区| 亚洲精品免费播放| 2023国产精品| 欧美伦理影视网| 本田岬高潮一区二区三区| 免费在线观看精品| 亚洲乱码国产乱码精品精小说 | 亚洲电影一级黄| 国产日韩欧美精品电影三级在线| 色八戒一区二区三区| 国产精品一区二区无线| 天天操天天色综合| 亚洲美女少妇撒尿| 久久精品人人爽人人爽| 3751色影院一区二区三区| 99久久伊人精品| 亚洲激情中文1区| 不卡的av电影在线观看| 久久国产剧场电影| 伊人色综合久久天天人手人婷| 日韩视频在线永久播放| 欧美四级电影在线观看| 亚洲福利视频一区| 国产欧美视频一区二区| 欧美无乱码久久久免费午夜一区| 国产中文一区二区三区| 一区二区三区国产精品| 久久精品人人做人人综合| 欧美三级日韩三级| 国产999精品久久久久久绿帽| 亚洲成人激情av| 制服.丝袜.亚洲.中文.综合| 一本色道久久综合亚洲精品按摩| 久久99久久99精品免视看婷婷| 国产精品美女视频| 欧美一区二区三区在线观看视频| 不卡视频一二三四| 国产一区二区网址| 日精品一区二区三区| 亚洲裸体在线观看| 日韩一区二区在线免费观看| 91精品国产福利| 欧美亚洲一区二区在线观看| aaa亚洲精品| 国产一区二区伦理| 韩国v欧美v日本v亚洲v| 蜜臂av日日欢夜夜爽一区| 日日骚欧美日韩| 亚洲444eee在线观看| 亚洲一区二区三区四区五区黄| 中文字幕在线不卡一区二区三区 | 顶级嫩模精品视频在线看| 91麻豆精品国产91久久久久久久久 | 久久久久久久久久美女| 欧美成人精品二区三区99精品| 欧美剧在线免费观看网站| 91高清视频在线| 欧美日本不卡视频| 欧美日韩在线观看一区二区 | 91在线观看视频| 国产一区二区不卡| 国产一区久久久| 国产成人av影院| 极品瑜伽女神91| av在线不卡电影| 91在线视频网址| 95精品视频在线| 色av成人天堂桃色av| 91一区在线观看| 欧美精品日日鲁夜夜添| 日韩欧美一级精品久久| 精品剧情在线观看| 久久久精品免费免费| 欧美韩国日本不卡| 亚洲自拍都市欧美小说| 午夜日韩在线电影| 日本三级亚洲精品| 精一区二区三区| 成人黄色小视频| 成人黄页毛片网站| 91精品国产综合久久精品麻豆 | 久久99久久精品| 精品无人码麻豆乱码1区2区| 国产suv一区二区三区88区| 99久久精品国产一区| 欧美日韩在线免费视频| 精品裸体舞一区二区三区| 亚洲午夜久久久久久久久久久| 日韩中文字幕亚洲一区二区va在线 | 韩国精品免费视频| 成人黄色av电影| 欧美在线观看一区二区| 日韩欧美第一区| 欧美国产一区视频在线观看| 一区二区三国产精华液| 免费成人av在线播放| www.爱久久.com| 欧美另类变人与禽xxxxx| 国产日韩欧美高清| 亚洲成av人影院在线观看网| 狠狠色伊人亚洲综合成人| 99re成人精品视频| 6080国产精品一区二区| 精品福利在线导航| 视频一区二区中文字幕| 成人高清免费观看| 色综合久久综合网97色综合| 欧美岛国在线观看| 亚洲欧美另类久久久精品2019| 蜜臀av一级做a爰片久久| 91免费版pro下载短视频| 欧美精品一区二区久久久| 中文字幕一区二区三区蜜月| 免费av网站大全久久| 欧美日韩国产电影| 亚洲另类春色校园小说| 国产精品系列在线观看| 337p亚洲精品色噜噜狠狠| 国产精品女同互慰在线看| 国产一区二区免费视频| 欧美精品99久久久**| 亚洲你懂的在线视频| 成人伦理片在线| 久久精品免视看| 久久99精品久久久久久动态图| 欧洲日韩一区二区三区|