code: def format(self, value):
      if self.floating_dtype:
          if self.sci_mode:
              ret = f"{{:{self.max_width}.{PRINT_OPTS.precision}e}}".format(
                  value
              )
          elif self.int_mode:
              ret = f"{value:.0f}"
              if not (math.isinf(value) or math.isnan(value)):
                  ret += "."
          else:
              ret = f"{{:.{PRINT_OPTS.precision}f}}".format(value)
      else:
          ret = f"{value}"
      return (self.max_width - len(ret)) * " " + ret
  
imports: import contextlib
  import dataclasses
  import math
  import textwrap
  from typing import Any, Dict, Optional
  import torch
  from torch import inf
label_desc: Use image node_id 3 for calling the _Formatter obj's underlying member method code with example usage: obj.format(value) and returns: unknown