class_docstr: Related to minibatch training
class_docstr_tok: ["Related","to","minibatch","training"]
code: def test_density_scaling(self):
      with pm.Model() as model1:
          pm.Normal("n", observed=[[1]], total_size=1)
          p1 = pytensor.function([], model1.logp())
  
      with pm.Model() as model2:
          pm.Normal("n", observed=[[1]], total_size=2)
          p2 = pytensor.function([], model2.logp())
      assert p1() * 2 == p2()
  
file_path: pymc/tests/variational/test_minibatch_rv.py
imports: import numpy
  import pytensor
  import pytest
  from scipy import stats
  import pymc
  from pymc import Normal, draw
  from pymc.data import minibatch_index
  from pymc.testing import select_by_precision
  from pymc.variational.minibatch_rv import create_minibatch_rv
  from tests.test_data import gen1, gen2
label_desc: Use image node_id 1 for calling the TestMinibatchRandomVariable obj's underlying member method code with example usage: obj.test_density_scaling() without return types