[Pybrainsim-activity] SF.net SVN: pybrainsim:[68] trunk/src/Stimulus.py
Status: Planning
Brought to you by:
rgoj
From: <rg...@us...> - 2009-08-03 17:01:03
|
Revision: 68 http://pybrainsim.svn.sourceforge.net/pybrainsim/?rev=68&view=rev Author: rgoj Date: 2009-08-03 17:00:55 +0000 (Mon, 03 Aug 2009) Log Message: ----------- * Correcting mistake: a generator must return it's activation from the runGenerator method * Correcting mistake: after the end of stimuli in stimulusList the activation would remain unchanged, thus always stimulating the connected generator * Changing message printed by the runGenerator method Modified Paths: -------------- trunk/src/Stimulus.py Modified: trunk/src/Stimulus.py =================================================================== --- trunk/src/Stimulus.py 2009-08-03 16:55:34 UTC (rev 67) +++ trunk/src/Stimulus.py 2009-08-03 17:00:55 UTC (rev 68) @@ -38,14 +38,14 @@ def runGenerator(self, time): if self.currentStimulus < len(self.stimulusTimes): - if self.stimulusTimes[self.currentStimulus] < time: - print("Stimulus now: BEEEEEEEP! ... Time is: " + str(time) + ", Stimulus list is: " + str(self.stimulusTimes) + " Connected generator phase should have been: " + str(self.connectedGeneratorPhase)) + if self.stimulusTimes[self.currentStimulus] <= time: + print("Stimulus now: BEEEEEEEP! ... Time is: " + str(time) + ", Stimulus list is: " + str(self.stimulusTimes)) self.currentStimulus += 1 - self.activation = 'Stimulus' else: - self.activation = None + self.activation = 0 + else: + self.activation = 0 - # The runGenerator method must return a value - return 0 + return self.activation This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site. |