code: def softmin(
      a: TensorLikeType,
      dim: Optional[int] = None,
      _stacklevel: int = 3,  # for compat when using TorchRefsMode(strict=True)
      dtype: Optional[torch.dtype] = None,
  ) -> TensorLikeType:
      # The error is for compat with regular PyTorch, which has this behavior
      # deprecated.  For PrimTorch, it's fine to drop support for deprecated
      # behavior because it requires explicit opt in.  This error is to inform
      # users how to update their calls.
      torch._check(
          dim is not None,
          lambda: "implicit dim not supported, use dim=X",
      )
      return torch.softmax(a=-a, dim=dim, dtype=dtype)
  
imports: import math
  from functools import wraps
  from typing import Callable, Optional, Union
  import torch
  import torch._prims
  import torch._prims_common
  import torch._refs
  from torch._decomp import register_decomposition
  from torch._prims_common import ELEMENTWISE_TYPE_PROMOTION_KIND, NumberType, ShapeType, TensorLike, TensorLikeType
  from torch._prims_common.wrappers import elementwise_type_promotion_wrapper, elementwise_unary_scalar_wrapper, out_wrapper
  from torch._refs import _make_inplace
label_desc: Use image node_id 14 for calling a global function with example usage: softmin(a, dim, _stacklevel, dtype) and returns: torch