move sim and log settings into individual run function