Comments (4)
Thanks @vujadeyoon
Yes, the pose_pred includes rotation vectors (left axis rotation, top axis rotation, front axis rotation) and translation coordinates.
If you want pitch, yaw and roll (in this order) on the same format as AFLW2000 dataset, you can use the conversion below:
def convert_to_aflw(rotvec, is_rotvec=True):
if is_rotvec:
rotvec = Rotation.from_rotvec(rotvec).as_matrix()
rot_mat_2 = np.transpose(rotvec)
angle = Rotation.from_matrix(rot_mat_2).as_euler('xyz', degrees=True)
return np.array([angle[0], -angle[1], -angle[2]])
However, this format suffers from a problem where yaw is limited to (-90, 90) degrees, and if go beyond this point, pitch and roll are affected to compensate.
Otherwise, just used the first three values from the pose_pred which corresponds to the rotation vector.
Hope this helps.
from img2pose.
Ok I got your point. Thank you for letting me know.
from img2pose.
Dear 976jay,
You can find code [1] that you want in the jupyter cell, Run on a folder or an image list.
I think the variable, pose_pred, includes information related to the yaw, pitch, and roll angles as well as 3D translation coordinate values (i.e. x, y, z)
Best,
vujadeyoon
[1] pose_pred = res["dofs"].cpu().numpy()[i].astype('float')
from img2pose.
I will look into this. Thank you so much
from img2pose.
Related Issues (20)
- Question about 300W-LP labels acquirements HOT 6
- Pose to angle HOT 1
- jaw data HOT 1
- Hi, I'm confused about the definition of the output pose HOT 1
- Slow inference HOT 2
- Question about Visualizing the Activation Map on each layer of the model HOT 1
- Question on fine-tuning HOT 1
- Question about Fine tuning Model with 300W-LP HOT 1
- Bug in readme file HOT 1
- img2pose_v1.pth convert onnx? HOT 1
- A Question about the conversion of t .
- A question about K_box and K_img. HOT 1
- A Question about fine-tuning HOT 2
- TypeError: a bytes-like object is required, not 'NoneType' HOT 4
- A Question about the 6DoF HOT 1
- A Question about the convert_to_aflw
- ONNX output is giving incorrect DOF values HOT 1
- How to get the tvec=[tx,ty,tz]?
- Utilizing GT intrinsics
- AFLW2000-3D translation
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from img2pose.