code: def test_optim_call(tmpdir, optim_fn, lr, kwargs):
      layer = nn.Linear(10, 1)
      optimizer = optim_fn(layer.parameters(), lr=lr, **kwargs)
  
      for _ in range(10):
          dummy_input = torch.rand(1, 10)
          dummy_input.requires_grad = True
          result = layer(dummy_input)
          result.backward()
          optimizer.step()
  
imports: import pytest
  import torch
  from flash.core.optimizers import LAMB, LARS, LinearWarmupCosineAnnealingLR
  from flash.core.utilities.imports import _TOPIC_CORE_AVAILABLE
  from torch import nn
label_desc: Use image node_id 1 for calling a global function with example usage: test_optim_call(tmpdir, optim_fn, lr, kwargs) without return types