check if exists output dir in stats.py