code: def __init__(self, item):
      def split_dim(item):
          parts = item.replace(")", "(").split("(")
          for i in range(len(parts)):
              if i % 2 == 0:
                  for x in parts[i]:
                      if x.strip():
                          yield x
              else:
                  x = [x for x in parts[i] if x.strip()]
                  yield x if len(x) > 1 else x[0]
  
      iter = split_dim(item)
      self.id2ax = [x for x in iter]
      self.ax2id = dict(
          [
              (x, i)
              for i, x in enumerate(self.id2ax)
              if isinstance(x, str) and x != "*"
          ]
      )
      for i, x in enumerate(self.id2ax):
          if not isinstance(x, str):
              for j, ax in enumerate(x):
                  self.ax2id[ax] = (i, j)
  
imports: import os, sys, json, re
  import tempfile
  import copy
  import inspect
  import logging
  import importlib
  from .None import solver
  from .None import patterns
label_desc: Use image node_id 1 to create a new Mapper2D object  with example: obj = Mapper2D(item)