diff --git a/video_prediction_tools/data_preprocess/preprocess_data_step2.py b/video_prediction_tools/data_preprocess/preprocess_data_step2.py
index 73c65232df346a4fd073de9f9ead4693d75cee60..7d03e1f236247ae57c69f0744afb49d622d5479a 100644
--- a/video_prediction_tools/data_preprocess/preprocess_data_step2.py
+++ b/video_prediction_tools/data_preprocess/preprocess_data_step2.py
@@ -72,7 +72,7 @@ class ERA5Pkl2Tfrecords(ERA5Dataset):
         """
         Get the corresponding statistics file
         """
-        self.stats_file = os.path.join(self.input_dir, "statistics.json")
+        self.stats_file = os.path.join(os.path.dirname(self.input_dir), "statistics.json")
         print("Opening json-file: {0}".format(self.stats_file))
         if os.path.isfile(self.stats_file):
             with open(self.stats_file) as js_file: