diff --git a/modules/util/viirs_l1b_l2.py b/modules/util/viirs_l1b_l2.py
index 514dfe07414c7e95c80aa374536f114ed3cc7f19..7874eb2bba60087ba43cda779d760e80b99218b6 100644
--- a/modules/util/viirs_l1b_l2.py
+++ b/modules/util/viirs_l1b_l2.py
@@ -96,7 +96,9 @@ def run_all(directory, out_directory, day_night='ANY'):
     data_train_tiles = []
     f_cnt = 0
 
-    print('Start, number of files: ', len(data_files))
+    num_files = len(data_files)
+
+    print('Start, number of files: ', num_files)
 
     for idx, data_f in enumerate(data_files):
         # if idx % 4 == 0:  # if we want to skip some files
@@ -155,9 +157,7 @@ def run_all(directory, out_directory, day_night='ANY'):
             [data_train_tiles.append(data_tiles[k]) for k in range(n_vld, num)]
 
             f_cnt += 1
-            if f_cnt == 5:
-                f_cnt = 0
-
+            if (f_cnt % 5) == 0:
                 num_valid_samples = 0
                 if len(data_valid_tiles) > 0:
                     # label_valid = np.stack(label_valid_tiles)
@@ -177,7 +177,7 @@ def run_all(directory, out_directory, day_night='ANY'):
                 data_valid_tiles = []
                 data_train_tiles = []
 
-                print('  num_train_samples, num_valid_samples: ', num_train_samples, num_valid_samples)
+                print('  num_train_samples, num_valid_samples, progress % : ', num_train_samples, num_valid_samples, int(f_cnt/num_files)*100)
                 total_num_train_samples += num_train_samples
                 total_num_valid_samples += num_valid_samples