def explode(self):
        """
        If the current Line entity consists of multiple line
        break it up into n Line entities.

        Returns
        ----------
        exploded: (n,) Line entities
        """
        points = np.column_stack((
            self.points,
            self.points)).ravel()[1:-1].reshape((-1, 2))
        exploded = [Line(i) for i in points]
        return exploded
def explode ( self ) : points = np . column_stack ( ( self . points , self . points ) ) . ravel ( ) [ 1 : - 1 ] . reshape ( ( - 1 , 2 ) ) exploded = [ Line ( i ) for i in points ] return exploded
If the current Line entity consists of multiple line
        break it up into n Line entities.

        Returns
        ----------
        exploded: (n,) Line entities