Calculate error rate and clean some useless print
Let print message more clearly