소스 검색

test: VAFE _keep_num test

main
Rob Hallam 2 달 전
부모
커밋
e7a9bae601
1개의 변경된 파일13개의 추가작업 그리고 1개의 파일을 삭제
  1. +13
    -1
      test/test_feature_extractors.py

+ 13
- 1
test/test_feature_extractors.py 파일 보기

@@ -310,7 +310,19 @@ class TestVideoActivityFeatureExtractor(unittest.TestCase):
test_extractor.teardown()
self.assertTrue(test_extractor.features)

# TODO: add sample video with activity to test _activitydetect()
def test_keep_num(self):
"""Test keep_num keeps 0"""
num_features = 1
min_duration = 0

video_source = TestSourceMedia().one_colour_silent_audio()
test_extractor = extractors.VideoActivityFeatureExtractor(input_files=video_source,
num_features=num_features,
min_duration=min_duration)
test_extractor.setup()
test_extractor.run()
test_extractor.teardown()
self.assertEqual(len(test_extractor.features), num_features)

class TestJSONFeatureExtractor(unittest.TestCase):
"""Test JSONFeatureExtractor"""


불러오는 중...
취소
저장