code: def get_sparse_pruning_shared_parameters(param_dict):
      output = {}
      if SHARED_PARAMETERS in param_dict.keys():
          sub_param_dict = param_dict[SHARED_PARAMETERS]
          output[SPARSE_PRUNING_ENABLED] = get_scalar_param(
              sub_param_dict,
              SPARSE_PRUNING_ENABLED,
              SPARSE_PRUNING_ENABLED_DEFAULT,
          )
          output[SPARSE_PRUNING_METHOD] = get_scalar_param(
              sub_param_dict,
              SPARSE_PRUNING_METHOD,
              SPARSE_PRUNING_METHOD_DEFAULT,
          )
          assert output[SPARSE_PRUNING_METHOD] in [
              SPARSE_PRUNING_METHOD_L1,
              SPARSE_PRUNING_METHOD_TOPK,
          ], f"Invalid sparse pruning method. Supported types: [{SPARSE_PRUNING_METHOD_L1}, {SPARSE_PRUNING_METHOD_TOPK}]"
          output[SPARSE_PRUNING_SCHEDULE_OFFSET] = get_scalar_param(
              sub_param_dict,
              SPARSE_PRUNING_SCHEDULE_OFFSET,
              SPARSE_PRUNING_SCHEDULE_OFFSET_DEFAULT,
          )
      else:
          output[
              SPARSE_PRUNING_ENABLED
          ] = SPARSE_PRUNING_ENABLED_DEFAULT
          output[SPARSE_PRUNING_METHOD] = SPARSE_PRUNING_METHOD_DEFAULT
          output[
              SPARSE_PRUNING_SCHEDULE_OFFSET
          ] = SPARSE_PRUNING_SCHEDULE_OFFSET_DEFAULT
      return output
  
imports: from .constants import *
  import copy
  from ..runtime.config_utils import get_scalar_param
label_desc: Use image node_id 13 for calling a global function with example usage: get_sparse_pruning_shared_parameters(param_dict) and returns: output