code: def testHalfNormalSurvivalFunction(self):
      batch_size = 50
      scale = self._rng.rand(batch_size) + 1.0
      x = np.linspace(-8.0, 8.0, batch_size).astype(np.float64)
      halfnorm = half_normal.HalfNormal(
          scale=scale, validate_args=False
      )
  
      sf = halfnorm.survival_function(x)
      self._testBatchShapes(halfnorm, sf)
  
      log_sf = halfnorm.log_survival_function(x)
      self._testBatchShapes(halfnorm, log_sf)
  
      expected_logsf = sp_stats.halfnorm(scale=scale).logsf(x)
      self.assertAllClose(expected_logsf, self.evaluate(log_sf), atol=0)
      self.assertAllClose(
          np.exp(expected_logsf), self.evaluate(sf), atol=0
      )
  
imports: from absl.testing import parameterized
  import numpy
  from scipy import stats
  import tensorflow.compat.v1
  import tensorflow.compat.v2
  from tensorflow_probability.python.distributions import half_normal
  from tensorflow_probability.python.distributions import kullback_leibler
  from tensorflow_probability.python.internal import test_util
  from tensorflow_probability.python.math import gradient
label_desc: Use image node_id 12 for calling the HalfNormalTest obj's underlying member method code with example usage: obj.testHalfNormalSurvivalFunction() without return types