"git@developer.sourcefind.cn:OpenDAS/mmdetection3d.git" did not exist on "fc5d477a973d9b0ed7143642347855a0a05a58bf"
Unverified Commit b28137cf authored by Xiaomeng Zhao's avatar Xiaomeng Zhao Committed by GitHub
Browse files

Merge pull request #2837 from myhloli/dev

fix: enhance memory cleaning condition to check model list length
parents 23bb3587 f41fc406
...@@ -236,7 +236,7 @@ def result_to_middle_json(model_list, images_list, pdf_doc, image_writer, lang=N ...@@ -236,7 +236,7 @@ def result_to_middle_json(model_list, images_list, pdf_doc, image_writer, lang=N
"""清理内存""" """清理内存"""
pdf_doc.close() pdf_doc.close()
if os.getenv('MINERU_DONOT_CLEAN_MEM') is None: if os.getenv('MINERU_DONOT_CLEAN_MEM') is None and len(model_list) >= 10:
clean_memory(get_device()) clean_memory(get_device())
return middle_json return middle_json
......
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