Open chongxi opened 4 years ago
This must have something to do with changing the threshold using the sliding bar during the experiment.
There are two sources of the problem can cause this bug and they have different nature:
1) The asynchronous operation
to the same shared variable from different CPUs
2) The log.info use .2f
print precision, which can be different from the precision when the comparison happens.
The first array represents the speed, the first column is smoothed speed (using 0.5 s window) in cm/s, the second column is the speed threshold. The second array represents the reconstruction error between the online and offline BMI navigation trajectory.
The asynchronous operation
to the same shared variable from different CPUs explains why the reconstruction error follows the changing of speed threshold in the GUI.
reconstruction error happens when the animal speed become first lower than the speed threshold (after the speed threshold adjusting)
To test whether we can bypass this problem, the speed threshold should be set to 5cm/s by default.