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
imu noise of mir #99
Comments
Almost all of that noise does not come from the It looks almost identical to your plot. The noise is the same when the robot is stationary. I think this is because even when the robot is stationary in Gazebo, there are always small corrections being applied. There are a lot of simulated forces at work: there is a repulsive force between the ground and each of the wheels; the powered wheels are being commanded to turn forwards and backwards to keep them still, and so on. All of this leads to the robot to "vibrate" by a minuscule amount. Unfortunately, the Apart from that, the
... and possibly also:
Then the total noise can be properly calculated like this: import numpy as np
# n: number of measurements
# dt: sampling rate [s], e.g. dt = 1e-2 when sampling at 100 Hz
def generate_signal(n, dt, noise_density, random_walk, random_state=0):
rng = np.random.RandomState(random_state)
white = noise_density / np.sqrt(dt) * rng.randn(n)
walk = random_walk * np.sqrt(dt) * np.cumsum(rng.randn(n))
return white + walk The orientation should probably be either not filled at all or be returned without noise, because in order to be realistic, it should be coupled to the gyroscope and accelerometer noise. There are already packages like So in short: If you want to get rid of the noise, you'll have to improve |
Hi @mintar, thanks for your very kind and detailed reply! |
Maybe you should try this IMU plugin instead:
It looks much better! If you successfully use it, please report back! |
Hi @mintar, thanks for your suggestions. I compare mir and husky, and compare
|
Thank you for the detailed analysis! I've debugged and solved the problem in commit 063d4e7. The problem was that I used STL meshes as collision geometries for the wheels. If you visualize contacts in Gazebo, you can see that there are lots of inconsistent contacts (not all 6 wheels touch the ground at all times), which lead to these simulated "vibrations" of the robot, which was picked up by the simulated IMU: mir.mp4The husky doesn't have this problem: husky.mp4After replacing the collision geometries with cylinders, the problem is fixed for the MiR: mir_fixed.mp4 |
By the way, you should use |
The gazebo_plugins IMU has a very bad noise model (same stdev for everything). The IMU plugin from hector_gazebo_plugins is much better. See #99.
I've also switched to the hector_gazebo_plugins now. |
Hi author @mintar, thanks very much :) |
When using the STL meshes, there were lots of inconsistent contacts between the wheels and the ground. This resulted in lots of small "vibrations" of the robot due to unstable repulsive forces between ground and wheels, which were measured by the simulated IMU. Using cylinders as collision geometries fixes that. Fixes DFKI-NI#99.
When using the STL meshes, there were lots of inconsistent contacts between the wheels and the ground. This resulted in lots of small "vibrations" of the robot due to unstable repulsive forces between ground and wheels, which were measured by the simulated IMU. Using cylinders as collision geometries fixes that. Fixes DFKI-NI#99.
When using the STL meshes, there were lots of inconsistent contacts between the wheels and the ground. This resulted in lots of small "vibrations" of the robot due to unstable repulsive forces between ground and wheels, which were measured by the simulated IMU. Using cylinders as collision geometries fixes that. Fixes DFKI-NI#99.
When using the STL meshes, there were lots of inconsistent contacts between the wheels and the ground. This resulted in lots of small "vibrations" of the robot due to unstable repulsive forces between ground and wheels, which were measured by the simulated IMU. Using cylinders as collision geometries fixes that. Fixes DFKI-NI#99.
When using the STL meshes, there were lots of inconsistent contacts between the wheels and the ground. This resulted in lots of small "vibrations" of the robot due to unstable repulsive forces between ground and wheels, which were measured by the simulated IMU. Using cylinders as collision geometries fixes that. Fixes DFKI-NI#99.
When using the STL meshes, there were lots of inconsistent contacts between the wheels and the ground. This resulted in lots of small "vibrations" of the robot due to unstable repulsive forces between ground and wheels, which were measured by the simulated IMU. Using cylinders as collision geometries fixes that. Fixes DFKI-NI#99.
When using the STL meshes, there were lots of inconsistent contacts between the wheels and the ground. This resulted in lots of small "vibrations" of the robot due to unstable repulsive forces between ground and wheels, which were measured by the simulated IMU. Using cylinders as collision geometries fixes that. Fixes DFKI-NI#99.
When using the STL meshes, there were lots of inconsistent contacts between the wheels and the ground. This resulted in lots of small "vibrations" of the robot due to unstable repulsive forces between ground and wheels, which were measured by the simulated IMU. Using cylinders as collision geometries fixes that. Fixes DFKI-NI#99. (cherry picked from commit ea368a3) by Martin Günther
Hello authors,
Thanks for your sharing this interesting software. I'm using your mir_robot noetic branch. When remaining the default imu noise params
<xacro:property name="imu_stdev" value="0.00017" />
ofmir_100_v1.urdf.xacro
, which loadsimu.gazebo.urdf.xacro
and sets<xacro:imu_gazebo link="${prefix}imu_link" imu_topic="/imu/data" update_rate="50.0" stdev="${imu_stdev}" />
. imu's gaussianNoise =0.00017 * 0.00017 is very very small.imu.gazebo.urdf.xacro
content:rostopic pub /cmd_vel geometry_msgs/Twist -r 3 -- '[0,0,0]' '[0, 0, 0.4]'
to let mir rotate in place. I found the imu's acc and gyro_z are very noisy. First picture is acc_x and acc_y,second is acc_z, third is gyro_x and gyro_y, the last one is gyro_z. For example, acc_x often is 2 m/s^2, acc_y often is 1m/s^2, acc_z often is 8.5 to 11 m/s^2. Command angular z velocity is 0.4 rad/s, but the gyro_z is 0.36 rad/s to 0.42 rad/s.
The text was updated successfully, but these errors were encountered: