2024-Q4-AI 3. Inverse kinematics (Numpy, calculus, partial derivatives)

Описание к видео 2024-Q4-AI 3. Inverse kinematics (Numpy, calculus, partial derivatives)

Whiteboard:
https://whiteboard.fi/8ba3c97b-c36a-4...

Calculus:
   • 3Blue1Brown: Calculus  

3.2. Forward Kinematics Task

Using the provided template, implement a 2-segment robot arm with defined theta_1 and theta_2 angles using a 2D rotation matrix. Use 2D vectors instead of 3D vectors. Perform translation by vector addition.

2D rotation matrix:

http://share.yellowrobot.xyz/upic/cfe...

The result should be as follows:

http://share.yellowrobot.xyz/upic/0dd...

Template:

https://share.yellowrobot.xyz/quick/2...


3.4 Implement MSE/L2 Loss Calculation

Implement the calculation of the MSE/L2 loss between the robot's end-effector position and the target position and display it using plt.title(f'loss = {loss}')

Error calculation:

http://share.yellowrobot.xyz/upic/966...


3.5. Implement the derivative for MSE/L2 error calculation

Implement the derivative for MSE/L2 error calculation
http://share.yellowrobot.xyz/upic/d94...

3.6. Implement Robot Arm Inverse Kinematics using SGD

Implement an arm with 2 segments using the previous tasks, so that both angles change in a direction that reduces the error value.

Submit the source code and a screenshot


3.7. Implement a robot arm with 3 segments

Preparation of tasks from previous assignments

1. Implement inverse kinematics using MSE for 3 segments

2. Prevent the arm from passing over itself or going below the 0 level (this can be achieved by adding additional errors and additional dTheta from different points on the arm's middle parts, maximization can also be done. The solution does not need to work in 100% of cases, but it should be implemented without IF statements).

The result should look like this:
http://share.yellowrobot.xyz/upic/a2a...

Комментарии

Информация по комментариям в разработке