code: def df(self, y, f):
          r
          y, f = np.broadcast_arrays(y, f)
          if self.tranfcn == 'exp':
              return y - np.exp(f)
          else:
              return expit(f) * (y / safesoftplus(f) - 1)
docs: r"""
          Derivative of Poisson log likelihood w.r.t.\  f.
  
          Parameters
          ----------
          y: ndarray
              array of 0, 1 valued integers of targets
          f: ndarray
              latent function from the GLM prior (:math:`\mathbf{f} =
              \boldsymbol\Phi \mathbf{w}`)
  
          Returns
          -------
          df: ndarray
              the derivative :math:`\partial \log p(y|f) / \partial f`