code: def testMean(self, dist):
      loc, scale, conc = self.evaluate(
          [dist.loc, dist.scale, dist.concentration]
      )
      hp.note(
          "Location: {}, scale: {}, concentration: {}".format(
              loc, scale, conc
          )
      )
      self.assertEqual(dist.batch_shape, dist.mean().shape)
      # scipy doesn't seem to be very accurate for small concentrations, so use
      # higher precision.
      expected = sp_stats.genpareto(
          np.float64(conc), loc=np.float64(loc), scale=np.float64(scale)
      ).mean()
      actual = self.evaluate(dist.mean())
      # There is an unavoidable catastropic cancellation for means near 0
      self.assertAllClose(expected, actual, rtol=5e-4, atol=1e-4)
  
imports: import hypothesis
  import hypothesis.strategies
  import numpy
  from scipy import stats
  import tensorflow.compat.v2
  from tensorflow_probability.python.distributions import generalized_pareto
  from tensorflow_probability.python.internal import hypothesis_testlib
  from tensorflow_probability.python.internal import test_util
  from tensorflow_probability.python.math import gradient
label_desc: Use image node_id 7 for calling the GeneralizedParetoTest obj's underlying member method code with example usage: obj.testMean(dist) without return types