code: def test_ndiagquad_does_not_throw_error() -> None:
      """
      Check that the autograph=False for quadrature.ndiagquad does not throw an error.
      Regression test for https://github.com/GPflow/GPflow/issues/1547.
      """
  
      @tf.function(autograph=False)
      def func_ndiagquad_autograph_false() -> tf.Tensor:
          mu: AnyNDArray = np.array([1.0, 1.3])
          var: AnyNDArray = np.array([3.0, 3.5])
          num_gauss_hermite_points = 25
          return quadrature.ndiagquad(
              [lambda *X: tf.exp(X[0])],
              num_gauss_hermite_points,
              [mu],
              [var],
          )
  
      func_ndiagquad_autograph_false()
  
file_path: GPflow/tests/gpflow/quadrature/test_quadrature.py
imports: from typing import cast
  import numpy
  import pytest
  import tensorflow
  from numpy.testing import assert_allclose
  import gpflow.quadrature
  from gpflow.base import AnyNDArray, TensorType
label_desc: Use image node_id 5 for calling a global function with example usage: test_ndiagquad_does_not_throw_error() and returns: quadrature