code: def polygons_obb(polygons):
      
      rectangles = [None] * len(polygons)
      transforms = [None] * len(polygons)
      for i, p in enumerate(polygons):
          transforms[i], rectangles[i] = polygon_obb(p)
      return np.array(transforms), np.array(rectangles)
docs: Find the OBBs for a list of shapely.geometry.Polygons