code: def test_normal_expected_improvement(self):
      shape = [5, 1, 20]
      loc = 2.0 * np.ones(shape, dtype=self.dtype)
      stddev = 3.0
      observations = np.array([2.0, 3.0, 4.0]).astype(self.dtype)
      best_observed = tf.reduce_max(observations)
      exploration = 0.8
      actual_ei = expected_improvement.normal_expected_improvement(
          best_observed=best_observed,
          mean=loc,
          stddev=stddev,
          exploration=exploration,
      )
  
      norm = normal.Normal(self.dtype(0.0), 1.0)
      imp = loc - best_observed - exploration
      z = imp / stddev
      expected_ei = imp * norm.cdf(z) + stddev * norm.prob(z)
      self.assertAllEqual(actual_ei.shape, shape)
      self.assertAllClose(actual_ei, expected_ei)
      self.assertDTypeEqual(actual_ei, self.dtype)
  
imports: import numpy
  import tensorflow.compat.v2
  from tensorflow_probability.python.distributions import gaussian_process_regression_model
  from tensorflow_probability.python.distributions import normal
  from tensorflow_probability.python.distributions import student_t
  from tensorflow_probability.python.distributions import student_t_process_regression_model
  from tensorflow_probability.python.experimental.bayesopt.acquisition import expected_improvement
  from tensorflow_probability.python.internal import test_util
  from tensorflow_probability.python.math import gradient
  from tensorflow_probability.python.math.psd_kernels import exponentiated_quadratic
label_desc: Use image node_id 1 for calling the _ExpectedImprovementTest obj's underlying member method code with example usage: obj.test_normal_expected_improvement() without return types