My Creation Anniversary - CSDN Creator 4th Anniversary, thanks to the platform, the future can be expected!

The 4th anniversary of CSDN creators, thanks to the platform, the future can be expected!

  • Unknowingly, it has been the 4th anniversary of joining this platform. I am in a trance of yesterday. Some things, you don’t care, but the platform has already written a program to mark it. Thoughts are unlimited, so the program has no boundaries.
  • Frankly speaking, although it is the fourth anniversary, I feel that I will really create content on this platform from the second half of 2021. Why do I say that, because I really have the ability to think about algorithms and programs since then.
  • https://blog.csdn.net/yohnyang?spm=1010.2135.3001.5343
    insert image description here

chance

  1. Accumulate and consolidate basic knowledge through blogging
  2. Experience sharing in actual combat projects
  3. Records in the daily learning process
  4. Technical communication through articles
  5. Knowledge payment, technology realization
  6. Try to expand more contacts through this platform, get in touch with new projects related to visual algorithms, and constantly break through and challenge

reward

  1. Increase fans
    insert image description here

  2. Overall Level Improvement
    insert image description here

  3. Download
    insert image description here

  4. cash out
    insert image description here


daily

  1. Is creation already a part of life? Every morning, I will open CSDN on my mobile phone to check the data changes. On weekdays, I will query related technical blind spots through CSDN, and conduct periodic self-counting and review. If I have new experience and summary, I will always be impatient Turning it into a blog has been regarded as a necessary part.
  2. With limited energy, how to balance creation, work and study: time is precious, people in their twenties, life pressure is generally high, running through weak skills, little work experience, sparse contacts, long overtime hours, which may be reserved for creation and There is very little time to study, but after working for a long time, you will find that when you are working on a project or developing a function, if you do it at your fingertips, it will increase the accumulation of surprises. If it is quite challenging, you will gain some new knowledge and experience every day. The experience is equivalent to studying every day. I think creation can squeeze some time out of spare time to write a blog, and it can be done at one time or several times.

Achievement

  • I have been working for more than two years, and I have also done some small projects by myself. These can be seen in my
    artificial intelligence
    column, which mainly introduces some visual algorithm applications (traditional + deep learning)
  • There is one achievement that I am most proud of. In 2022, I studied a C++ robot library and recorded it in the robot control algorithm column. This is the only one on the whole network and the most detailed. I personally feel that it is easier to ROSuse.
  • The summarized in-depth learning practical routines currently have a small number of articles but a good number of subscriptions. I am very proud of this and will continue to work hard in the future. I will continue to present more project cases to my fans and subscribers. Thank you for your company along the way.
  • Put a feeling 自己刚站起来code, you can see the detailed introduction in my stereo vision and 3D reconstruction column: https://blog.csdn.net/yohnyang/article/details/124490587
clear all;
close all;
clc;

%生成原始点集
X=[];Y=[];Z=[];
for i=-180:2:180
    for j=-90:2:90
        x = i * pi / 180.0;
        y = j * pi / 180.0;   
        X =[X,cos(y) * cos(x)];
        Y =[Y,sin(y) * cos(x)];
        Z =[Z,sin(x)]; 
    end
end
P=[X(1:3000)' Y(1:3000)' Z(1:3000)'];

%生成变换后点集
i=0.5;j=0.3;k=0.7;
Rx=[1 0 0;0 cos(i) -sin(i); 0 sin(i) cos(i)];
Ry=[cos(j) 0 sin(j);0 1 0;-sin(j) 0 cos(j)];
Rz=[cos(k) -sin(k) 0;sin(k) cos(k) 0;0 0 1];
R=Rx*Ry*Rz;
X=P*R + [0.2,0.3,0.4];

plot3(P(:,1),P(:,2),P(:,3),'b.');
hold on;
plot3(X(:,1),X(:,2),X(:,3),'r.');

%计算点集均值
up = mean(P);
ux = mean(X);

% %case1:矩阵右乘 
% P1=P-up;
% X1=X-ux;
% 
% % 计算点集协方差
% sigma=P1'*X1/(length(X1))
% 
% [u s v] = svd(sigma);
% RR=u*v';
% 
% % 计算平移向量
% qr=ux-up*RR;
% 
% %验证旋转矩阵与平移向量正确性
% Pre = P*RR+qr;

%case2:矩阵左乘
PP=P';
XX=X';

PP1=PP-up';
XX1=XX-ux';

%sigma
sigma=XX1*PP1'/length(XX1);

[u s v]=svd(sigma);

RR=u*v';
qr=ux'-RR*(up');

