liqian hai 1 ano
pai
achega
570b48bab4
Modificáronse 2 ficheiros con 8 adicións e 6 borrados
  1. 4 3
      ai_tag_task.py
  2. 4 3
      asr_task.py

+ 4 - 3
ai_tag_task.py

@@ -210,9 +210,10 @@ def timer_check():
             if not os.path.exists(asr_folder):
                 # 1分钟后重新检查
                 Timer(60, timer_check).start()
-            # 数据准备好,进行aiTag
-            ai_tags_new(project=project, table=table, dt=dt)
-            print(f"videos ai tag finished!")
+            else:
+                # 数据准备好,进行aiTag
+                ai_tags_new(project=project, table=table, dt=dt)
+                print(f"videos ai tag finished!")
 
         else:
             # 数据没准备好,1分钟后重新检查

+ 4 - 3
asr_task.py

@@ -122,9 +122,10 @@ def timer_check():
             if not os.path.exists(download_folder):
                 # 视频未下载好,1分钟后重新检查
                 Timer(60, timer_check).start()
-            # 数据准备好,进行asr
-            asr_process(project=project, table=table, dt=dt, cuda_id=cuda_id)
-            print(f"videos asr finished!")
+            else:
+                # 数据准备好,进行asr
+                asr_process(project=project, table=table, dt=dt, cuda_id=cuda_id)
+                print(f"videos asr finished!")
 
         else:
             # 数据没准备好,1分钟后重新检查