Comments (11)
hi how can I extract 2d poses from the resulted 3d pose (2d pose front view, back view, and side view) thanks
You can project the 3D pose to 2D with your camera parameters. Use different extrinsic rotation/translation for different views. Method in this repo that can be used is:
from evoskeleton.
thanks for your replay, i am trying to do it for my own images where i do not have such information is there any default value for it.
Thanks in advance
from evoskeleton.
thanks for your replay, i am trying to do it for my own images where i do not have such information is there any default value for it. Thanks in advance
You do not need many parameters to simulate a pin-hole camera. Assume you have 3d pose [x, y, z] in the camera coordinate system (this repo contains it) and you can project it to the screen as [fx/z, fy/z] where f is your focal length. I would suggest you take a look at camera models. See https://docs.opencv.org/4.5.3/d9/d0c/group__calib3d.html for example.
from evoskeleton.
Thanks for your replay
I am trying to use it for my own images i generate the pose using h36mpose.py and then run the inference but can i ask how to generate the stats.npy file ?
from evoskeleton.
Thanks for your replay I am trying to use it for my own images i generate the pose using h36mpose.py and then run the inference but can i ask how to generate the stats.npy file ?
Use this inference script https://github.com/Nicholasli1995/EvoSkeleton/blob/master/examples/inference.py. Download the file following the instruction here https://github.com/Nicholasli1995/EvoSkeleton/blob/master/docs/TRAINING.md.
from evoskeleton.
thanks so much for your replay I follow the instructions I just have trouble showing the 2d projection from 3d pose as follows
How can I visualize it right so I can see how accurate the projected 2d poses?
Thanks for everything, the code and support.
from evoskeleton.
i try to use the following code but yet did not get it
`def project_to_cameras(poses):
"""
Project 3d poses using camera parameters
input:
3D poses: [n_pose, pose length]
cams: list of camera parameters
return: list of 2D projections for each camera
cams:
"""
p_2d = []
rcams= np.load('/Pose_for_Re-id/EvoSkeleton_master/cameras.npy', allow_pickle=True).item()
#print('befor adding')
cams = add_virtual_cams(rcams)
#print('after adding')
# By default, all actions are used
ncams=4
for cam in range(ncams):
R, T, f, c, k, p, name = cams[(1, cam+1)]
pts2d, _, _, _, _ = cameras.project_point_radial(np.reshape(poses, [-1, 3]), R, T, f, c, k, p )
f = plt.figure(figsize=(9, 9))
ax4 = plt.subplot(131)
plt.title('2D key-point inputs: {:d}*2'.format(16))
ax4.set_aspect('equal')
ax4.invert_yaxis()
skeleton_pred = None
s2d=pts2d
show2Dpose(np.reshape( pts2d, [-1, len(H36M_NAMES)*2]),ax4)
p_2d.append(np.reshape( pts2d, [-1, len(H36M_NAMES)*2]))
return p_2d`
from evoskeleton.
If I need to rotate around the y-axis what should I change?
from evoskeleton.
If I need to rotate around the y-axis what should I change?
See ax.set_xlim/set_ylim to control your 2D plot. Change R and T to the camera pose that you need.
from evoskeleton.
Thanks but wen i change the anagle in add_virtual_cams to:
new_R, new_T = get_new_camera(R.T, T, [0.,angle, 0.])
nothing changed.
from evoskeleton.
Thanks but wen i change the anagle in add_virtual_cams to:
new_R, new_T = get_new_camera(R.T, T, [0.,angle, 0.])
nothing changed.
You do not understand the code and coordinate transformation and I don't have time for beginner tutorial. Why not you upload your 3D pose and I simply write you a script to run? You can create a page in the discussion and I'm closing this issue since it's not a bug.
from evoskeleton.
Related Issues (20)
- Training with less joints HOT 2
- Regarding the 2D HPE model HOT 2
- training input size and inference input size not match HOT 32
- Location of the hip/pelvis joint? HOT 6
- camera params in cameras.npy HOT 2
- generating other poses from a known pose HOT 7
- ImportError: No module named libs.hhr.config HOT 3
- AttributeError: module 'libs.utils' has no attribute 'utils' HOT 5
- 2D to 3D with own data HOT 6
- weird 3D Pose
- Input of the plot_distribution in anglelimits.py HOT 4
- Inconsistency between pretrained HRNet 2D detector and twoDPose_HRN.npy HOT 7
- Data Preprocessing when test on 3dhp dataset HOT 3
- Obtain 3D skeleton with 2D key-points as inputs using SMPLify by own data HOT 3
- Source of 2D keypoints when eval on 3dhp dataset HOT 1
- Preprocessed npz file of HRNet HOT 1
- About 2D anchor of the cropped image HOT 3
- Regarding h36m image HOT 5
- 模型下载问题 HOT 1
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 evoskeleton.