Init_files can now count the number of frames