pslade2 / RealTimeKin

20 stars 9 forks source link

IK Result was Unacceptable #2

Closed BiboyLin closed 3 years ago

BiboyLin commented 3 years ago

By using the IMU customed, my IK result was strange and unacceptable showed in Opensim :

https://user-images.githubusercontent.com/34125254/121982627-68c4a780-cdc2-11eb-9f19-b0880a7d3037.mov

I couldn't ensure which part was the problem: Is the IMU data problem or IK processing problem?

For examing the IMU data, I have checked by: 1) comparing with another type of IMU using the same walking condition(30hz, 4km/h) Result: The IMU and reading function can work well, the following picture was the raw imu recording of right foot (acc_x,acc_y,acc_z, gyro_x,gyro_y, gyro_z) produced by the ik_streaming, corresponding the IK result above, it seems correct comparing with another one used in my exoskeleton. image

3) comparing with 100hz and 30hz sampling rate Result: I found the Pi can't process the data in 100Hz, which would lead to only approximately 1/3 data can be recorded in the .npy or .sto, for example, about 50s walking data, only 16s was recorded in the raw_imu_data.npy and 15s in the recording_x.sto

By doing so, I still can't ensure whether my IMU data was right. Can you provide some sample recording like walking data, so that I can comparing the format and value of my IMU data with yours?

Besides, I still interest in your visualization setting and how you achieve it?

pslade2 commented 3 years ago

sample_walking_data.zip I've attached some sample walking data. The .npy contains the IMU raw data and the .sto contains the kinematics computed in real-time from that data.

  1. I think the units of your sensors are not the same as expected units. See the paper for details about the units expected.

  2. The online estimation rate depends on the number of sensors you use (see Fig. 8 of the paper). Thus, 100 Hz may be too high for the number of sensors you use. Since you are using a different IMU sensor you also have to be able to sample that sensor at that rate.

  3. The visualization shown in the videos is visualized after the fact using OpenSim on a computer. The raspberry pi uses a terminal rather than GUI based system to reduce computation demands, and thus cannot render the visualization itself. You could pass the kinematics between the Pi and another computer to visualize it in real time if that was necessary.

Best of luck with your IMUs!

BiboyLin commented 3 years ago

Thanks a lot!!!! That is verrrry helpful!! It seems you using the radian system but my IMU output the degree by °/s! Once I get the result, I will comment on it here! Thanks you again!

BiboyLin commented 3 years ago

Thanks again! I got a great IK result now! And I am going to validate the accuracy with the optimal motion capture system~ For real-time visualization, your suggestion seems the only way to achieve it due to the limited computation capability of Pi., and I will try!

pslade2 commented 3 years ago

Glad it was an easy fix! Hope the system works well for you!