增加对训练和推理中图片情况的判断
This commit is contained in:
@ -110,6 +110,17 @@ def add_detect_imgs(detect_imgs: List[ProjectDetectImg], session: Session):
|
||||
session.commit()
|
||||
|
||||
|
||||
def check_detect_img(detect_id: int, session: Session):
|
||||
"""
|
||||
查询推理集合中图片的数量
|
||||
:param detect_id:
|
||||
:param session:
|
||||
:return:
|
||||
"""
|
||||
query = session.query(ProjectDetectImg).filter_by(detect_id=detect_id)
|
||||
return query.count()
|
||||
|
||||
|
||||
def get_img_list(detect_id: int, session: Session):
|
||||
"""
|
||||
获取训练集合中的图片列表
|
||||
|
Reference in New Issue
Block a user