Rob Hallam
180e98db84
fix: another tiny formatting fix
D'oh
pirms 2 mēnešiem
Rob Hallam
41a2e3298c
fix: fix formatting of issue links in README
pirms 2 mēnešiem
Rob Hallam
4d05d1472d
feat: add README
pirms 2 mēnešiem
Rob Hallam
2037cc3c2d
Merge branch 'feat-exemplar-scripts'
pirms 2 mēnešiem
Rob Hallam
65cb224d6b
feat: add two exemplar scripts
Fairly basic, could obviously be refactored but they are there to be exemplars
to give folks an idea of where they can start with the pipeline.
pirms 2 mēnešiem
Rob Hallam
4f1ba7a370
chore: add requirements.txt
pirms 2 mēnešiem
Rob Hallam
8d1866093c
Merge branch 'refactor-codequality'
pirms 2 mēnešiem
Rob Hallam
65e1a6665e
Merge branch 'feat-config'
Adds config to isualisation and JSON producers
pirms 2 mēnešiem
Rob Hallam
e0468baead
feat: [VidP] permit config output destination
pirms 2 mēnešiem
Rob Hallam
5ca6f9e9d0
test: [WordFE] cover non-batched
pirms 2 mēnešiem
Rob Hallam
c8d414565d
test: [WordFE] test call to model.transcribe()
pirms 2 mēnešiem
Rob Hallam
e7a9bae601
test: VAFE _keep_num test
pirms 2 mēnešiem
Rob Hallam
2327048212
fix: fix LaughFE broken test for no featurres & VAFE keep_num check
pirms 2 mēnešiem
Rob Hallam
c14745dcde
test: test _keep_num trimming overlap
pirms 2 mēnešiem
Rob Hallam
d4a11b6e29
refactor: move _keep_num to base FeatureExtractor class
pirms 2 mēnešiem
Rob Hallam
a6bd196e39
test: [LoudFE._keep_min] test min duration
pirms 2 mēnešiem
Rob Hallam
d72b9ea2a4
test: [VizProd] simple colour test
pirms 2 mēnešiem
Rob Hallam
55b532f1eb
test: fix LoudFE tests
pirms 2 mēnešiem
Rob Hallam
4bec7a8ecc
fix: stop FEs incorrectly dropping some Features
_keep_num() was incorrectly detecting overlaps
pirms 2 mēnešiem
Rob Hallam
3173babcff
test: add 'missing' tests
Identified when checking coverage while only testing utils
pirms 2 mēnešiem
Rob Hallam
4cf406935b
test: test Interval.overlaps()
pirms 2 mēnešiem
Rob Hallam
4a05a94784
feat: [Interval] add overlaps() method
Found to be useful when writing tests
pirms 2 mēnešiem
Rob Hallam
a9323196d6
Merge branch 'feat-exemplar-scripts'
pirms 2 mēnešiem
Rob Hallam
97401aa84f
fix: [LaughFE] restore check for input files
pirms 2 mēnešiem
Rob Hallam
0bd39a1415
feat: [VizP] different colours for different FEs
pirms 2 mēnešiem
Rob Hallam
c1ec2adb9f
feat: [VP] make compiling clips into a video optional
pirms 2 mēnešiem
Rob Hallam
eda55da82d
refactor: improve docstrings, move laughter FE loc to config
pirms 2 mēnešiem
Rob Hallam
460819d678
feat: Update LoudFE & VAFE to not keep adjacent features
Otherwise features tend to cluster
pirms 2 mēnešiem
Rob Hallam
2bea733906
Merge branch 'fix-vafe-and-loudfe' into feat-exemplar-scripts
pirms 2 mēnešiem
Rob Hallam
7c196e43b2
feat: adjust LoudFE._keen_num() to work as VAFE._keep_num
As with VAFE, update LoudFE to expand to min duration when keeping n features
see: 72fc6b563b
pirms 2 mēnešiem
Rob Hallam
72fc6b563b
feat: modify VAFE to keep only n expanded Features
The problem that I had overlooked until now (!!) due to only using small
exemplar videos for testing was that VideoActivityFeatureExtractor keeps
a fraction of small (0.5s) Features. This is not so problematic for a short
exemplar video, but ends up witha lot of jumpy Features in an actual source
video.
Fix approach:
Like LoudnessFE, keep a specific number and expand the duration (which I think I
will do for LoudnessFE too), dropping any that would be consumed in that range
pirms 2 mēnešiem
Rob Hallam
d0a1779421
Merge branch 'feat-adjusters' into feat-exemplar-scripts
pirms 2 mēnešiem
Rob Hallam
c53704cf7c
test: update mocket get_loudnesses & test _keep_num
pirms 2 mēnešiem
Rob Hallam
e716f5d80a
feat: [LoudFE] keep only N top loudness Features
add LoudAudioFeatureExtractor._num_features (set in init, default: 5)
add _keep_num -- takes list of loudnesses and keeps top N (default: 5)
pirms 2 mēnešiem
Rob Hallam
a793fe08ce
test: [TTA] add coverage of adjust()
Add test cases that require reducing the number of Features
pirms 2 mēnešiem
Rob Hallam
4e42137b33
test: [mocks] add convenience classmethod and __eq__
Facilitates unit tests of TTA
pirms 2 mēnešiem
Rob Hallam
dfb5cbd1ef
test: add tests of sorting first by score then by time
pirms 2 mēnešiem
Rob Hallam
d0935f950f
feat: [TTA] _sort_by_score_time()
Pull out a one-liner for test scenarios to facilitate testing adjust()
pirms 2 mēnešiem
Rob Hallam
e22ece92ba
test: [TTA: adjust] test adjustments that result in no change
Cases:
- no features
- features under target duration
- features equal to target duration
pirms 2 mēnešiem
Rob Hallam
5365d7d1e2
test: [_determine_margin] add TTA._STRATEGY.PERCENT unit tests
Test _determine_margin() with margins specified as percentage
pirms 2 mēnešiem
Rob Hallam
f253250239
feat: [TTA] add algo for dropping Features in adjust()
Tries to drop the lowest-scoring Features until the target time (range) is
reached. This is not optimised and a relatively naïve approach- there are many
inputs which would result in a non-ideal pruning.
pirms 2 mēnešiem
Rob Hallam
764083b001
fix: duration is an attribute of Interval, not Feature
pirms 2 mēnešiem
Rob Hallam
4ffe712ce2
test: [TTA] add unit tests for _determine_margin -- ABSOLUTE
pirms 2 mēnešiem
Rob Hallam
15ca7cb6fa
fix: negative total durations should not be possible
pirms 2 mēnešiem
Rob Hallam
43fe240c40
test: TargetTimeAdjuster - test init and _features_total_time
pirms 2 mēnešiem
Rob Hallam
62932f6b08
test: add test of generic Adjuster base class
pirms 2 mēnešiem
Rob Hallam
b025f0ea10
feat: [wip] TargetTimeAdjuster set up structure & helpers
TargetTimeAdjuster will adjust a list of Features until it is within an optional
margin of a target total duration.
Helper functions:
- _determine_margin() :: figure out the max and min cutoff times, considering
margin and margin strategy (percent / absolute)
- _features_total_time() :: basic sum of list of Features' durations
TODO: rename to TargetDurationAdjuster ? rename 'strategy' ??
pirms 2 mēnešiem
Rob Hallam
e46da363e0
feat: imlpement generic Adjuster class
Adjusters will be used to modify a list of Features. This could either be:
- to modify the overall set (eg to target a time)
- to modify individual Features
The most important Adjuster will be one that targets an overall time, eg:
"modify this list of Features such that their times add up to 1 minute (either ±
a % or a hard limit)"
@see : feature_extractors.py::FeatureExtractor
pirms 2 mēnešiem
Rob Hallam
391f838149
Merge branch 'test-fes-functional'
pirms 2 mēnešiem
Rob Hallam
1ea881fc67
test: add negative test for LaughFE
Also rename positive test to indicate that
pirms 2 mēnešiem