Add support for Linux clipboard reading (#44)

* Allow clipboard reading on Linux using Pillow 10

* Update README.md to reflect Pillow changes

* Update README.md with Linux clipboard requirements

* Fix "Using CUDA;Using CPU" console output

* Add verbose option to help with debugging

* Restore wayland codepath for writing text to clipboard
This commit is contained in:
Mar2ck
2023-08-27 22:36:07 +01:00
committed by GitHub
parent ba1b0d94a8
commit ea21bb71b3
4 changed files with 18 additions and 15 deletions

View File

@@ -18,7 +18,7 @@ class MangaOcr:
if not force_cpu and torch.cuda.is_available():
logger.info('Using CUDA')
self.model.cuda()
if not force_cpu and torch.backends.mps.is_available():
elif not force_cpu and torch.backends.mps.is_available():
logger.info('Using MPS')
self.model.to('mps')
else: