Open icyzhang0923 opened 4 years ago
Have you solved this issue?
you should create it yourself with below code
import csv
base_dir = '/home/hbai/shukurullo/tsm/temporal-shift-module/data_frames/test'
csv_file_path = 'test_data.csv'
with open(csv_file_path, mode='w', newline='') as file: writer = csv.writer(file)
# Traverse through all class directories
for class_dir in os.listdir(base_dir):
class_path = os.path.join(base_dir, class_dir)
print(f'class_path: {class_path}')
if os.path.isdir(class_path):
# Traverse through all video files in the class directory
for video_file in os.listdir(class_path):
print(f'video_file: {video_file}')
video_path = os.path.join(class_path, video_file)
writer.writerow([class_dir, video_file])
print(f"CSV file '{csv_file_path}' created successfully.") '''
When I want to train the TSM model on kinetics, I do not find the file 'kinetics_val.csv', 'kinetics_train.csv'