kpzhang93 / MTCNN_face_detection_alignment

Joint Face Detection and Alignment using Multi-task Cascaded Convolutional Neural Networks
MIT License
2.8k stars 1.01k forks source link

why resizing with a minus 127.5 and multiply 0.0078125 #24

Open flankechen opened 6 years ago

flankechen commented 6 years ago

in the detect_face.m line 34: im_data=(imResample(img,[hs ws],'bilinear')-127.5)*0.0078125;

how to understand this magic number?

ilyanelken commented 6 years ago

@flankechen 0.0078125 = 1 / 128

lx-onism commented 4 years ago

in the detect_face.m line 34: im_data=(imResample(img,[hs ws],'bilinear')-127.5)*0.0078125;

how to understand this magic number?

hello, my matlab meet an errot while excute the above code: Undefined function or variable 'imResample'. I don't know why and can not get answer by searching on the net.Could you help me? thanks a lot