luannd / MinutiaeNet

Code and models for paper "Robust Minutiae Extractor: Integrating Deep Networks and Fingerprint Domain Knowledge" at International Conference on Biometrics (ICB) 2018
https://arxiv.org/pdf/1712.09401.pdf
MIT License
132 stars 45 forks source link

NameError: name 'reduce' is not defined #6

Closed wajihullahbaig closed 6 years ago

wajihullahbaig commented 6 years ago
MinutiaeNet-master/CoarseNet/CoarseNet_utils.py in merge_sum(x)
    193     return reduce(lambda x,y:x*y, x)
    194 def merge_sum(x):
--> 195     return reduce(lambda x,y:x+y, x)
    196 
    197 

NameError: name 'reduce' is not defined

Could not find the function mentioned above

luannd commented 6 years ago

This is another question with python 3. You can read this link for more details. The problem can be fixed by from functools import reduce in python 3. If it solves, let me know and I will close this issue.

wajihullahbaig commented 6 years ago

Thank you for the reply. Yes it was a Python3 error. I have forked your code and I am making it Python3 compatible. You can find it here. https://github.com/wajihullahbaig/MinutiaeNet

You can close this issue.