Skip to content
Snippets Groups Projects
Commit aef9f0c5 authored by Anton Kullberg's avatar Anton Kullberg
Browse files

bug: fixed list comparison bug

parent 803804a6
No related branches found
No related tags found
No related merge requests found
......@@ -117,13 +117,13 @@ def plot_result_ex2_24(result):
fig.add_subplot(gs[1:, :])]
Yt = np.hstack(result['Y'])
yx, yy = radar_to_pos(Yt)
confirmed_id = [track['identity'] for track in result['confirmed_tracks']]
for track in result['tracks']:
x = np.vstack(track['x'])
t = np.hstack(track['t']).flatten()
assoc = np.hstack(track['associations']).flatten()
if track in result['confirmed_tracks']:
if track['identity'] in confirmed_id:
ls = '-'
l = ax[0].plot(t, track['identity']*np.ones(t.shape), ls=ls, markersize=3)[0]
ax[0].plot(assoc, track['identity']*np.ones(assoc.shape), ls='', color=l.get_color(), marker='x', markersize=6)
......
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Please register or to comment