|
@@ -3,6 +3,7 @@ import os
|
|
|
import sys
|
|
|
import traceback
|
|
|
from datetime import date
|
|
|
+
|
|
|
import pandas as pd
|
|
|
import yaml
|
|
|
from loguru import logger
|
|
@@ -11,8 +12,8 @@ curr_path = os.path.abspath(os.path.dirname(__file__))
|
|
|
project_root_path = curr_path[:curr_path.find("video_to_word") + len("video_to_word")]
|
|
|
sys.path.append(project_root_path)
|
|
|
|
|
|
-from utils.common_func import mysql_replace_into
|
|
|
-from config.url_and_db import ai_word_engine, jeecg_product_engine
|
|
|
+from utils.common_func import mysql_replace_into
|
|
|
+from config.url_and_db import ai_word_engine, jeecg_engine
|
|
|
from get_material_and_script.get_material_from_kuaishou_kaiyan import GetMaterialFromKuaishouKaiyan
|
|
|
from get_material_and_script.get_material_from_ocean_engine import GetMaterialFromOceanEngine
|
|
|
from get_material_and_script.get_material_from_huichuang import GetMaterialFromHuiChuang
|
|
@@ -23,7 +24,6 @@ def get_material_and_script(start_time=""):
|
|
|
with open('/data/pythonProject/video_to_word/config/config.yaml', mode='r', encoding='utf-8') as f:
|
|
|
config = yaml.load(f.read(), Loader=yaml.FullLoader)
|
|
|
|
|
|
-
|
|
|
# 1-2 分批写入数据库的行数
|
|
|
chunk_size = config['chunk_size']
|
|
|
|
|
@@ -63,7 +63,7 @@ def get_material_and_script(start_time=""):
|
|
|
# 获取公司内部的优质素材
|
|
|
inst = GetMaterialFromHuiChuang(query_word=query_word,
|
|
|
logger=logger,
|
|
|
- jeecg_boot_db_engine=jeecg_product_engine,
|
|
|
+ jeecg_boot_db_engine=jeecg_engine,
|
|
|
ai_word_db_engine=ai_word_engine)
|
|
|
inst.get_video_basic_info()
|
|
|
if source_code == 3:
|