MCPcopy Create free account
hub / github.com/MotrixLab/ADHMR / affine_transform

Function affine_transform

ADHMR/lib/utils/transforms.py:1408–1411  ·  view source on GitHub ↗
(pt, t)

Source from the content-addressed store, hash-verified

1406
1407
1408def affine_transform(pt, t):
1409 new_pt = np.array([pt[0], pt[1], 1.]).T
1410 new_pt = np.dot(t, new_pt)
1411 return new_pt[:2]
1412
1413def inverse_affine_transform(transformed_pt, t):
1414 # Extract the 2x2 linear transformation part and the translation part

Callers 9

transform_predsFunction · 0.70
transform_preds_newFunction · 0.70
__call__Method · 0.50
__call__Method · 0.50
__call__Method · 0.50
__call__Method · 0.50
__call__Method · 0.50
__call__Method · 0.50
__call__Method · 0.50

Calls

no outgoing calls

Tested by

no test coverage detected