mne.
set_log_file
Set the log to print to a file.
fname : str, or None
Filename of the log to print to. If None, stdout is used. To suppress log outputs, use set_log_level(‘WARN’).
output_format : str
Format of the output messages. See the following for examples: https://docs.python.org/dev/howto/logging.html e.g., “%(asctime)s - %(levelname)s - %(message)s”.
Format of the output messages. See the following for examples:
https://docs.python.org/dev/howto/logging.html
e.g., “%(asctime)s - %(levelname)s - %(message)s”.
overwrite : bool | None
Overwrite the log file (if it exists). Otherwise, statements will be appended to the log (default). None is the same as False, but additionally raises a warning to notify the user that log entries will be appended.