code: def chooseReliableActiveFiringRate(cellsPerAxis, bumpSigma,
                                       minimumActiveDiameter=None):
      
      firingFieldDiameter = 2 * (1./cellsPerAxis)*(2./math.sqrt(3))
  
      if minimumActiveDiameter:
        firingFieldDiameter = max(firingFieldDiameter, minimumActiveDiameter)
  
      return ThresholdedGaussian2DLocationModule.gaussian(
        bumpSigma, firingFieldDiameter / 2.)
docs: When a cell is activated by sensory input, this implies that the phase is
      within a particular small patch of the rhombus. This patch is roughly
      equivalent to a circle of diameter (1/cellsPerAxis)(2/sqrt(3)), centered on
      the cell. This 2/sqrt(3) accounts for the fact that when circles are packed
      into hexagons, there are small uncovered spaces between the circles, so the
      circles need to expand by a factor of (2/sqrt(3)) to cover this space.
  
      This sensory input will activate the phase at the center of this cell. To
      account for uncertainty of the actual phase that was used during learning,
      the bump of active cells needs to be sufficiently large for this cell to
      remain active until the bump has moved by the above diameter. So the
      diameter of the bump (and, equivalently, the cell's firing field) needs to
      be at least 2 of the above diameters.
  
      @param minimumActiveDiameter (float or None)
      If specified, this makes sure the bump of active cells is always above a
      certain size. This is useful for testing scenarios where grid cell modules
      can only encode location with a limited "readout resolution", matching the
      biology.
  
      @return
      An "activeFiringRate" for use in the ThresholdedGaussian2DLocationModule.