class Generate_Dataset: def __init__(self, video_path, save_path): self.resnet = ResNet() self.dataset = {} self.video_list = [] self.video_path = '' self.h5_file = h5py.File(save_path, 'w') print(save_path) self._set_video_list(video_path) def _set_video_list(self, video_path): # import pdb;pdb.set_trace() if os.path.isdir(video_path): self.video_path = video_path fileExt = r".mp4",".avi" self.video_list = [_ for _ in os.listdir(video_path) if _.endswith(fileExt)]
user16278360