docstr: Unlike numpy we don't assume outputs of vectorize without signature are scalar.
docstr_tok: ["Unlike","numpy","we","do","n't","assume","outputs","of","vectorize","without","signature","are","scalar","."]
code: def test_vectorize_no_signature(self):
      """Unlike numpy we don't assume outputs of vectorize without signature are scalar."""
  
      def func(x):
          return full((5, 3), x)
  
      vec_func = vectorize(func)
  
      x = tensor("x", shape=(4,), dtype="float64")
      out = vec_func(x)
  
      assert out.type.ndim == 3
      test_x = np.array([1, 2, 3, 4])
      np.testing.assert_allclose(
          out.eval({x: test_x}),
          np.full((len(test_x), 5, 3), test_x[:, None, None]),
      )
  
file_path: pytensor/tests/tensor/test_functional.py
imports: import numpy
  import pytest
  from pytensor.graph.basic import equal_computations
  from pytensor.tensor import full, tensor
  from pytensor.tensor.functional import vectorize
  from pytensor.tensor.random.type import RandomGeneratorType
label_desc: Use image node_id 1 for calling the TestVectorize obj's underlying member method code with example usage: obj.test_vectorize_no_signature() and returns: full