pdf2markdown/third_party/MinerU/tests/test_cli/conftest.py

11 lines
152 B
Python

import pytest
import torch
def clear_gpu_memory():
'''
clear GPU memory
'''
torch.cuda.empty_cache()
print("GPU memory cleared.")