Browse Source

video_rank

linfan 1 year ago
parent
commit
703595b647
1 changed files with 3 additions and 2 deletions
  1. 3 2
      video_rank.py

+ 3 - 2
video_rank.py

@@ -978,7 +978,7 @@ def video_sank_pos_rank(data, size, top_K, flow_pool_P, ab_Code='', exp_config=N
             break
         for recall_pos_config in recall_list:
             rand_num = random.random()
-            #print("rand_num:", rand_num)
+            print("choose_item:",recall_pos_config, "rand_num:", rand_num)
             for per_recall_item in recall_pos_config:
                 per_recall_name = per_recall_item[0]
                 per_recall_freq = per_recall_item[1]
@@ -992,6 +992,7 @@ def video_sank_pos_rank(data, size, top_K, flow_pool_P, ab_Code='', exp_config=N
                     for recall_item in per_recall:
                         vid = recall_item['videoId']
                         if vid in select_ids:
+                            print("exsited vid:", vid, "\t:", per_recall_name)
                             continue
                         recall_item['rand'] = rand_num
                         rov_recall_rank.append(recall_item)
@@ -1001,7 +1002,7 @@ def video_sank_pos_rank(data, size, top_K, flow_pool_P, ab_Code='', exp_config=N
                         else:
                             exp_recall_dict[per_recall_name] = 1
                         break
-    #print("rov_recall_rank:", rov_recall_rank)
+    print("rov_recall_rank:", rov_recall_rank)
     if len(rov_recall_rank)<4:
         rov_doudi_rank = region_h_recall_rank + sim_recall + u2i_recall + u2u2i_recall + w2v_recall +return_video_recall+ region_24h_recall_rank + rule_24h_recall_rank + rule_24h_dup_recall_rank
         for recall_item in rov_doudi_rank: