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

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

?? lsmtopology.cpp

?? amygdata的神經網絡算法源代碼
?? CPP
?? 第 1 頁 / 共 2 頁
字號:
/***************************************************************************                          lsmtopology.cpp  -  description                             -------------------    begin                : Wed Mar 30 2005    copyright            : (C) 2005 by Rudiger Koch    email                : rkoch@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 "lsmtopology.h"#include "spikeinput.h"#include "factory.h"#include "physicalproperties.h"#include "neuronproperties.h"#include "neuron.h"#include "spikingneuron.h"#include "inputneuron.h"#include "nconnector.h"#include "synapse.h"#include "synapseproperties.h"#include "utilities.h"#include "logging.h"#include <stdexcept>#include <cstdlib>namespace Amygdala {using namespace std;LSMTopology::LSMTopology(string name) :     Topology(name),    X(0), Y(0), Z(0),    lastInX(0), lastInY(0), lastInZ(0), lastInSide(0),    lastOutX(0), lastOutY(0), lastOutZ(0){}LSMTopology::~LSMTopology(){}Topology * LSMTopology::MakeInput(SpikeInput * sInput, unsigned int iNeurons){    if( X==0 || Y==0 || Z==0) throw runtime_error("No cube defined yet. Call MakeCube before attempting to create Input");    //TFactory * lsmInput = dynamic_cast<TFactory*> (Factory::GetRegistry().GetFactory("LSMTopology::Input"));    //if(!lsmInput) throw runtime_error("No LSMTopology::Input factory registered");    TopologyFactory<LSMTopology::Input> lsmInput;    Input* in = lsmInput("LSM Input");    input.push_back(in);        // Move the code that used to be in Input::MakeInput() to here since more than one Input    // object is now allowed.  Since we have to keep track of where input neurons have been added    // previously, it will be easier to do that here.    //in->MakeInput(sInput, X, Y, Z, iNeurons);    LOGGER(3, "Making Inputs");    unsigned int neuronCounter = 1;    unsigned int inputLocs = 2*X*Z + 2*Y*Z;    unsigned int totInputs = 0;        for (unsigned int i=0; i<input.size(); ++i) {        totInputs += input[i]->size();    }    totInputs += iNeurons;    if(totInputs > inputLocs)             throw runtime_error("Insufficient space for InputNeurons. Consider making the cube larger");        if (lastInSide == 0) {        int y=-1;        // distribute the InputNeurons alongside at the X-Z side of the cube (y == -1)        for(int x=lastInX; x < X; x++){            for(int z=lastInZ; z < Z; z++){                InputNeuron * inNrn = in->MakeInputNeuron(x, y, z);                sInput->AddNeuron(inNrn);                lastInZ = z;                if(++neuronCounter > iNeurons) return in;            }            lastInZ = 0;               lastInX = x;        }        lastInX = 0;        lastInZ = 0;        lastInSide = 1;    }        if (lastInSide == 1) {        int y=Y;        // distribute the InputNeurons alongside at the X-Z side of the cube (y == Y)        for(int x=lastInX; x < X; x++){            for(int z=lastInZ; z < Z; z++){                InputNeuron * inNrn = in->MakeInputNeuron(x, y, z);                sInput->AddNeuron(inNrn);                lastInZ = z;                if(++neuronCounter > iNeurons) return in;            }               lastInZ = 0;            lastInX = x;        }        lastInX = 0;        lastInZ = 0;        lastInSide = 2;    }        if (lastInSide == 2) {        // if there are still more input neurons        // distribute them alongside at the X-Y side of the cube (z == -1)        int z=-1;        for(int x=lastInX; x < X; x++){            for(int y=lastInY; y < Y; y++){                InputNeuron * inNrn = in->MakeInputNeuron(x, y, z);                sInput->AddNeuron(inNrn);                lastInY = y;                if(++neuronCounter > iNeurons) return in;            }               lastInY = 0;            lastInX = x;        }        lastInX = 0;        lastInSide = 3;    }        if (lastInSide == 3) {        // if there are still more input neurons        // distribute them alongside at the X-Y side of the cube (z == Z)        int z=Z;        for(int x=lastInX; x < X; x++){            for(int y=lastInY; y < Y; y++){                InputNeuron * inNrn = in->MakeInputNeuron(x, y, z);                sInput->AddNeuron(inNrn);                lastInY = y;                if(++neuronCounter > iNeurons) return in;            }               lastInY = 0;            lastInX = x;        }        lastInX = 0;        lastInSide = 4;    }        return in;}Topology * LSMTopology::MakeReadout(const string & nType, unsigned int oNeurons){    if( X==0 || Y==0 || Z==0) throw runtime_error("No cube defined yet. Call MakeCube before attempting to create Output");    TFactory * lsmOutput = dynamic_cast<TFactory*> (Factory::GetRegistry().GetFactory("LSMTopology::Output"));    if(!lsmOutput) throw runtime_error("No LSMTopology::Output factory registered");    Output* out = dynamic_cast<Output*> (lsmOutput->MakeTopology("LSM Output"));    output.push_back(out);        // Move the code that used to be in Output::MakeReadout() to here since more than one Output    // object is now allowed.  Since we have to keep track of where neurons have been added    // previously, it will be easier to do that here.    //out->MakeReadout(nType, X, Y, oNeurons);    LOGGER(3, "Making Outputs");    unsigned int neuronCounter = 1;    NFactory * nf =  dynamic_cast<NFactory*> (Factory::GetRegistry().GetFactory(nType));    if (nf == NULL) throw runtime_error("No neuron type " + nType + " registered!");    NeuronProperties * nProps = nf->MakeNeuronProperties(true);    PhysicalProperties * pProps = nProps->GetPhysicalProps();    // distribute the OutputNeurons alongside at the Y-Z side of the cube starting at X+1, 0, 0    for (int z=lastOutZ; true; z++){        for (int y = lastOutY; y < Y; y++){            pProps->SetPosition(X + 1, y, z);            Neuron * n = nf->MakeNeuron(Network::GetNetworkRef()->GetNewNeuronId(), nProps, out);            OutputManager::AddNeuronToGroup(n, OUTPUTGROUP);            LOGGER(4, "Output neuron at " << X+1 << ", " << y << ", " << z);            lastOutY++;            if(++neuronCounter > oNeurons) return out;        }        lastOutY=0;        lastOutZ++;    }        return out;}Topology * LSMTopology::MakeReadout(NFactory* nf, NeuronProperties* np, unsigned int oNeurons){    if( X==0 || Y==0 || Z==0) throw runtime_error("No cube defined yet. Call MakeCube before attempting to create Output");    TFactory * lsmOutput = dynamic_cast<TFactory*> (Factory::GetRegistry().GetFactory("LSMTopology::Output"));    if(!lsmOutput) throw runtime_error("No LSMTopology::Output factory registered");    Output* out = dynamic_cast<Output*> (lsmOutput->MakeTopology("LSM Output"));    output.push_back(out);        // Move the code that used to be in Output::MakeReadout() to here since more than one Output    // object is now allowed.  Since we have to keep track of where neurons have been added    // previously, it will be easier to do that here.    //out->MakeReadout(nType, X, Y, oNeurons);    LOGGER(3, "Making Outputs");    unsigned int neuronCounter = 1;    /*NFactory * nf =  dynamic_cast<NFactory*> (Factory::GetRegistry().GetFactory(nType));    if (nf == NULL) throw runtime_error("No neuron type " + nType + " registered!");*/    //NeuronProperties * nProps = nf->MakeNeuronProperties(true);    PhysicalProperties * pProps = np->GetPhysicalProps();    // distribute the OutputNeurons alongside at the Y-Z side of the cube starting at X+1, 0, 0    for (int z=lastOutZ; true; z++){        for (int y = lastOutY; y < Y; y++){            pProps->SetPosition(X + 1, y, z);            Neuron * n = nf->MakeNeuron(Network::GetNetworkRef()->GetNewNeuronId(), np, out);            OutputManager::AddNeuronToGroup(n, OUTPUTGROUP);            LOGGER(4, "Output neuron at " << X+1 << ", " << y << ", " << z);            lastOutY++;            if(++neuronCounter > oNeurons) return out;        }        lastOutY=0;        lastOutZ++;    }        return out;}void LSMTopology::MakeCube(const string & nType, unsigned int lx, unsigned int ly, unsigned int lz){    X=lx; Y=ly; Z=lz;    LOGGER(1, "Making Cube of size " << X << ", " << Y << ", " << Z);        NFactory * nf =  dynamic_cast<NFactory*> (Factory::GetRegistry().GetFactory(nType));    if (nf == NULL) throw runtime_error("No neuron type " + nType + " registered!");        NeuronProperties * nProps = nf->MakeNeuronProperties(true);    PhysicalProperties * pProps = nProps->GetPhysicalProps();        for (int x = 0; x < X; x++){

