class_docstr: A collection of one or more Polygons.
  
  If component polygons overlap the collection is invalid and some
  operations on it may fail.
  
  Parameters
  ----------
  polygons : sequence
      A sequence of Polygons, or a sequence of (shell, holes) tuples
      where shell is the sequence representation of a linear ring
      (see LinearRing) and holes is a sequence of such linear rings.
  
  Attributes
  ----------
  geoms : sequence
      A sequence of `Polygon` instances
  
  Examples
  --------
  Construct a MultiPolygon from a sequence of coordinate tuples
  
  >>> from shapely import Polygon
  >>> ob = MultiPolygon([
  ...     (
  ...     ((0.0, 0.0), (0.0, 1.0), (1.0, 1.0), (1.0, 0.0)),
  ...     [((0.1,0.1), (0.1,0.2), (0.2,0.2), (0.2,0.1))]
  ...     )
  ... ])
  >>> len(ob.geoms)
  1
  >>> type(ob.geoms[0]) == Polygon
  True
code: def __new__(self, polygons=None):
      if polygons is None:
          # allow creation of empty multipolygons, to support unpickling
          # TODO better empty constructor
          return shapely.from_wkt("MULTIPOLYGON EMPTY")
      elif isinstance(polygons, MultiPolygon):
          return polygons
  
      polygons = getattr(polygons, "geoms", polygons)
      # remove None and empty polygons from list of Polygons
      polygons = [p for p in polygons if p]
  
      L = len(polygons)
  
      # Bail immediately if we have no input points.
      if L == 0:
          return shapely.from_wkt("MULTIPOLYGON EMPTY")
  
      # This function does not accept sequences of MultiPolygons: there is
      # no implicit flattening.
      if isinstance(polygons[0], MultiPolygon):
          raise ValueError(
              "Sequences of multi-polygons are not valid arguments"
          )
  
      subs = []
      for i in range(L):
          ob = polygons[i]
          if not isinstance(ob, polygon.Polygon):
              shell = ob[0]
              if len(ob) > 1:
                  holes = ob[1]
              else:
                  holes = None
              p = polygon.Polygon(shell, holes)
          else:
              p = polygon.Polygon(ob)
          subs.append(p)
  
      return shapely.multipolygons(subs)
  
file_path: shapely/shapely/geometry/multipolygon.py
imports: import shapely
  from shapely.geometry import polygon
  from shapely.geometry.base import BaseMultipartGeometry
label_desc: Use image node_id 1 for calling the MultiPolygon obj's underlying member method code with example usage: obj.__new__(polygons) and returns: shapely, shapely, shapely, polygons