Guest User

Untitled

a guest
Aug 17th, 2018
79
0
Never
Not a member of Pastebin yet? Sign Up, it unlocks many cool features!
text 0.43 KB | None | 0 0
  1. aa = np.matrix([[1,2,3],[1,2,3],[1,2,3]])
  2. bb = np.matrix([[1,1,1],[2,2,2],[3,3,3]])
  3.  
  4. np.tile(aa,(3,1))*bb.ravel().T
  5.  
  6. ValueError: shapes (9,3) and (9,1) not aligned: 3(dim 1) != 9 (dim 0)
  7.  
  8. points = bb
  9. T = aa
  10.  
  11. for point in points:
  12. pointNewPosition = T*point.T
  13. pointsNewPos.append(pointNewPosition.T)
  14.  
  15. import numpy as np
  16.  
  17. aa = np.array([[1,2,3],[1,2,3],[1,2,3]])
  18. bb = np.array([[1,1,1],[2,2,2],[3,3,3]])
  19.  
  20. result = aa.T.dot(bb)
Add Comment
Please, Sign In to add comment