Python Complex Number Fitting