Code
Hub
Workspaces
Connect
Indexed graphs
Engine
MCP
copy
hub
/
github.com/AirtestProject/Poco
/ unit
Method
unit
poco/utils/vector.py:65–67 ·
view source on GitHub ↗
(self)
Source
from the content-addressed store, hash-verified
63
return
math.sqrt(self.x ** 2 + self.y ** 2)
64
65
def
unit(self):
66
length = self.length
67
return
Vec2(self.x / length, self.y / length)
68
69
def
rotate(self, radian):
70
qx = math.cos(radian) * self.x - math.sin(radian) * self.y
Callers
1
track_sampling
Function · 0.80
Calls
1
Vec2
Class · 0.85
Tested by
no test coverage detected