class_docstr: Segments are lines in 2D space where each two key dimensions specify a
  (x, y) node of the line.
class_docstr_tok: ["Segments","are","lines","in","2D","space","where","each","two","key","dimensions","specify","a","(","x",",","y",")","node","of","the","line","."]
code: def get_data(self, element, ranges, style):
      inds = (1, 0, 3, 2) if self.invert_axes else (0, 1, 2, 3)
      dims = element.dimensions()
      data = [
          [(x0, y0), (x1, y1)]
          for x0, y0, x1, y1 in zip(
              *(element.dimension_values(d) for d in inds)
          )
      ]
      with abbreviated_exception():
          style = self._apply_transforms(element, ranges, style)
      return (data,), style, {"dimensions": dims}
  
file_path: holoviews/holoviews/plotting/mpl/geometry.py
imports: import numpy
  from matplotlib.collections import LineCollection, PatchCollection
  from matplotlib.patches import Rectangle
  from ...core.options import abbreviated_exception
  from ..mixins import GeomMixin
  from .element import ColorbarPlot
  from .path import PathPlot, PolygonPlot
label_desc: Use image node_id 2 for calling the SegmentPlot obj's underlying member method code with example usage: obj.get_data(element, ranges, style) and returns: data,  style,  dict