def test_two_dim_odd_input_axis_0(self):
    x = np.array([[-1., 50., -3.5, 2., -1], [0., 0., 3., 2., 4.]]).T
    for q in [0, 10, 25, 49.9, 50, 50.01, 90, 95, 100]:
      expected_percentile = np.percentile(
          x, q=q, interpolation=self._interpolation, axis=0)
      with self.test_session():
        # Get dim 1 with negative and positive indices.
        pct_neg_index = sample_stats.percentile(
            x, q=q, interpolation=self._interpolation, axis=[0])
        pct_pos_index = sample_stats.percentile(
            x, q=q, interpolation=self._interpolation, axis=[0])
        self.assertAllEqual((2,), pct_neg_index.get_shape())
        self.assertAllEqual((2,), pct_pos_index.get_shape())
        self.assertAllClose(expected_percentile, pct_neg_index.eval())
        self.assertAllClose(expected_percentile, pct_pos_index.eval())