Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Why? Cannot close object, library is destroyed. This may cause a memory leak! #239

Open
Zhuyunfe opened this issue Aug 20, 2024 · 3 comments

Comments

@Zhuyunfe
Copy link

F:\myself\office\nougat-main>nougat 1.pdf -o f:\myself\office
E:\Python39\lib\site-packages\torch\functional.py:513: UserWarning: torch.meshgrid: in an upcoming release, it will be required to pass the indexing argument. (Triggered internally at C:\actions-runner_work\pytorch\pytorch\builder\windows\pytorch\aten\src\ATen\native\TensorShape.cpp:3610.)
return _VF.meshgrid(tensors, **kwargs) # type: ignore[attr-defined]
0%| | 0/3 [00:00<?, ?it/s]E:\Python39\lib\site-packages\nougat\model.py:437: UserWarning: var(): degrees of freedom is <= 0. Correction should be strictly less than the reduction factor (input numel divided by output numel). (Triggered internally at C:\actions-runner_work\pytorch\pytorch\builder\windows\pytorch\aten\src\ATen\native\ReduceOps.cpp:1808.)
return torch.var(self.values, 1) / self.values.shape[1]
WARNING:root:Found repetitions in sample 1
INFO:root:Processing file 1.pdf with 5 pages
33%|████████████████████████████ | 1/3 [00:09<00:18, 9.17s/it]WARNING:root:Found repetitions in sample 0
WARNING:root:Found repetitions in sample 1
67%|████████████████████████████████████████████████████████ | 2/3 [00:12<00:05, 5.54s/it]WARNING:root:Found repetitions in sample 0
100%|████████████████████████████████████████████████████████████████████████████████████| 3/3 [00:13<00:00, 4.47s/it]
-> Cannot close object, library is destroyed. This may cause a memory leak!

@Zhuyunfe
Copy link
Author

why ? I have installed transformers==4.38.2

@williamparson
Copy link

Try pip install transformers==4.25.1

@Zhuyunfe
Copy link
Author

pip install transformers==4.25.1

I've tried it but it still doesn't work

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants