code: def test_eight_schools_large_sample(posterior):
      num_chains, num_samples = 2, 200
      fit = posterior.sample(
          num_chains=num_chains,
          num_samples=num_samples,
          num_warmup=num_samples,
      )
      num_flat_params = schools_data["J"] * 2 + 2
      assert fit._draws.shape == (
          len(fit.sample_and_sampler_param_names) + num_flat_params,
          num_samples,
          num_chains,
      )
      df = fit.to_frame()
      assert "eta.1" in df.columns
      assert len(df["eta.1"]) == num_samples * num_chains
      assert fit["eta"].shape == (
          schools_data["J"],
          num_chains * num_samples,
      )
  
imports: import pytest
  import stan
label_desc: Use image node_id 2 for calling a global function with example usage: test_eight_schools_large_sample(posterior) without return types