Skip to content

Commit

Permalink
Update dot.py
Browse files Browse the repository at this point in the history
  • Loading branch information
YayaWeizz authored May 26, 2024
1 parent d3bd62c commit d694cd0
Showing 1 changed file with 5 additions and 2 deletions.
7 changes: 5 additions & 2 deletions dot.py
Original file line number Diff line number Diff line change
Expand Up @@ -581,7 +581,9 @@ def _newDotsXY(self, nDots):
newDots = np.random.uniform(-0.5, 0.5, size = (nDots, 2)) * self.fieldSize

return newDots


#updating the position of the dots for the square aparatus according to the direction of the movement

def getRandPosInSquareSide(self,sideNum):
xy = np.zeros((1, 2))
if sideNum==0:
Expand All @@ -598,7 +600,8 @@ def getRandPosInSquareSide(self,sideNum):
xy[:,1] = 0.5*self.fieldSize[1] #set y
return xy


# main for updating dots (also here is where the dot in circle are updated)

def _update_OutOfBoundXY(self, outofbounds):
nOutOfBounds = outofbounds.sum()
allDir = self._dotsDir[outofbounds];
Expand Down

0 comments on commit d694cd0

Please sign in to comment.