fix critical bug in fa.py about zeros