diff --git a/README.md b/README.md index 3ca61c9..16a9f76 100644 --- a/README.md +++ b/README.md @@ -23,11 +23,10 @@ Read the text 'kids feeding and playing with the horse' to generate a text embed - Encode video (default): ```python import towhee -towhee.dc(['./demo_video.mp4']) \ - .video_decode.ffmpeg(sample_type='uniform_temporal_subsample', args={'num_samples': 4}) \ - .runas_op(func=lambda x: [y for y in x]) \ - .video_text_embedding.frozen_in_time(model_name='frozen_in_time_base_16_244', modality='video', device='cpu') \ - .show() +towhee.glob('./archery.mp4') \ + .video_decode.ffmpeg() \ + .video_text_embedding.frozen_in_time(model_name='frozen_in_time_base_16_244', modality='video', device='cpu') \ + .show() ``` @@ -47,9 +46,8 @@ towhee.dc(['kids feeding and playing with the horse']) \ ```python import towhee -towhee.dc['path'](['./demo_video.mp4']) \ - .video_decode.ffmpeg['path', 'frames'](sample_type='uniform_temporal_subsample', args={'num_samples': 4}) \ - .runas_op['frames', 'frames'](func=lambda x: [y for y in x]) \ +towhee.glob['path']('./archery.mp4') \ + .video_decode.ffmpeg['path', 'frames']() \ .video_text_embedding.frozen_in_time['frames', 'vec'](model_name='frozen_in_time_base_16_244', modality='video', device='cpu') \ .select['path', 'vec']() \ .show(formatter={'path': 'video_path'}) diff --git a/demo_video.mp4 b/demo_video.mp4 deleted file mode 100755 index e6fb645..0000000 Binary files a/demo_video.mp4 and /dev/null differ diff --git a/result1.png b/result1.png index c0900f2..2f99f9e 100644 Binary files a/result1.png and b/result1.png differ diff --git a/result3.png b/result3.png index 958cbfe..5636810 100644 Binary files a/result3.png and b/result3.png differ