mirror of
https://github.com/enzet/map-machine.git
synced 2025-05-14 09:36:49 +02:00
Add segment representation.
This commit is contained in:
parent
95f3fc14b0
commit
05e549a364
1 changed files with 3 additions and 0 deletions
|
@ -134,5 +134,8 @@ class Segment:
|
|||
np.arccos(np.dot(vector, np.array((0.0, 1.0)))) / np.pi
|
||||
)
|
||||
|
||||
def __repr__(self):
|
||||
return f"{self.point_1} -- {self.point_2}"
|
||||
|
||||
def __lt__(self, other: "Segment") -> bool:
|
||||
return self.y < other.y
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue