code: def test_to_simplex_1d(self):
      with self.test_session():
          x = tf.constant([0.0])
          self.assertAllClose(to_simplex(x).eval(), [0.5, 0.5])
          x = tf.constant([0.0, 10.0])
          self.assertAllClose(
              to_simplex(x).eval(),
              [3.333333e-01, 6.666363e-01, 3.027916e-05],
          )
  
file_path: edward/tests/util/to_simplex_test.py
imports: from __future__ import absolute_import
  from __future__ import division
  from __future__ import print_function
  import numpy
  import tensorflow
  from edward.util import to_simplex
label_desc: Use image node_id 1 for calling the test_to_simplex_class obj's underlying member method code with example usage: obj.test_to_simplex_1d() without return types