Pre = RR*PP+qr;
Pre=Pre';


figure;
plot3(P(:,1),P(:,2),P(:,3),'b.');
hold on;
plot3(X(:,1),X(:,2),X(:,3),'r.');
plot3(Pre(:,1),Pre(:,2),Pre(:,3),'go');

C++ - Eigen implementation:

void pose_estimation_3d3d(const vector<Point3f> &pts1,
                          const vector<Point3f> &pts2,
                          Mat &R, Mat &t) {
    
    
  Point3f p1, p2;     // center of mass
  int N = pts1.size();
  //求质心
  for (int i = 0; i < N; i++) {
    
    
    p1 += pts1[i];
    p2 += pts2[i];
  }
  p1 = Point3f(Vec3f(p1) / N);
  p2 = Point3f(Vec3f(p2) / N);
  
  //去质心
  vector<Point3f> q1(N), q2(N); // remove the center
  for (int i = 0; i < N; i++) {
    
    
    q1[i] = pts1[i] - p1;
    q2[i] = pts2[i] - p2;
  }

  // 计算W
  Eigen::Matrix3d W = Eigen::Matrix3d::Zero();
  for (int i = 0; i < N; i++) {
    
    
    W += Eigen::Vector3d(q1[i].x, q1[i].y, q1[i].z) * Eigen::Vector3d(q2[i].x, q2[i].y, q2[i].z).transpose();
  }
  cout << "W=" << W << endl;

  // SVD分解出U V
  Eigen::JacobiSVD<Eigen::Matrix3d> svd(W, Eigen::ComputeFullU | Eigen::ComputeFullV);
  Eigen::Matrix3d U = svd.matrixU();
  Eigen::Matrix3d V = svd.matrixV();

  cout << "U=" << U << endl;
  cout << "V=" << V << endl;
 //计算R T
  Eigen::Matrix3d R_ = U * (V.transpose());
  if (R_.determinant() < 0) {
    
      //R存在多解情况,取正值
    R_ = -R_;
  }
  //求解t
  Eigen::Vector3d t_ = Eigen::Vector3d(p1.x, p1.y, p1.z) - R_ * Eigen::Vector3d(p2.x, p2.y, p2.z);

  // 变成矩阵形式
  R = (Mat_<double>(3, 3) <<
    R_(0, 0), R_(0, 1), R_(0, 2),
    R_(1, 0), R_(1, 1), R_(1, 2),
    R_(2, 0), R_(2, 1), R_(2, 2)
  );
  t = (Mat_<double>(3, 1) << t_(0, 0), t_(1, 0), t_(2, 0));
}

look forward to

  • Career planning
    is not too far away here, let’s talk about the career plan for the next three to five years: In the third year of the current job, I hope that in the next two to three years, I can consolidate my C++ combat ability, in multi-threading, algorithms and deployment. It can be used freely, and can transplant its own algorithm in Qt to form a complete set of system operations, and truly become a technical elite. In five years, it is hoped that it will not only develop in technology, but also in product design, program formulation and Accumulate more experience in teamwork, and shine better

  • creative planning

    • On the one hand, the existing columns will be supplemented and perfected, and the number of columns for each actual combat project will be 50+
    • On the other hand, develop other column projects, such as nlp, robot control algorithm, etc.
    • I also hope that I can optimize my accumulated experience and knowledge into courses on the CSDN platform, and save some meaningful memories after a few years​​​​

thank you

! ! ! ---------- Thanks to CSDN for providing the platform ----------! ! !

Guess you like

Origin blog.csdn.net/yohnyang/article/details/132389185
Recommended