removed scipy dependency