def METHOD_NAME(metric_device):
    n_iters = 60
    s = 16
    offset = n_iters * s
    n_probabilities = 10
    y = torch.rand(offset * idist.get_world_size(), n_probabilities)
    def update(_, i):
        return y[i * s + rank * offset : (i + 1) * s + rank * offset, :]
    engine = Engine(update)
    m = InceptionScore(num_features=n_probabilities, feature_extractor=torch.nn.Identity(), device=metric_device)
    m.attach(engine, "InceptionScore")
    engine.run(data=list(range(n_iters)), max_epochs=1)
    assert "InceptionScore" in engine.state.metrics
    assert pytest.approx(calculate_inception_score(y), rel=1e-5) == m.compute()