
#include <Neuro/Brain.H>
Inheritance diagram for Brain:


It contains a retina (input image), a VisualCortex, a SaliencyMap, a WinnerTakeAll, a visual field (image that keeps track of attended locations), and lots of interconnections between those.
Definition at line 76 of file Brain.H.
Public Member Functions | |
| nub::ref< PrefrontalCortex > | getPFC () const |
| Get the PFC. | |
| nub::ref< Retina > | getRET () const |
| Get the Retina. | |
| nub::ref< VisualCortex > | getVC () const |
| Get the VisualCortex. | |
| nub::ref< EyeHeadController > | getEHC () const |
| Get the EyeHeadController. | |
| nub::ref< SimulationViewer > | getSV () const |
| Get the SimulationViewer. | |
| nub::ref< ShapeEstimator > | getSE () const |
| Get the ShapeEstimator. | |
| nub::ref< SaliencyMap > | getSM () const |
| Get the SaliencyMap. | |
| nub::ref< TaskRelevanceMap > | getTRM () const |
| Get the TaskRelevanceMap. | |
| nub::ref< AttentionGuidanceMap > | getAGM () const |
| Get the AttentionGuidanceMap. | |
| nub::ref< AttentionGate > | getAG () const |
| Get the AttentionGate. | |
| nub::ref< WinnerTakeAll > | getWTA () const |
| Get the WinnerTakeAll. | |
| nub::ref< InferoTemporal > | getIT () const |
| Get the InferoTemporal. | |
| nub::ref< GistEstimator > | getGE () const |
| Get the GistEstimator. | |
| nub::ref< TargetChecker > | getTC () const |
| Get the TargetChecker. | |
| nub::ref< RetinaToWorld > | getRTW () const |
| Get the RetinaToWorld. | |
| void | drawResults (Image< PixRGB< byte > > &traj, const Rectangle &foa) |
| Pass along to our subcomponents (VisualCortex in particular). | |
Constructors, destructors, and run-time "modules" | |
Typically, you instantiate a IRoomBrain and then add various plug-in "modules" to it (using setRET(), setVC(), etc.). If you decide so, each module you add may become a subcomponent of your IRoomBrain object; if so, you should not do a ModelManager::addSubComponent() on them, but just do it once for all on your IRoomBrain object instead. | |
| Brain (OptionManager &mgr, const std::string &descrName="Brain", const std::string &tagName="Brain") | |
| Constructor. | |
| virtual | ~Brain () |
| Virtual destructor for safe inheritance. | |
Module setters | |
Each call takes a reference to an appropriate ModelComponent derivative object, which must furthermore be the appropriate specific derived type for the module type. Each call takes a boolean parameter 'makeSubComp'. If true, the object passed as argument will become a subcomponent of us, thus you will not need to separately register it with ModelManager. Yields a fatal error if we already have one module of that type (name). Typically, you want to set this flag to true in models where the Brain is your top-level (root) component; in models that contains objects for whom the Brain is a subcomponent, typically they will also have our modules as subcomponents, so we should not set this flag to true
HISTORICAL NOTE: For now, these replace the old addModule() function -- the reason was that everybody who called addModule() was doing it with a type known at compile time (i.e., they called it with a literal "VisualCortex" string and a nub::soft_ref<VisualCortex>), so it's more straightforward to just have separate functions for each type. This approach also avoids a round of up+down casting (with addModule, you might have a VisualCortex object, which then got casted to ModuleComponent for the addModule() call, only to be dynamic-casted back to VisualCortex inside addModule()). If, in the future, we end up with a system in which Brain doesn't need to know the actual types of all its modules (e.g., it just has a bag of BrainModule objects), then it could make sense to go back to the addModule() system. | |
| void | setPFC (nub::ref< PrefrontalCortex > mod, bool makeSubComp=false) |
| Set the PrefrontalCortex. | |
| void | setRET (nub::ref< Retina > mod, bool makeSubComp=false) |
| Set the Retina. | |
| void | setVC (nub::ref< VisualCortex > mod, bool makeSubComp=false) |
| Set the VisualCortex. | |
| void | setEHC (nub::ref< EyeHeadController > mod, bool makeSubComp=false) |
| Set the EyeHeadController. | |
| void | setSV (nub::ref< SimulationViewer > mod, bool makeSubComp=false) |
| Set the SimulationViewer. | |
| void | setSE (nub::ref< ShapeEstimator > mod, bool makeSubComp=false) |
| Set the ShapeEstimator. | |
| void | setSM (nub::ref< SaliencyMap > mod, bool makeSubComp=false) |
| Set the SaliencyMap. | |
| void | setTRM (nub::ref< TaskRelevanceMap > mod, bool makeSubComp=false) |
| Set the TaskRelevanceMap. | |
| void | setAGM (nub::ref< AttentionGuidanceMap > mod, bool makeSubComp=false) |
| Set the AttentionGuidanceMap. | |
| void | setAG (nub::ref< AttentionGate > mod, bool makeSubComp=false) |
| Set the AttentionGate. | |
| void | setWTA (nub::ref< WinnerTakeAll > mod, bool makeSubComp=false) |
| Set the WinnerTakeAll. | |
| void | setIT (nub::ref< InferoTemporal > mod, bool makeSubComp=false) |
| Set the InferoTemporal. | |
| void | setGE (nub::ref< GistEstimator > mod, bool makeSubComp=false) |
| Set the GistEstimator. | |
| void | setTC (nub::ref< TargetChecker > mod, bool makeSubComp=false) |
| Set the TargetChecker. | |
| void | setRTW (nub::ref< RetinaToWorld > mod, bool makeSubComp=false) |
| Set the RetinaToWorld. | |
Brain simulation functions | |
| void | setTargetMask (const Image< byte > &targets) |
| Specify a target mask. | |
| void | input (const Image< PixRGB< byte > > &inp, nub::soft_ref< SimEventQueue > q) |
| Load a new frame and pass it through visual cortex. | |
| virtual void | evolve (SimEventQueue &q) |
| Evolve all of our modules. | |
| SimStatus | evolve (bool useLowMem) |
| Evolve all of our modules. | |
Protected Member Functions | |
| virtual void | start1 () |
| do some additional config at start time; see ModelComponent.H | |
Classes | |
| struct | Impl |
| Private implementation struct for Brain. More... | |
|
||||||||||||||||
|
Constructor.
Definition at line 122 of file Brain.C. References ModelComponent::addSubComponent(), Brain::Impl::AG, Brain::Impl::AGM, Brain::Impl::EHC, Brain::Impl::GE, Brain::Impl::IT, Brain::Impl::PFC, Brain::Impl::RET, Brain::Impl::RTW, Brain::Impl::SE, Brain::Impl::SM, Brain::Impl::SV, Brain::Impl::TC, Brain::Impl::TRM, Brain::Impl::VC, and Brain::Impl::WTA. |
|
|
Virtual destructor for safe inheritance.
|
|
||||||||||||
|
Pass along to our subcomponents (VisualCortex in particular).
Definition at line 386 of file Brain.C. References Brain::Impl::VC. Referenced by SimulationViewerStd::attentionShift(), and SimulationViewerNerdCam::attentionShift(). |
|
|
Evolve all of our modules.
|
|
|
Evolve all of our modules.
Implements SimModule. Definition at line 331 of file Brain.C. References Brain::Impl::AG, Brain::Impl::AGM, Brain::Impl::EHC, Brain::Impl::GE, Brain::Impl::IT, Brain::Impl::PFC, Brain::Impl::RET, Brain::Impl::RTW, Brain::Impl::SE, Brain::Impl::SM, Brain::Impl::SV, Brain::Impl::TC, Brain::Impl::TRM, Brain::Impl::VC, and Brain::Impl::WTA. Referenced by GetSaliency::compute(). |
|
|
Get the AttentionGate.
Definition at line 310 of file Brain.C. References Brain::Impl::AG. Referenced by start1(). |
|
|
Get the AttentionGuidanceMap.
Definition at line 309 of file Brain.C. References Brain::Impl::AGM. Referenced by Brain_Init(). |
|
|
Get the EyeHeadController.
Definition at line 304 of file Brain.C. References Brain::Impl::EHC. Referenced by Brain_Init(), and SimulationViewerEyeSim::start1(). |
|
|
Get the GistEstimator.
Definition at line 313 of file Brain.C. References Brain::Impl::GE. Referenced by Brain_Init(). |
|
|
Get the InferoTemporal.
Definition at line 312 of file Brain.C. References Brain::Impl::IT. Referenced by Brain_Init(), and start1(). |
|
|
Get the PFC.
Definition at line 301 of file Brain.C. References Brain::Impl::PFC. |
|
|
Get the Retina.
Definition at line 302 of file Brain.C. References Brain::Impl::RET. Referenced by Brain_Init(), VisualBuffer::bufferToRetinal(), SimulationViewerEyeMvt2::eyeStatus(), SimulationViewerCompress::getTraj(), and VisualBuffer::retinalToBuffer(). |
|
|
Get the RetinaToWorld.
Definition at line 315 of file Brain.C. References Brain::Impl::RTW. |
|
|
Get the ShapeEstimator.
Definition at line 306 of file Brain.C. References Brain::Impl::SE. Referenced by Brain_Init(), and start1(). |
|
|
Get the SaliencyMap.
Definition at line 307 of file Brain.C. References Brain::Impl::SM. Referenced by Brain_Init(). |
|
|
Get the SimulationViewer.
Definition at line 305 of file Brain.C. References Brain::Impl::SV. Referenced by Brain_Init(), and start1(). |
|
|
Get the TargetChecker.
Definition at line 314 of file Brain.C. References Brain::Impl::TC. |
|
|
Get the TaskRelevanceMap.
Definition at line 308 of file Brain.C. References Brain::Impl::TRM. Referenced by Brain_Init(). |
|
|
|
Get the WinnerTakeAll.
Definition at line 311 of file Brain.C. References Brain::Impl::WTA. Referenced by Brain_Init(). |
|
||||||||||||
|
Load a new frame and pass it through visual cortex. This will yield a new input to the saliency map.
Definition at line 324 of file Brain.C. References LFATAL. Referenced by Brain_Init(). |
|
||||||||||||
|
Set the AttentionGate.
Definition at line 245 of file Brain.C. References ModelComponent::addSubComponent(), Brain::Impl::AG, and ModelComponent::removeSubComponent(). |
|
||||||||||||
|
Set the AttentionGuidanceMap.
Definition at line 236 of file Brain.C. References ModelComponent::addSubComponent(), Brain::Impl::AGM, and ModelComponent::removeSubComponent(). Referenced by Brain_Init(), and StdBrain::start1(). |
|
||||||||||||
|
Set the EyeHeadController.
Definition at line 191 of file Brain.C. References ModelComponent::addSubComponent(), Brain::Impl::EHC, and ModelComponent::removeSubComponent(). Referenced by Brain_Init(), and StdBrain::start1(). |
|
||||||||||||
|
Set the GistEstimator.
Definition at line 272 of file Brain.C. References ModelComponent::addSubComponent(), Brain::Impl::GE, and ModelComponent::removeSubComponent(). Referenced by Brain_Init(), and StdBrain::start1(). |
|
||||||||||||
|
Set the InferoTemporal.
Definition at line 263 of file Brain.C. References ModelComponent::addSubComponent(), Brain::Impl::IT, and ModelComponent::removeSubComponent(). Referenced by Brain_Init(), and StdBrain::start1(). |
|
||||||||||||
|
Set the PrefrontalCortex.
Definition at line 165 of file Brain.C. References ModelComponent::addSubComponent(), Brain::Impl::PFC, and ModelComponent::removeSubComponent(). Referenced by StdBrain::start1(). |
|
||||||||||||
|
Set the Retina.
Definition at line 174 of file Brain.C. References ModelComponent::addSubComponent(), ModelComponent::removeSubComponent(), and Brain::Impl::RET. Referenced by Brain_Init(), and StdBrain::start1(). |
|
||||||||||||
|
Set the RetinaToWorld.
Definition at line 290 of file Brain.C. References ModelComponent::addSubComponent(), ModelComponent::removeSubComponent(), and Brain::Impl::RTW. |
|
||||||||||||
|
Set the ShapeEstimator.
Definition at line 209 of file Brain.C. References ModelComponent::addSubComponent(), ModelComponent::removeSubComponent(), and Brain::Impl::SE. Referenced by Brain_Init(). |
|
||||||||||||
|
Set the SaliencyMap.
Definition at line 218 of file Brain.C. References ModelComponent::addSubComponent(), ModelComponent::removeSubComponent(), and Brain::Impl::SM. Referenced by Brain_Init(), and StdBrain::start1(). |
|
||||||||||||
|
Set the SimulationViewer.
Definition at line 200 of file Brain.C. References ModelComponent::addSubComponent(), ModelComponent::removeSubComponent(), and Brain::Impl::SV. Referenced by Brain_Init(), and StdBrain::start1(). |
|
|
Specify a target mask.
Definition at line 318 of file Brain.C. References Brain::Impl::TC. Referenced by Brain_Init(). |
|
||||||||||||
|
Set the TargetChecker.
Definition at line 281 of file Brain.C. References ModelComponent::addSubComponent(), ModelComponent::removeSubComponent(), and Brain::Impl::TC. |
|
||||||||||||
|
Set the TaskRelevanceMap.
Definition at line 227 of file Brain.C. References ModelComponent::addSubComponent(), ModelComponent::removeSubComponent(), and Brain::Impl::TRM. Referenced by Brain_Init(), and StdBrain::start1(). |
|
||||||||||||
|
Set the VisualCortex.
Definition at line 182 of file Brain.C. References ModelComponent::addSubComponent(), ModelComponent::removeSubComponent(), and Brain::Impl::VC. Referenced by Brain_Init(), and StdBrain::start1(). |
|
||||||||||||
|
Set the WinnerTakeAll.
Definition at line 254 of file Brain.C. References ModelComponent::addSubComponent(), ModelComponent::removeSubComponent(), and Brain::Impl::WTA. Referenced by Brain_Init(), and StdBrain::start1(). |
|
|
do some additional config at start time; see ModelComponent.H
Reimplemented from ModelComponent. Reimplemented in StdBrain. Definition at line 155 of file Brain.C. References getAG(), getIT(), getSE(), and getSV(). Referenced by StdBrain::start1(). |
1.4.4