Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

pytorch code #37

Open
shitouren1994 opened this issue May 13, 2021 · 0 comments
Open

pytorch code #37

shitouren1994 opened this issue May 13, 2021 · 0 comments

Comments

@shitouren1994
Copy link

hello,can you tell me the meaning of martix B and martix C in gen_position?

B[:, :, 0:1] = l * 0.5 * cosori + w * 0.5 * sinori
B[:, :, 1:2] = h * 0.5
B[:, :, 2:3] = l * 0.5 * cosori - w * 0.5 * sinori
B[:, :, 3:4] = h * 0.5
B[:, :, 4:5] = -l * 0.5 * cosori - w * 0.5 * sinori
B[:, :, 5:6] = h * 0.5
B[:, :, 6:7] = -l * 0.5 * cosori + w * 0.5 * sinori
B[:, :, 7:8] = h * 0.5
B[:, :, 8:9] = l * 0.5 * cosori + w * 0.5 * sinori
B[:, :, 9:10] = -h * 0.5
B[:, :, 10:11] = l * 0.5 * cosori - w * 0.5 * sinori
B[:, :, 11:12] = -h * 0.5
B[:, :, 12:13] = -l * 0.5 * cosori - w * 0.5 * sinori
B[:, :, 13:14] = -h * 0.5
B[:, :, 14:15] = -l * 0.5 * cosori + w * 0.5 * sinori
B[:, :, 15:16] = -h * 0.5

C[:, :, 0:1] = -l * 0.5 * sinori + w * 0.5 * cosori
C[:, :, 1:2] = -l * 0.5 * sinori + w * 0.5 * cosori
C[:, :, 2:3] = -l * 0.5 * sinori - w * 0.5 * cosori
C[:, :, 3:4] = -l * 0.5 * sinori - w * 0.5 * cosori
C[:, :, 4:5] = l * 0.5 * sinori - w * 0.5 * cosori
C[:, :, 5:6] = l * 0.5 * sinori - w * 0.5 * cosori
C[:, :, 6:7] = l * 0.5 * sinori + w * 0.5 * cosori
C[:, :, 7:8] = l * 0.5 * sinori + w * 0.5 * cosori
C[:, :, 8:9] = -l * 0.5 * sinori + w * 0.5 * cosori
C[:, :, 9:10] = -l * 0.5 * sinori + w * 0.5 * cosori
C[:, :, 10:11] = -l * 0.5 * sinori - w * 0.5 * cosori
C[:, :, 11:12] = -l * 0.5 * sinori - w * 0.5 * cosori
C[:, :, 12:13] = l * 0.5 * sinori - w * 0.5 * cosori
C[:, :, 13:14] = l * 0.5 * sinori - w * 0.5 * cosori
C[:, :, 14:15] = l * 0.5 * sinori + w * 0.5 * cosori
C[:, :, 15:16] = l * 0.5 * sinori + w * 0.5 * cosori
@benlvzi
Copy link

benlvzi commented Jun 2, 2021

B还好理解 但是矩阵C是怎么生成的?

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants