Config
ImageSamplerConfig
Bases: SamplerConfig
Configuration options for the image sampler.
Source code in video_sampler/config.py
124 125 126 127 128 129 |
|
SamplerConfig
Bases: BaseModel
Configuration options for the video sampler.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
min_frame_interval_sec |
float
|
The minimum time interval between sampled frames in seconds. Defaults to 1. |
required |
keyframes_only |
bool
|
Flag indicating whether to sample only keyframes. Defaults to True. |
required |
queue_wait |
float
|
The time to wait between checking the frame queue in seconds. Defaults to 0.1. |
required |
start_time_s |
int
|
The starting time for sampling in seconds. Defaults to 0. |
required |
end_time_s |
int
|
The ending time for sampling in seconds. None for no end. Defaults to None. |
required |
precise_seek |
bool
|
Flag indicating whether to use precise seeking. Defaults to False. Precise seeking is slower but more accurate. |
required |
debug |
bool
|
Flag indicating whether to enable debug mode. Defaults to False. |
required |
print_stats |
bool
|
Flag indicating whether to print sampling statistics. Defaults to False. |
required |
buffer_config |
dict[str, Any]
|
Configuration options for the frame buffer. Defaults to {"type": "entropy", "size": 15, "debug": True}. |
required |
gate_config |
dict[str, Any]
|
Configuration options for the frame gate. Defaults to {"type": "pass"}. |
required |
extractor_config |
dict[str, Any]
|
Configuration options for the extractor (keyword, audio). Defaults to None. |
required |
summary_config |
dict[str, Any]
|
Configuration options for the summary generator. Defaults to None. |
required |
Methods: str() -> str: Returns a string representation of the configuration.
Source code in video_sampler/config.py
38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 64 65 66 67 68 69 70 71 72 73 74 75 76 77 78 79 80 81 82 83 84 85 86 87 88 89 90 91 92 93 94 95 96 97 98 99 100 101 102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 |
|
SaveFormatConfig
Bases: BaseModel
Configuration options for the save format.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
encode_time_b64 |
bool
|
Encode time as base64 string. Avoids |
required |
avoid_dot |
bool
|
Avoid |
required |
include_filename |
bool
|
Include filename in the output path. Defaults to False. |
required |
Source code in video_sampler/config.py
7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 |
|