fixed display errors, using matplotlib 'Agg' backend