log to file and finish collecting results