mirror of
https://github.com/qurator-spk/eynollah.git
synced 2025-06-09 04:09:54 +02:00
allow passing PIL image to Eynollah w/o disk I/O
This commit is contained in:
parent
ba561ec833
commit
4897cefdb7
6 changed files with 53 additions and 48 deletions
|
@ -1,10 +1,11 @@
|
|||
import cv2
|
||||
from pathlib import Path
|
||||
from qurator.eynollah.utils.pil_cv2 import check_dpi
|
||||
from tests.base import main
|
||||
|
||||
def test_dpi():
|
||||
fpath = Path(__file__).parent.joinpath('resources', 'kant_aufklaerung_1784_0020.tif')
|
||||
assert 300 == check_dpi(str(fpath))
|
||||
fpath = str(Path(__file__).parent.joinpath('resources', 'kant_aufklaerung_1784_0020.tif'))
|
||||
assert 230 == check_dpi(cv2.imread(fpath))
|
||||
|
||||
if __name__ == '__main__':
|
||||
main(__file__)
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue