Wykres commitów

178 Commity (disable-codecov-comments)

Autor SHA1 Wiadomość Data
nyanpasu64 30a59c8e07 Add delayed_assert, to stereo overflow test 2018-11-17 22:01:00 -08:00
nyanpasu64 3bbb30d97e Add test for loud stereo overflowing 2018-11-17 21:49:41 -08:00
nyanpasu64 fade930f64 Rename trigger subsampling to stride 2018-11-17 16:10:00 -08:00
nyanpasu64 dcc705f0c2 Rename Wave.get_around() subsampling to stride 2018-11-17 16:10:00 -08:00
nyanpasu64 0acea45908 Add separate trigger and render_subsampling configs 2018-11-17 16:10:00 -08:00
nyanpasu64 7ce15a7f89 Merge branch 'render-refactor' 2018-11-16 17:11:52 -08:00
nyanpasu64 f794728a99 Update comments and TODO 2018-11-12 00:46:56 -08:00
nyanpasu64 88a79a97e8 Remove Renderer.set_colors(), move into constructor
Makes it simpler to create an impl which constructs all canvases
within __init__, not on first frame.
2018-11-05 15:45:38 -08:00
nyanpasu64 5c7db27862 Improve error message of test_renderer
If the foreground color is 136 instead of the right color,
this corresponds to the global foreground color #888888,
which means the per-channel foreground color wasn't applied.
2018-11-05 15:30:06 -08:00
nyanpasu64 342752febf Move LayoutConfig and RendererLayout to new file 2018-11-03 22:53:47 -07:00
nyanpasu64 62e8c800f4 Fix passing tuples/lists into RendererLayout 2018-11-03 22:51:42 -07:00
nyanpasu64 bc042c29d7 Choose between playback and encode via CLI, not config 2018-10-31 00:32:43 -07:00
nyanpasu64 3beaee923c [wip] Add PostTrigger and LocalPostTrigger
A post-processing trigger should have subsampling=1,
and no more post triggers.

LocalPostTrigger uses a parabolic cost function for shifting to find
edges. It doesn't work well and needs tweaking.
2018-10-30 18:01:38 -07:00
nyanpasu64 cc7b9b35ac Add ITriggerConfig.post and Trigger.post for trigger chaining
One would think `use_edge_trigger` should be an InitVar.
But it breaks test_trigger_subsampling() which is parameterized on
`cfg.use_edge_trigger` (and I want to keep it that way, not peek at
`cfg.post`).

I also copied test_trigger_subsampling to test_post_trigger_subsampling,
to test `cfg.post`.
2018-10-30 18:01:38 -07:00
nyanpasu64 6c4e128031 Add PerFrameCache class to cache period over multiple triggers 2018-10-30 18:01:38 -07:00
nyanpasu64 3fd37133da Fix test on Windows 2018-09-05 17:41:42 -07:00
nyanpasu64 355071d7c8 Add output test, ensure Ovgen closes pipe to ffmpeg 2018-08-29 01:08:05 -07:00
nyanpasu64 a62f1561cf Fix output pipeline tests (unique Popen mocks) 2018-08-29 00:57:08 -07:00
nyanpasu64 8f521529c2 Disable unit test (creates a popup window) 2018-08-28 03:21:57 -07:00
nyanpasu64 aae4646157 Properly terminate output processes (including exceptions) 2018-08-28 03:21:49 -07:00
nyanpasu64 f917c3bdc6 Fix bug where test_output writes to ./- instead of stdout
Also remove gibberish from test_output
2018-08-27 14:57:40 -07:00
nyanpasu64 ba17f64618 [wip] Fix loading YAML config from another directory
Bugs: FFmpeg writes to file named "-"
2018-08-27 04:48:35 -07:00
nyanpasu64 590aad12ba Add test for loading YAML config from another directory 2018-08-27 04:31:37 -07:00
nyanpasu64 e1c4bdbbdb Fix CLI YAML output path (should write to current dir) 2018-08-27 01:47:39 -07:00
nyanpasu64 74f260711c Add test for command-line write paths
Fails at the moment
2018-08-26 23:50:21 -07:00
nyanpasu64 7e93c60f9a Fix tests (CLI sink fixtures) 2018-08-26 23:48:36 -07:00
nyanpasu64 29798e7343 Increase trigger performance, cache and reuse data window
Reuses data window if period is within 1 semitone of saved window.
2018-08-26 19:33:34 -07:00
nyanpasu64 e42d235343 Rename trigger/render_width_ratio to trigger/render_width
trigger/render_width multiplies how wide the window is, in milliseconds.
2018-08-26 01:24:26 -07:00
nyanpasu64 494ce2bf69 Add ability to load legacy YAML files
Add Ignored and Alias fields to Config and CorrelationTriggerConfig.
2018-08-25 22:44:42 -07:00
nyanpasu64 98a13e9c5b Add Ignored object, for discarding config fields 2018-08-25 22:25:09 -07:00
nyanpasu64 56438bed5c Add Alias class, for config field aliasing 2018-08-25 22:19:09 -07:00
nyanpasu64 acffc1a55e Fix unit tests 2018-08-25 18:51:01 -07:00
nyanpasu64 cf0f716593 Add data padding/truncation functions (and unit tests) 2018-08-25 17:06:13 -07:00
nyanpasu64 ae9aa862e2 Fix unit tests 2018-08-25 16:35:09 -07:00
nyanpasu64 aa3e4fb8e1 Rename RENDER_PROFILING to PRINT_TIMESTAMP 2018-08-25 15:46:39 -07:00
nyanpasu64 d355fa728e Restrict test_channel_subsampling inputs to <= 100
Considerably speeds up Hypothesis test-case minimization when failures
occur.
2018-08-24 21:39:59 -07:00
nyanpasu64 effc60d064 Delete benchmark_trigger.py (outdated)
It's nice to have, but it calls CorrelationTriggerConfig incorrectly and
doesn't work.
2018-08-24 01:47:23 -07:00
nyanpasu64 a172fc33a9 Add test for nsamp and render_subsampling used for rendering 2018-08-24 01:47:23 -07:00
nyanpasu64 a2237e09d6 Cleanup unit-test files 2018-08-24 01:46:33 -07:00
nyanpasu64 ce3849cd54 Rename Wave.get_around(region_len) to region_nsamp 2018-08-24 01:05:46 -07:00
nyanpasu64 8466b9ab93 Add tests for subsampling 2018-08-24 00:05:57 -07:00
nyanpasu64 e9c0a21469 Remove unused Config.wav_prefix and update tests
It was intended that Channel.wav_path was stored and loaded relative to
Config.wav_prefix, but this was never implemented (neither saving nor
loading.)

