Commit e4092f53 authored by 张彦钊's avatar 张彦钊

增加过滤掉上次预测过的用户功能

parent 48ed8b6d
......@@ -239,11 +239,15 @@ if __name__ == "__main__":
total_number = 0
# 增加缓存日记视频列表
cache_video_id = []
cache_device_city_list = []
while True:
data_set_cid = pd.read_csv(DIRECTORY_PATH + "data_set_cid.csv")["cid"].values.tolist()
total_video_id = get_video_id(cache_video_id)
cache_video_id = total_video_id
device_city_list = get_active_users()
# 过滤掉上次预测过的用户
device_city_list = list(set(device_city_list)-set(cache_device_city_list))
cache_device_city_list = device_city_list
total_number += len(device_city_list)
print("累计预测用户总数:{}".format(total_number))
if device_city_list != []:
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment