зеркало из
https://github.com/ssciwr/AMMICO.git
synced 2025-10-29 05:04:14 +02:00
* Apply thresholding to restrict the scope of facial expression recognition * fix test dict faces * remove approx * do not ignore data in subdirs * where does test_display come from * remove face analysis duplication * imageai sneaked into ci Co-authored-by: Inga Ulusoy <inga.ulusoy@uni-heidelberg.de>
17 строки
414 B
Python
17 строки
414 B
Python
import misinformation.faces as fc
|
|
import json
|
|
from pytest import approx
|
|
|
|
|
|
def test_analyse_faces():
|
|
mydict = {
|
|
"filename": "./test/data/IMG_2746.png",
|
|
}
|
|
mydict = fc.EmotionDetector(mydict).analyse_image()
|
|
|
|
with open("./test/data/example_faces.json", "r") as file:
|
|
out_dict = json.load(file)
|
|
|
|
for key in mydict.keys():
|
|
assert mydict[key] == out_dict[key]
|