Closed andreas-wolf closed 4 years ago
Example from geoparse.py;
try: prediction = self.country_model.predict(i['matrix']).transpose()[0] ranks = prediction.argsort()[::-1] labels = np.asarray(labels)[ranks] prediction = prediction[ranks] except ValueError: print(traceback.print_exc()) prediction = np.array([0]) labels = np.array([""])`
This spams the console with noise and makes operation unnecessarily difficult.
Please consider using a proper logger, which is best practice for libraries: https://docs.python.org/3/howto/logging.html#configuring-logging-for-a-library
You're totally right that using a real logger is the better way to do it. I don't have the time to convert it right now, but I'd welcome a PR.
Example from geoparse.py;
This spams the console with noise and makes operation unnecessarily difficult.
Please consider using a proper logger, which is best practice for libraries: https://docs.python.org/3/howto/logging.html#configuring-logging-for-a-library