Calculating the log filename.
Simple open and write on log output.
PEP8