727d6da1af
Removed the ability for any handler to use multiple instances by default
master
Erik Thuning
2025-02-06 15:43:19 +01:00
ae3ea546a2
Lowered the max number of lines per subtitle segment from 3 to 2
Erik Thuning
2025-02-06 15:41:49 +01:00
365a66bdfa
Added a limit to the number of characters per subtitle line
Erik Thuning
2025-02-06 10:24:48 +01:00
f455f95ce0
Stop seeking into the video for poster generation, just use the first frame.
Erik Thuning
2024-12-06 15:27:34 +01:00
cbf29c4962
Implementing a unified job pool for transcodes and subtitles never panned out, so the code was just adding unnecessary complexity. The pipeline now uses mp.pool to manage ffmpeg jobs as before.
Erik Thuning
2024-10-17 11:30:35 +02:00
3da736422d
Added a debug log line when the model has finished loading. Also removed some redundant info from the startup debug line.
Erik Thuning
2024-10-16 14:03:20 +02:00
dd0af2221f
Removed GPU code from transcode.py, since it never worked properly. Also cleaned out irrelevant options from config.ini.example.
Erik Thuning
2024-10-16 13:56:17 +02:00
27598d4401
Promoted subtitles_whisper_hack from hack status.
Erik Thuning
2024-10-14 16:34:46 +02:00
d6206f1e6b
Changed instantiation logic for whisper handler:
Erik Thuning
2024-10-14 16:26:31 +02:00
f1de6a19c4
Whitespace
Erik Thuning
2024-10-10 12:59:05 +02:00
f8ab46bac8
Added support for uploads with name prefix
Erik Thuning
2024-09-06 11:40:59 +02:00
11917608bb
Made raise_for_structure provide better feedback on errors
Erik Thuning
2024-06-18 11:26:20 +02:00
8de039a3f3
Fixed some bugs so the preprocessor works: - start time is now recorded as a timestamp - typo fix: match.groups() -> match.group() - Subtitle generation is only requested if the presentation has video on channel 1
Erik Thuning
2024-06-18 11:23:43 +02:00
1afa1b93af
Added env subdirectory to gitignore
Erik Thuning
2024-06-13 15:41:09 +02:00
4842ed56f1
Fixed several errors in the arec preprocessor
Erik Thuning
2024-06-13 15:37:21 +02:00
b7a3d7dec2
Activated the arec preprocessor
Erik Thuning
2024-06-13 15:36:25 +02:00
dec2da4310
Added a preprocessor for arec recorders. Also moved the code for creating a basic jobspec and pulling information from the relevant daisy booking into the preprocessor superclass so it can be called by both the cattura and arec preprocessors.
Erik Thuning
2024-06-04 15:49:07 +02:00
49d1da804b
Started seting the running flag immediately on the call to start() instead of after all the startup tsks are done. This alleviates a potential problem where start() could be called more than once in quick succession with unpredictable results.
Erik Thuning
2024-06-04 15:45:09 +02:00
37c2dbaec6
Merge branch 'master' of gitea.dsv.su.se:DMC/play-daemon-threaded
Erik Thuning
2024-03-27 10:50:33 +01:00
3d9075a5e0
Starting on a visibility handler
Erik Thuning
2024-03-27 10:50:09 +01:00
bfe68b9250
Fixed a typo
Erik Thuning
2024-03-27 10:40:31 +01:00
3a50515f7a
Merge branch 'master' of gitea.dsv.su.se:DMC/play-daemon-threaded
Erik Thuning
2024-03-26 15:50:47 +01:00
6c11d5578f
Added optional support for user-specified notification endpoints in packages
Erik Thuning
2024-03-26 15:47:39 +01:00
67f8dfc177
Added diagram outlining the pipeline flow
Erik Thuning2024-02-21 11:24:54 +01:00
19498e64f9
Added logging of contents of queue files from disk and preprocessed jobs
Erik Thuning
2024-02-16 11:58:05 +01:00
02341f0cd8
The original check was a bit hasty, this one should actually work properly.
Erik Thuning
2024-02-06 14:15:33 +01:00
8a0a9fbc33
Set the cattura preprocessor to automatically request subtitling based on the camera source.
Erik Thuning
2024-02-06 13:31:11 +01:00
9874390a78
Python complains if a dictionary is modified while using an iterator on it, so changing iterator to a list
Erik Thuning
2024-01-18 10:43:23 +01:00
35d7a057e3
Missed another import
Erik Thuning
2024-01-18 10:37:53 +01:00
2cbb501361
Forgot an import
Erik Thuning
2024-01-18 10:34:18 +01:00
bb76807921
Added logging when deleting job files
Erik Thuning
2024-01-18 10:32:13 +01:00
d28be73e2c
No longer setting explicit width, so that ffmpeg can take care of odd number oddness
Erik Thuning
2024-01-15 20:19:50 +01:00
7a2736300b
Made logging statements use consistent string formats and some minor related fixes
Erik Thuning
2023-12-21 14:41:11 +01:00
96f1e55286
Added a syslogidentifier line
Erik Thuning
2023-12-21 14:40:55 +01:00
18841b44d7
Switched to the hack version of SubtitlesWhisperHandler
Erik Thuning
2023-12-20 16:19:07 +01:00
b4f6ff8bde
Formatting
Erik Thuning
2023-12-20 16:18:43 +01:00
e19fb3c9a4
Added a hack version of parallel transcription until triton is fixed
Erik Thuning
2023-12-20 16:18:03 +01:00
a83efc62a5
Logging process information if log level is DEBUG or higher
Erik Thuning
2023-12-14 16:40:24 +01:00
622f7cbb61
Generating two subtitle tracks per job in the generation test
Erik Thuning
2023-12-14 16:37:16 +01:00
4283badaef
Saving intermediate subtitle files under the track name instead of the source name
Erik Thuning
2023-12-14 16:29:30 +01:00
784b365f1e
Switching to the serial whisper handler
Erik Thuning
2023-12-14 14:59:48 +01:00
51991d327b
Testing out a new approach to dispatching subtitle generation jobs. Hope to solve gpu assignment issues
Erik Thuning
2023-12-14 14:58:35 +01:00
c34ed2cc62
Updated the subtitles generation test to run several generation tasks
Erik Thuning
2023-12-12 15:39:19 +01:00
a5d9eef356
Switched the directory observer in QueueReader from inotify to polling, in order to properly handle NFS-mounted queue directories.
Erik Thuning
2023-12-08 11:32:16 +01:00
60150c98ab
Updated tests to reflect the split subtitles handlers
Erik Thuning
2023-11-30 16:48:37 +01:00
10c126a37c
Split subtitles handling into two handlers. One for generation and one for import.
Erik Thuning
2023-11-30 16:35:26 +01:00
2da06f84a7
Attempting to make sure all log lines get flushed, and fixed a variable name
Erik Thuning
2023-11-30 16:08:07 +01:00
f634fd4b1e
Documented the ability to force the language when generating subtitles
Erik Thuning
2023-11-30 15:51:14 +01:00
c7f6207cc6
Pointed out that the user running the daemon must be able to write to its home directory
Erik Thuning
2023-11-30 12:52:12 +01:00
881de4f699
Merged two log lines for better emails
Erik Thuning
2023-11-30 12:35:11 +01:00
a6ccb053d8
Removed an unnecessary try/except. Handler._process() already catches the exception in a sane way and hence no such handling is needed in SubtitlesHandler._handle()
Erik Thuning
2023-11-30 11:53:14 +01:00
b5eda4695f
Updated logging calls
Erik Thuning
2023-11-30 09:53:09 +01:00
6da6e92d46
Added script to clean up trash files
Erik Thuning
2023-11-24 16:22:42 +01:00
a0bba02840
Major updates to the subtitles handler with some knock-on effects - More than one subtitles handler can be run in parallel - Language can be specified in generation tasks - Switched to pathlib for path handling in subtitles handler (simpler) - Handlers are now instantiated via factory function
Erik Thuning
2023-11-24 16:17:51 +01:00
755b8e6839
Reduced the pool size in the tests for more sane error output
Erik Thuning
2023-11-23 15:44:07 +01:00
2ce11af099
Formatting
Erik Thuning
2023-11-23 15:43:38 +01:00
b81bd64ffd
Made it possible to have more than one handler of the same type by making the handler's queue an init parameter.
Erik Thuning
2023-11-23 15:41:42 +01:00
e75c1cc282
Added a clarifying comment about jobsize in relation to capacity
Erik Thuning
2023-11-22 11:11:38 +01:00
c5bfc9f8d5
Made queue items be processed chronologically on start
Erik Thuning
2023-11-22 10:03:54 +01:00
5641aef235
Fixed a crash caused by empty sequence
Erik Thuning
2023-11-22 09:44:00 +01:00
1b9c77fd84
Updated the readme
Erik Thuning
2023-11-17 12:40:51 +01:00
022949c3c2
Refactored the transcode pipeline - better exceptions - simpler handling of scaling - terrible nvidia encode results (still)
Erik Thuning
2023-11-10 14:27:32 +01:00
8f466a8e09
Changed ValidationException to ValueError in default preprocessor, in order to harmonize with errors thrown by raise_for_structure()
Erik Thuning
2023-11-08 10:30:17 +01:00
1e6c8ac178
Settled on how to stringify the error message from ffmpeg
Erik Thuning
2023-11-08 10:26:10 +01:00
10db80cbfa
Forgot an import
Erik Thuning
2023-11-08 10:22:48 +01:00
9bdb1dbef9
Trying to fix lack of newlines in ffmpeg errors
Erik Thuning
2023-10-26 09:49:13 +02:00
08a8db11b8
Accidentally a dict key
Erik Thuning
2023-10-25 16:03:40 +02:00
e08184e05b
Added an explicit check for existence of upload_dir if the job specifies it.
Erik Thuning
2023-10-19 11:22:12 +02:00
9b43bf5eee
Small tweak to avoid reserving space when nothing is waiting
Erik Thuning
2023-10-10 14:09:21 +02:00
2e8606b9a4
Fixed a duplicate header
Erik Thuning
2023-10-09 17:23:32 +02:00
f91109fb3e
Handlers have been switched to the new WorkThread class. config.ini.example updated to match.
Erik Thuning
2023-10-09 17:19:16 +02:00
291a828b1b
Removed dead code
Erik Thuning
2023-10-09 16:41:50 +02:00
6309f1f4a4
Added WorkThread, a class handling long-running jobs by means of a prioritized queue.
Erik Thuning
2023-10-09 16:39:55 +02:00
02d8c98665
Finished experimenting on nvidia options
Erik Thuning
2023-10-05 16:44:34 +02:00
88096714ff
More nvenc experiments
Erik Thuning
2023-10-04 15:25:01 +02:00
80cdf629c1
Removed obsolete variables in excpetion block
Erik Thuning
2023-10-04 15:13:08 +02:00
ae431e6902
Testing nvidia settings
Erik Thuning
2023-10-04 15:10:05 +02:00
2bc1621697
Fixed a typo
Erik Thuning
2023-10-04 15:07:34 +02:00
72e4a59101
Experimental nvidia settings
Erik Thuning
2023-10-04 15:06:00 +02:00
e9b6bb5376
Forgot an import
Erik Thuning
2023-10-04 14:11:36 +02:00
16a3a120ff
Preparing for hardware encoding support
Erik Thuning
2023-10-04 14:09:12 +02:00
c9187e5736
Fixed a missing qualifier in thumbnail.py
Erik Thuning
2023-10-02 16:51:29 +02:00
100aa9d4dc
Started caching generated package ids so they stay consistent across daemon restarts
Erik Thuning
2023-09-22 23:01:51 +02:00
42efec0fb5
Attempting to prevent threads from dying on errors
Erik Thuning
2023-09-22 21:08:45 +02:00
7b3eb380c0
Missed an instance of the creation key to be changed
Erik Thuning
2023-08-30 20:40:13 +02:00
8bc1ff6318
Removed an empty subtitles key from cattura preprocessing, and fixed a misnamed 'creation' key to the correct name 'created'
Erik Thuning
2023-08-30 14:58:31 +02:00
deeb55b73f
Fixed the courseSegmentInstance sorting bug and added reasoning for sorting in the first place
Erik Thuning
2023-08-29 11:23:04 +02:00
c0fe9a8cb1
Fixed a bug when sorting booking items
Erik Thuning
2023-08-29 10:29:06 +02:00
c2a1cf61a0
Changed a bunch of debug messages to info, to make logging slightly less verbose if needed.
Erik Thuning
2023-08-24 14:06:39 +02:00
b7f0f562a8
Fixed a use before set, and refactored to make it less likely
Erik Thuning
2023-08-24 13:40:10 +02:00
4f97bfe44e
Guarding against exceptions when applying handler results to package
Erik Thuning
2023-08-24 13:27:04 +02:00
787fb605e1
Subtitle replacement and deletion now works as expected
Erik Thuning
2023-06-15 10:59:54 +02:00
3970c21a02
Fixed a logic bug where valid subtitle specifications were being rejected
Erik Thuning
2023-06-15 10:09:13 +02:00
bc5b3932f1
Fixed some logical errors in subtitle generation
Erik Thuning
2023-05-25 09:31:44 +02:00
c9d99add9d
Re-work of transcode handling so that errors in transcoding can be properly reported with no crashes.
Erik Thuning
2023-05-24 14:48:13 +02:00
98595461a0
Fixed existing packages not getting loaded correctly due to a bad assumption about package base paths
Erik Thuning
2023-05-24 14:46:54 +02:00
a0996a9bba
The distributor thread will no longer crash if there is more than one pending job for a single package.
Erik Thuning
2023-05-16 11:22:24 +02:00
ee5c420f4b
package_id wasn't being assigned if it was supplied in the incoming package
Erik Thuning
2023-05-16 10:28:57 +02:00
51c67e9737
Fixed duration keyts still being around in places where they shouldn't
Erik Thuning
2023-04-20 14:02:12 +02:00