freealise commited on
Commit
846b265
1 Parent(s): cc5de73

Update app.py

Browse files
Files changed (1) hide show
  1. app.py +4 -1
app.py CHANGED
@@ -76,15 +76,18 @@ def make_video(video_path, outdir='./vis_video_depth', encoder='vits'):
76
  ])
77
 
78
  if os.path.isfile(video_path):
79
- if video_path.endswith('txt'):
80
  with open(video_path, 'r') as f:
81
  lines = f.read().splitlines()
 
82
  else:
83
  filenames = [video_path]
 
84
  else:
85
  filenames = os.listdir(video_path)
86
  filenames = [os.path.join(video_path, filename) for filename in filenames if not filename.startswith('.')]
87
  filenames.sort()
 
88
 
89
  # os.makedirs(outdir, exist_ok=True)
90
 
 
76
  ])
77
 
78
  if os.path.isfile(video_path):
79
+ if video_path.endswith('vtt'):
80
  with open(video_path, 'r') as f:
81
  lines = f.read().splitlines()
82
+ print(lines[0])
83
  else:
84
  filenames = [video_path]
85
+ print(filenames[0])
86
  else:
87
  filenames = os.listdir(video_path)
88
  filenames = [os.path.join(video_path, filename) for filename in filenames if not filename.startswith('.')]
89
  filenames.sort()
90
+ print(filenames[0])
91
 
92
  # os.makedirs(outdir, exist_ok=True)
93