else:
other = np.atleast_2d(other)
if other.shape[0] == 1:
other = other.T
if other.shape[0] == self.dim - 1:
// Transform one or more 2-vectors
return np.squeeze(self.rot * other + np.atleast_2d(self.trans).T)
elif other.shape[0] == self.dim:
// Transform one or more 3-vectors
return np.squeeze(self.as_matrix().dot(other))
else:
After Change
return SE2(self.rot * other.rot,
self.rot * other.trans + self.trans)
else:
other = np.atleast_2d(other)
if other.shape[1] == self.dim - 1:
// Transform one or more 2-vectors
return np.squeeze(self.rot * other.T + np.atleast_2d(self.trans).T).T
elif other.shape[1] == self.dim:
// Transform one or more 3-vectors
return np.squeeze(self.as_matrix().dot(other.T)).T
else: