code: def test_overdispersed_asymptote(probs, overdispersion):
      total_count = 100000
  
      # Check binomial_dist converges in distribution to LogitNormal.
      d1 = binomial_dist(total_count, probs)
      d2 = dist.TransformedDistribution(
          dist.Normal(math.log(probs / (1 - probs)), overdispersion),
          SigmoidTransform(),
      )
  
      # CRPS is equivalent to the Cramer-von Mises test.
      # https://en.wikipedia.org/wiki/Cram%C3%A9r%E2%80%93von_Mises_criterion
      k = torch.arange(0.0, total_count + 1.0)
      cdf1 = d1.log_prob(k).exp().cumsum(-1)
      cdf2 = d2.cdf(k / total_count)
      crps = (cdf1 - cdf2).pow(2).mean()
      assert crps < 0.02
  
imports: import math
  import pytest
  import torch
  from torch.distributions.transforms import SigmoidTransform
  import pyro.distributions
  from pyro.contrib.epidemiology import beta_binomial_dist, binomial_dist, infection_dist
  from pyro.contrib.epidemiology.distributions import _RELAX_MIN_VARIANCE, set_relaxed_distributions
  from tests.common import assert_close
label_desc: Use image node_id 7 for calling a global function with example usage: test_overdispersed_asymptote(probs, overdispersion) without return types