def METHOD_NAME(model_class, up_to_list, batch_size, training, seed):
    model_module = importlib.import_module("nnabla.models.imagenet")
    nn.clear_parameters()
    rng = np.random.RandomState(seed)
    model = getattr(model_module, model_class)()
    # Determine input shape and create input variable
    input_shape = list(model.input_shape)
    input_shape = tuple(input_shape)
    x = nn.Variable.from_numpy_array(rng.randint(
        0, 256, size=(batch_size,) + input_shape))
    # Test cases for all intermediate outputs
    for use_up_to in up_to_list:
        returns_net = False
        def _execute():
            y = model(x, training=training, use_up_to=use_up_to)
            y.forward()
        _execute()
        net = model(x, training=training,
                    use_up_to=use_up_to, returns_net=True)
        assert isinstance(net, NnpNetwork)
        assert len(net.inputs.values()) == 1
        assert len(net.outputs.values()) == 1
        y = list(net.outputs.values())[0]
        if training:
            assert _check_trainable_parameters(y)
        else:
            assert not _check_trainable_parameters(y)