?? 快捷鍵說明

復制代碼 Ctrl + C
搜索代碼 Ctrl + F
全屏模式 F11
切換主題 Ctrl + Shift + D
顯示快捷鍵 ?
增大字號 Ctrl + =
減小字號 Ctrl + -
亚洲欧美第一页_禁久久精品乱码_粉嫩av一区二区三区免费野_久草精品视频
国产精品综合二区| 亚洲福利一区二区三区| 国产精品久久久一本精品| 3d动漫精品啪啪一区二区竹菊 | 色综合久久久久久久久久久| 精品一区二区精品| 高清不卡一区二区在线| 成人福利视频网站| 日本韩国精品在线| 日韩视频永久免费| 中文字幕一区二区三区视频| 国产精品成人网| 午夜av电影一区| 国产专区综合网| 欧美日韩一区二区三区在线看| 欧美日韩免费一区二区三区视频| 欧美三级在线播放| 久久久青草青青国产亚洲免观| 国产精品色在线| 亚洲影视在线观看| 国产一区二区日韩精品| 91网址在线看| 精品国产伦一区二区三区观看体验 | 污片在线观看一区二区| 国产精品亚洲第一| 色视频成人在线观看免| 久久免费国产精品| 日韩精彩视频在线观看| 成人黄色在线看| 精品少妇一区二区三区在线播放 | 亚洲一区二区三区四区中文字幕| 国产成a人无v码亚洲福利| 91福利小视频| 亚洲一区二区三区在线播放| 粉嫩av一区二区三区粉嫩| 欧美高清hd18日本| 偷偷要91色婷婷| 91精品国产一区二区三区香蕉| 国产精品欧美久久久久一区二区| 日本午夜一本久久久综合| 91片在线免费观看| 国产精品福利影院| 成人午夜电影小说| **网站欧美大片在线观看| 国产成人免费高清| 国产清纯美女被跳蛋高潮一区二区久久w| 亚洲综合999| 欧美一区二视频| 天堂蜜桃一区二区三区 | 欧美理论在线播放| 欧美一区二区网站| 亚洲va中文字幕| 欧美精品黑人性xxxx| 久久草av在线| 国产精品每日更新在线播放网址| 成av人片一区二区| 亚洲午夜激情av| 久久婷婷色综合| 99视频精品全部免费在线| 亚洲一区在线播放| 精品国产网站在线观看| 一本大道久久a久久综合| 日韩国产一区二| 国产精品视频线看| 在线不卡欧美精品一区二区三区| 91在线免费看| 久草中文综合在线| 国产精品无码永久免费888| 麻豆91在线观看| 国产精品免费观看视频| 91精品国产美女浴室洗澡无遮挡| 成人夜色视频网站在线观看| 蜜臀久久久久久久| 亚洲嫩草精品久久| 精品第一国产综合精品aⅴ| 波多野结衣在线aⅴ中文字幕不卡| 亚洲高清不卡在线观看| 国产视频不卡一区| 欧美变态tickle挠乳网站| 欧美日韩综合在线| 欧美日韩美女一区二区| 91视频在线观看| 国产精品一区二区久久不卡| 一区二区高清视频在线观看| 国产精品污网站| 国产精品欧美久久久久无广告| 一区二区中文视频| 一区二区免费看| 亚洲图片自拍偷拍| 亚洲永久免费av| 亚洲精品国产一区二区三区四区在线| 亚洲国产精品t66y| 国产精品久99| 中文乱码免费一区二区| 欧美国产日韩亚洲一区| 久久久久国产精品麻豆ai换脸| 国产女同性恋一区二区| 亚洲日本护士毛茸茸| 久久久99久久| 国产精品网曝门| 首页国产欧美久久| 国产伦精品一区二区三区免费 | 国产a视频精品免费观看| 欧美亚洲高清一区| 日韩免费观看高清完整版| 国产日韩精品视频一区| 一区二区三区免费观看| 国内成人精品2018免费看| 不卡的av电影在线观看| 欧美日韩日日夜夜| 欧美成人a∨高清免费观看| 中文字幕免费一区| 国产精品久久久久三级| 夜夜嗨av一区二区三区四季av| 亚洲国产精品久久不卡毛片 | 蜜臀a∨国产成人精品| 99视频一区二区| 国产视频一区二区在线观看| 亚洲成a人v欧美综合天堂下载| 久久国产福利国产秒拍| 97精品国产97久久久久久久久久久久| 欧美一级日韩免费不卡| 亚洲精品国产第一综合99久久| 国产精品一级黄| 精品国产麻豆免费人成网站| 麻豆91免费看| 日韩视频在线观看一区二区| 日韩综合一区二区| 欧美三级电影在线观看| 天天操天天色综合| 欧美狂野另类xxxxoooo| 亚洲福利一区二区三区| 91啪在线观看| 一区二区三区不卡在线观看 | 日韩一区二区免费高清| 美女视频免费一区| 欧美成人性福生活免费看| 韩国午夜理伦三级不卡影院| 中文字幕欧美日本乱码一线二线 | 欧美日产在线观看| 久久se精品一区二区| 国产偷国产偷精品高清尤物| 色猫猫国产区一区二在线视频| 亚洲制服欧美中文字幕中文字幕| 在线观看日韩一区| 亚洲国产精品一区二区久久恐怖片| 欧美午夜视频网站| 成人国产精品免费网站| 亚洲日本青草视频在线怡红院| 成人动漫中文字幕| 亚洲黄色在线视频| 欧美岛国在线观看| 99久久精品99国产精品| 天天做天天摸天天爽国产一区| 欧美一区二区免费视频| 国产成人精品亚洲日本在线桃色| 久久精品一区蜜桃臀影院| 成人激情综合网站| 天堂va蜜桃一区二区三区漫画版| 日韩西西人体444www| 欧美伊人久久久久久午夜久久久久| 激情图片小说一区| 天堂一区二区在线| 亚洲品质自拍视频网站| 久久精品人人做人人综合 | 国产精品私房写真福利视频| 久久这里只有精品视频网| 正在播放一区二区| 91蜜桃网址入口| av在线免费不卡| 99久久99久久久精品齐齐| 狠狠狠色丁香婷婷综合久久五月| 日本亚洲天堂网| 日韩电影在线观看一区| 亚洲成人av资源| 亚洲免费av观看| 久久精品日产第一区二区三区高清版| 日韩一区二区三区视频在线| 7777精品伊人久久久大香线蕉的 | 精品日韩99亚洲| 精品国精品自拍自在线| 精品久久久久久久久久久久包黑料| 欧美一二三区精品| 精品国产麻豆免费人成网站| 日韩一区二区三免费高清| 91精品国产综合久久久久久久| 欧美日韩一区二区三区四区| 欧美日韩电影在线| 久久这里只有精品首页| 亚洲美女在线国产| 婷婷丁香激情综合| 国精产品一区一区三区mba视频| 精品一区二区av| 国产成人免费视| 97精品超碰一区二区三区| 欧美综合色免费| 欧美一区二区免费观在线| 国产亚洲欧洲997久久综合| 亚洲无人区一区| www.色综合.com|