matplotlib在linux服务器画图 import matplotlib matplotlib.use('Agg') import matplotlib.pyplot as plt 注意语句顺序,use(‘Agg’)在plt之前