This change simplifies code, and eliminates some inconsistency (Config.
master_audio was never planned to be relative to Config.wav_prefix).
2018-08-20 01:13:47 -07:00
nyanpasu64 245704256a Alter unit tests for CLI working directory YAML 2018-08-20 01:02:55 -07:00
nyanpasu64 55573852e6 Add unit tests for loading folders via CLI 2018-08-20 00:38:20 -07:00
nyanpasu64 2a19afce5f [wip] Add unit tests for CLI parser 2018-08-20 00:38:13 -07:00
nyanpasu64 d9555c101e Add unit test for YAML config loading validation 2018-08-19 16:15:51 -07:00
nyanpasu64 3cec61a2ac Ensure that Ovgen.outputs are closed upon exceptions
channels and outputs are loaded upon Ovgen.play(), not __init__ creation
2018-08-18 02:57:03 -07:00
nyanpasu64 6f09710999 Add tests to ensure Outputs are closed upon exceptions 2018-08-18 02:57:03 -07:00
nyanpasu64 3324ed1568 [renderer] Test default colors, and channel line-color overrides 2018-08-17 00:00:36 -07:00
nyanpasu64 74f47a6525 Add test for rendering to output 2018-08-16 22:21:18 -07:00
nyanpasu64 5f94be0329 Add test for renderer background/foreground colors 2018-08-16 22:21:18 -07:00
nyanpasu64 6e7b7f4048 Rearrange renderer unit tests 2018-08-15 22:39:48 -07:00
nyanpasu64 21d739cd4f Move layout rows/columns to class LayoutConfig 2018-08-14 21:24:09 -07:00
nyanpasu64 2f4ebece70 Move renderer layout calculation to class RendererLayout 2018-08-14 21:23:40 -07:00
nyanpasu64 4a25b41d22 Move MatplotlibRenderer.create_window parameter into cfg 2018-08-14 21:23:19 -07:00
nyanpasu64 06159555a1 Disable test for config type checking 2018-08-14 02:20:07 -07:00
nyanpasu64 8cce1d1414 Add support for subsampling in CorrelationTrigger and Wave 2018-07-29 06:35:47 -07:00
nyanpasu64 bdacafc33a Remove ffmpeg_subprocess_test.py (already implemented as FFmpegOutput) 2018-07-29 06:35:42 -07:00
nyanpasu64 be57d5765f Add unified ITrigger constructor, [wip] trigger subsampling 2018-07-29 06:35:39 -07:00
nyanpasu64 f2af4299b2 Import dataclass from config (either dataclasses or keyword_dataclasses) 2018-07-29 06:35:35 -07:00
nyanpasu64 7f0e1ccaba (Config YAML) Add support for always dumping default fields
@register_config(always_dump='field names || *')
2018-07-29 06:35:17 -07:00
nyanpasu64 1124c46f1e Type-check fields, when loading config dataclasses from YAML 2018-07-29 06:35:15 -07:00
nyanpasu64 648829b4d9 Exclude default fields from YAML dumping. Add dumping unit tests. 2018-07-25 05:19:46 -07:00
nyanpasu64 a87642b38c Rename register_dataclass to register_config 2018-07-25 05:19:45 -07:00
nyanpasu64 65655b2645 [wip] Make config classes dumpable via YAML, rename base configs 2018-07-25 05:19:45 -07:00
nyanpasu64 e1dfdd13da Fix benchmark_trigger.py 2018-07-25 05:19:23 -07:00
nyanpasu64 4fa9cbb615 Fix test_renderer.py 2018-07-24 04:52:12 -07:00
nyanpasu64 e4399640bc whatever 2018-07-22 03:51:29 -07:00
nyanpasu64 9816001f9d [wip] Frame capture and FFmpeg video output 2018-07-22 02:06:10 -07:00
nyanpasu64 4b91be9120 WIP code for piping images into ffmpeg (subprocess.Popen) 2018-07-22 00:38:20 -07:00
nyanpasu64 054ba642eb Test to ensure no FutureWarning when determining Wave type 2018-07-20 15:30:24 -07:00
nyanpasu64 980d375b34 Add trigger speed benchmark.
Results: single takes .77 ms, double takes .99 ms (with some variability).
So single precision float is significantly faster.
2018-07-20 02:07:07 -07:00
nyanpasu64 7a818c0cd3 Add unit tests for Wave 2018-07-20 01:23:41 -07:00
nyanpasu64 26e3f36375 Optimize imports 2018-07-20 01:11:56 -07:00
nyanpasu64 2ad624be03 RendererConfig calculates orientation based on nrows or ncols.
- Ensure either nrows or ncols is set.
- If neither, set ncols=1 (single column).
- Remove rows_first flag.

Add test_renderer.py
2018-07-15 23:42:17 -07:00
nyanpasu64 0bb26a1c20 Fix unit tests, add CorrelationTrigger.Config.use_edge_trigger 2018-07-15 06:04:50 -07:00
nyanpasu64 0e575d9792 Fix CorrelationTrigger 2018-07-14 15:42:10 -07:00
nyanpasu64 cd33fcee6e Add unit tests (interactive for now) 2018-07-14 03:36:49 -07:00