Python how to turn off warning output

When coding, if you don't want to see the warning information output by the console,
you can turn off the output of the warning.The
specific method is as follows:
turn off the warning

import warnings
warnings.filterwarnings("ignore")

Add the above statement at the beginning of the file to close the warning

Guess you like

Origin www.cnblogs.com/MalcolmMeng/p/12694697.html
Recommended