Thank you for your reply.
I have tried to update matplotlib, but it cannot solve the problem: when I add:

from torch.utils.tensorboard import SummaryWriter
writer = SummaryWriter(’./runs/Classification’)
writer.add_scalar(“Loss/Train”,loss,epoch)

and using matplotlib to display any graph, it will get error:

Cannot mix incompatible Qt library (5.9.7) with this library (5.15.0)

I want to try uninstall Qt library 5.9.7, but I don’t know what command line can help me to do that (with pip or conda)?