code: def get_dimension_index(self, name, value):
          
  
          if 'index' not in self.get('dimension', {}). \
                  get(name, {}).get('category', {}):
              return 0
          ndx = self['dimension'][name]['category']['index']
  
          if isinstance(ndx, list):
              return ndx.index(value)
          else:
              return ndx[value]
docs: Converts a dimension ID string and a categody ID string into the \
             numeric index of that category in that dimension
          Args:
             name(string): ID string of the dimension.
             value(string): ID string of the category.
  
          Returns:
             ndx[value](int): index of the category in the dimension.