code: def test_invalid_jacobian_broadcast_raises():
      class BuggyTransform(Transform):
          name = "buggy"
  
          def forward(self, value, *inputs):
              return value
  
          def backward(self, value, *inputs):
              return value
  
          def log_jac_det(self, value, *inputs):
              return pt.zeros_like(value.sum(-1, keepdims=True))
  
      buggy_transform = BuggyTransform()
  
      with pm.Model() as m:
          pm.Uniform("x", shape=(4, 3), transform=buggy_transform)
  
      for jacobian_val in (True, False):
          with pytest.raises(
              ValueError,
              match="are not allowed to broadcast together. There is a bug in the implementation of either one",
          ):
              m.logp(jacobian=jacobian_val)
  
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 26 for calling a global function with example usage: test_invalid_jacobian_broadcast_raises() and returns: value, value, pt