code: def _encode_decode_decorator(func):
      
      def wrapper(*args):
          """error catching"""
          try:
              processed_geom = func(*args)
              return processed_geom
          except ImportError as err:
              raise ImportError('The Python package `shapely` needs to be '
                                'installed to encode or decode geometries. '
                                '({})'.format(err))
      return wrapper
docs: decorator for encoding and decoding geoms