helpers ¶
Functions:
-
is_from_vs_module–Returns true if the module in which the obj was defined is VapourSynth.
-
lazy_load–Lazily load a package.
-
require_jet_dependency–Decorator that raises DependencyNotFoundError when a specific package is missing.
-
setup_logging–Configure global logging.
is_from_vs_module ¶
Returns true if the module in which the obj was defined is VapourSynth.
Source code in vsjetpack/helpers.py
18 19 20 21 22 23 24 25 26 27 28 29 30 31 | |
lazy_load ¶
lazy_load(
name: str,
package: str | None = None,
exc: Callable[[], Exception] | None = None,
) -> ModuleType
Lazily load a package.
Source code in vsjetpack/helpers.py
34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 | |
require_jet_dependency ¶
require_jet_dependency(
*name: Literal["scipy", "rich", "psutil"]
) -> Callable[[Callable[P, R]], Callable[P, R]]
Decorator that raises DependencyNotFoundError when a specific package is missing.
Source code in vsjetpack/helpers.py
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 | |
setup_logging ¶
Configure global logging.
Parameters:
-
(level¶str | int, default:INFO) –Log level. Defaults to INFO.
-
(kwargs¶Any, default:{}) –Arguments forwarded to logging.basicConfig
Source code in vsjetpack/helpers.py
102 103 104 105 106 107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 | |