Bertonlome commited on
Commit
e7b5170
·
1 Parent(s): 3574a74

Fix arrow filtering: keep Human* when both UGV* and UAV* are performers

Browse files
Files changed (1) hide show
  1. python_dash_ia.py +4 -4
python_dash_ia.py CHANGED
@@ -224,13 +224,13 @@ def build_interdependence_figures(df, highlight_track=None):
224
 
225
  # If both UGV* and UAV* are top performers in the PREVIOUS task, only use UGV* as source
226
  if "UGV*" in prev_performers and "UAV*" in prev_performers:
227
- filtered_prev_performers = ["UGV*"]
228
  else:
229
  filtered_prev_performers = prev_performers
230
 
231
  # If both UGV* and UAV* are top performers in the CURRENT task, only draw arrows to UGV*
232
  if "UGV*" in curr_performers and "UAV*" in curr_performers:
233
- filtered_curr_performers = ["UGV*"]
234
  else:
235
  filtered_curr_performers = curr_performers
236
 
@@ -480,13 +480,13 @@ def build_combined_interdependence_figure(df, highlight_track=None):
480
 
481
  # If both UGV* and UAV* are top performers in the PREVIOUS task, only use UGV* as source
482
  if "UGV*" in prev_performers and "UAV*" in prev_performers:
483
- filtered_prev_performers = ["UGV*"]
484
  else:
485
  filtered_prev_performers = prev_performers
486
 
487
  # If both UGV* and UAV* are top performers in the CURRENT task, only draw arrows to UGV*
488
  if "UGV*" in curr_performers and "UAV*" in curr_performers:
489
- filtered_curr_performers = ["UGV*"]
490
  else:
491
  filtered_curr_performers = curr_performers
492
 
 
224
 
225
  # If both UGV* and UAV* are top performers in the PREVIOUS task, only use UGV* as source
226
  if "UGV*" in prev_performers and "UAV*" in prev_performers:
227
+ filtered_prev_performers = [p for p in prev_performers if p != "UAV*"]
228
  else:
229
  filtered_prev_performers = prev_performers
230
 
231
  # If both UGV* and UAV* are top performers in the CURRENT task, only draw arrows to UGV*
232
  if "UGV*" in curr_performers and "UAV*" in curr_performers:
233
+ filtered_curr_performers = [p for p in curr_performers if p != "UAV*"]
234
  else:
235
  filtered_curr_performers = curr_performers
236
 
 
480
 
481
  # If both UGV* and UAV* are top performers in the PREVIOUS task, only use UGV* as source
482
  if "UGV*" in prev_performers and "UAV*" in prev_performers:
483
+ filtered_prev_performers = [p for p in prev_performers if p != "UAV*"]
484
  else:
485
  filtered_prev_performers = prev_performers
486
 
487
  # If both UGV* and UAV* are top performers in the CURRENT task, only draw arrows to UGV*
488
  if "UGV*" in curr_performers and "UAV*" in curr_performers:
489
+ filtered_curr_performers = [p for p in curr_performers if p != "UAV*"]
490
  else:
491
  filtered_curr_performers = curr_performers
492