code: def test_sum_to_1():
      check_vector_transform(tr.sum_to_1, Simplex(2))
      check_vector_transform(tr.sum_to_1, Simplex(4))
  
      with pytest.warns(
          FutureWarning, match="ndim_supp argument is deprecated"
      ):
          tr.SumTo1(2)
  
      check_jacobian_det(
          tr.sum_to_1,
          Vector(Unit, 2),
          pt.vector,
          floatX(np.array([0, 0])),
          lambda x: x[:-1],
      )
      check_jacobian_det(
          tr.multivariate_sum_to_1,
          Vector(Unit, 2),
          pt.vector,
          floatX(np.array([0, 0])),
          lambda x: x[:-1],
      )
  
imports: import numpy
  import pytensor
  import pytensor.tensor
  import pytest
  from numpy.testing import assert_allclose, assert_array_equal
  from pytensor.tensor.variable import TensorConstant
  import pymc
  import pymc.distributions.transforms
  from pymc.logprob.basic import transformed_conditional_logp
  from pymc.logprob.transforms import Transform
  from pymc.pytensorf import floatX, jacobian
  from pymc.testing import Circ, MultiSimplex, R, Rminusbig, Rplusbig, Simplex, SortedVector, Unit, UnitSortedVector, Vector
label_desc: Use image node_id 8 for calling a global function with example usage: test_sum_to_1() without return types