code: def _hurwitz_zeta(x, q, tolerance):
      """The Hurwitz zeta function, or the Riemann zeta function of two arguments.
  
      ``x`` must be greater than one and ``q`` must be positive.
  
      This function repeatedly computes subsequent partial sums until
      convergence, as decided by ``tolerance``.
      """
      z = 0
      z_prev = -float("inf")
      k = 0
      while abs(z - z_prev) > tolerance:
          z_prev = z
          z += 1 / ((k + q) ** x)
          k += 1
      return z
  
file_path: networkx/networkx/generators/community.py
imports: import itertools
  import math
  import networkx
  from networkx.utils import py_random_state
label_desc: Use image node_id 12 for calling a global function with example usage: _hurwitz_zeta(x, q, tolerance) and returns: z