You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
42 lines
1.4 KiB
42 lines
1.4 KiB
3 months ago
|
import pandas as pd
|
||
|
|
||
|
from get_300urls import get_300videos_urls
|
||
|
#def get_300videos_urls(keyword):
|
||
|
|
||
|
from get_danmu_about_AI import danmu_about_AI
|
||
|
#def danmu_about_AI(urls,keywords):
|
||
|
|
||
|
from generate_gif import generate_
|
||
|
#def generate_(file_path)
|
||
|
|
||
|
def main():
|
||
|
AI_tech = {
|
||
|
"直播转播8K超高清":["转播","8K","超高清"],
|
||
|
"智能辅助解说":["智能","辅助解说"],
|
||
|
"训练监测辅助":["训练监测","监测"],
|
||
|
"实时打分量化分析":["实时","打分","量化","分析"],
|
||
|
"3D全息视频技术":["3D","全息","视频技术"],
|
||
|
"无障碍建设为视障人士搭建设施":["无障碍","视障"],
|
||
|
"赛时安保辅助赛事管理":["安保""赛事管理"],
|
||
|
"信息咨询运动员专属GPT":["信息咨询","GPT"],
|
||
|
"智能裁判系统精确计算分数":["智能裁判","系统计算"],
|
||
|
"舆情监测实时侦测":["舆情","监测","侦测"],
|
||
|
"媒资修复史料焕新":["媒资","修复","史料"]
|
||
|
}
|
||
|
|
||
|
key = "2024巴黎奥运会"
|
||
|
urls = get_300videos_urls(key) #得到300个视频的URL
|
||
|
|
||
|
top_8_danmu,top_8_AI = danmu_about_AI(urls,AI_tech)
|
||
|
print(top_8_AI)
|
||
|
print(top_8_danmu)
|
||
|
|
||
|
df = pd.DataFrame({'danmu': top_8_danmu})
|
||
|
df.to_excel("danmu_data.xlsx", index=False,engine='openpyxl')
|
||
|
|
||
|
file_path = "danmu_data.xlsx"
|
||
|
generate_(file_path)
|
||
|
|
||
|
if __name__ == "__main__":
|
||
|
main()
|