• No results found

Evaluation of the Probit-Based Context-Aware Filter: Simulations

Filter: Simulations

In this section, we provide three simulation evaluations in order to illustrate different properties of the probit-based context-aware filter. Real-data evaluation is provided

Time 200 400 600 800 1000 1200 1400 1600 1800 2000 Magnitude -1 0 1 2 3 4

5 Example Run for Non-Moving System

Context-Aware Filter Estimates True State Context Measurements

(a) Example run.

Time 0 200 400 600 800 1000 1200 1400 1600 1800 2000 Magnitude 0 0.5 1 1.5 2 2.5

3 Estimation Error For Ten Runs of Non-Moving System

(b) Estimation error for ten runs. Time 0 200 400 600 800 1000 1200 1400 1600 1800 2000 Magnitude 0 0.2 0.4 0.6 0.8 1 1.2 1.4 1.6 1.8

2 Covariance of Ten Runs of Non-Moving System

(c) Magnitude of variance for ten runs.

Figure 3.4: Illustration of the performance of the context-aware filter on a non- moving scalar system.

in Section 3.8.

3.7.1

System with No Dynamics

In the first simulation scenario, we evaluate the performance of the filter on a system with no dynamics, in order to illustrate the significance of Theorem 2. Figure 3.4

shows the filter’s evaluation on a scalar system with a constant statexk= 3 and with

access to one context measurement with corresponding parameters bk= 1 and ak =

−5. The initial condition is set to µ0 = 1, Σ0 = 2. Figure 3.4c shows the evolution

of the covariance for 10 runs of the system; as expected, the covariance converges to 0 for each one, thus ensuring the convergence of the filter overall. Figure 3.4b shows the estimation errors for the same 10 runs – the figure indicates that the estimates are close to the true state, although some estimates converge more slowly due to different random realizations of the measurements. Finally, Figure 3.4a shows the interesting toothed shape of the estimates for an example run, with discrete jumps as new context measurements are incorporated.

State 1 0 10 20 30 40 50 60 State 2 0 20 40 60 80 100

120 Context-Aware Filter Accuracy for an Unstable System

True State Context-Aware Filter Estimates

(a) Example run. Note that each axis represents one state of the system. Time 0 50 100 150 200 250 300 350 400 450 Magnitude 0 2 4 6 8 10 12 14 16 18

20 Estimation Error For Ten Runs of an Unstable System

(b) Estimation error for ten runs. Time 0 50 100 150 200 250 300 350 400 450 Magnitude 0 0.2 0.4 0.6 0.8 1

1.2Trace of Covariance Matrix for Ten Runs of an Unstable System

(c) Trace of the covariance ma- trix for ten runs.

Figure 3.5: Illustration of the performance of the context-aware filter on an unstable system.

3.7.2

System with Unstable Dynamics

In the second simulation, we evaluate the performance of the context-aware filter on a system with unstable dynamics. The system dynamics are as follows:

xk+1 =   1.01 0 0 1.01  xk+νkp,

where νkp ∼ N(0,0.001I) and x0 = [1 1]T.6 30 context measurements are received

at each time, 15 with weightsbk,1 = [0 1]T and 15 with weightsbk,2 = [1 0]T; the 15

offsetsak are decreased linearly from 0 to -150 (i.e., they provide rough information

as to whether each state is between 0 and 10, 10 and 20, etc.).

Figure 3.5 shows the results of the simulation. We observe similar trends as in Figure 3.4, i.e., the trace of the covariance matrix (Figure 3.5c) converges over time, and the filter’s estimates seem to track the real system well after the initial period of uncertainty (Figure 3.5b). These results suggest that the context-aware filter does seem to converge over time (given certain observability-like conditions) and is likely asymptotically unbiased.

6Note that systems with larger-eigenvalue dynamics were tested as well with similar results; the

Time 50 100 150 200 250 300 350 400 450 500 Velocity (mph) 0 10 20 30 40 50 60

70 Velocity Estimates by Each Filter

Actual Velocity Kalman Filter Mean Context-Aware Filter Mean

Figure 3.6: Velocity estimates by each filter. Time 50 100 150 200 250 300 350 400 450 500 Magnitude 2 4 6 8 10 12 14 16

Absolute Errors by Each Filter

Kalman Filter Context-Aware Filter

Figure 3.7: Absolute errors by each fil- ter.

3.7.3

Velocity Estimation with Biased Measurements

Finally, we evaluate the sigmoid-based context-aware filter in a scenario with both plant (continuous) and context measurements; note that plant measurements are biased in order to illustrate the fact that context measurements can be used to improve estimation in scenarios where standard sensors are not sufficient. Once again, we use the LandShark robot as the experimental platform. In this case study, the LandShark is moving in a straight line in an urban environment, accelerating to a target velocity and then slowing down for intersections. The LandShark’s goal is to estimate its velocity in order to avoid collisions at intersections while moving as quickly as possible. Once again, it has access to GPS measurements to estimate velocity; however, the GPS velocity measurements have a negative bias at high speeds, thus potentially causing the LandShark to apply higher inputs and reach a dangerously high speed. In order to improve estimation, the LandShark can also measure air resistance at the front of the vehicle; while resistance cannot be mapped to speed in a straightforward fashion, it possible to establish whether the vehicle is moving beyond a certain velocity threshold. This information can be converted into a binary context measurement indicating that the LandShark is approaching its target velocity and can be consequently modeled using a sigmoid function.

To evaluate the performance of the sigmoid-based filter, we compare it with a Kalman filter that is only using the continuous measurements (note that a classical

Kalman filter is sufficient in this case since the vehicle is moving in a straight line). Figure 3.6 shows the estimates produced by each filter, including the actual velocity. Once again, the context measurements provide essential information that allows the system to significantly improve its state estimates and overcome the GPS bias, especially when running at high speeds. In addition, Figure 3.7 provides the absolute errors of each filter; the Kalman filter’s errors have a much larger variance and are invariably higher as well, similar to the localization scenario discussed above. Thus, this case study also supports the conclusion that the context-aware can be used to greatly improve estimation by incorporating binary context measurements.