code: def instantiate_activation_block(
      activation_name: str, **kwargs
  ) -> nn.Module:
      block = get_activation_block(activation_name)
  
      act_params = {}
  
      if "inplace" in kwargs and activation_name in {
          ACT_RELU,
          ACT_RELU6,
          ACT_LEAKY_RELU,
          ACT_SELU,
          ACT_SILU,
          ACT_CELU,
          ACT_ELU,
      }:
          act_params["inplace"] = kwargs["inplace"]
  
      if "slope" in kwargs and activation_name in {ACT_LEAKY_RELU}:
          act_params["negative_slope"] = kwargs["slope"]
  
      if activation_name == ACT_PRELU:
          act_params["num_parameters"] = kwargs["num_parameters"]
  
      return block(**act_params)
  
imports: from collections import OrderedDict
  import torch
  from torch import nn
  from torch.nn import functional
  from .identity import Identity
label_desc: Use image node_id 12 for calling a global function with example usage: instantiate_activation_block(activation_name) and returns: block