gst-python-ml 1.0.1__tar.gz → 1.0.2__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (80) hide show
  1. {gst_python_ml-1.0.1/plugins/python/gst_python_ml.egg-info → gst_python_ml-1.0.2}/PKG-INFO +64 -16
  2. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/README.md +61 -15
  3. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2/plugins/python/gst_python_ml.egg-info}/PKG-INFO +64 -16
  4. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/gst_python_ml.egg-info/requires.txt +2 -0
  5. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/pyproject.toml +3 -1
  6. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/COPYING +0 -0
  7. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/MANIFEST.in +0 -0
  8. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/__init__.py +0 -0
  9. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/base_aggregator.py +0 -0
  10. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/base_caption.py +0 -0
  11. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/base_classifier.py +0 -0
  12. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/base_llm.py +0 -0
  13. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/base_objectdetector.py +0 -0
  14. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/base_separate.py +0 -0
  15. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/base_transcribe.py +0 -0
  16. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/base_transform.py +0 -0
  17. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/base_translate.py +0 -0
  18. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/base_tts.py +0 -0
  19. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/caption_phi.py +0 -0
  20. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/caption_qwen.py +0 -0
  21. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/classifier.py +0 -0
  22. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/coquitts.py +0 -0
  23. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/data/soccer/app.py +0 -0
  24. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/data/soccer/botsort_people_reid.yaml +0 -0
  25. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/data/soccer/bytetrack_ball.yaml +0 -0
  26. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/demo_soccer.py +0 -0
  27. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/demucs.py +0 -0
  28. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/engine/__init__.py +0 -0
  29. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/engine/device_queue_pool.py +0 -0
  30. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/engine/engine_factory.py +0 -0
  31. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/engine/engine_manager.py +0 -0
  32. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/engine/litert_engine.py +0 -0
  33. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/engine/ml_engine.py +0 -0
  34. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/engine/onnx_engine.py +0 -0
  35. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/engine/openvino_engine.py +0 -0
  36. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/engine/pytorch_engine.py +0 -0
  37. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/engine/pytorch_vision_engine.py +0 -0
  38. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/engine/tensorflow_engine.py +0 -0
  39. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/gst_python_ml.egg-info/SOURCES.txt +0 -0
  40. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/gst_python_ml.egg-info/dependency_links.txt +0 -0
  41. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/gst_python_ml.egg-info/top_level.txt +0 -0
  42. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/kafkasink.py +0 -0
  43. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/llm.py +0 -0
  44. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/llm_stream_filter.py +0 -0
  45. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/log/__init__.py +0 -0
  46. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/log/global_logger.py +0 -0
  47. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/log/gst_logger.py +0 -0
  48. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/log/logger.py +0 -0
  49. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/log/logger_factory.py +0 -0
  50. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/mariantranslate.py +0 -0
  51. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/maskrcnn.py +0 -0
  52. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/objectdetector.py +0 -0
  53. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/overlay.py +0 -0
  54. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/overlay_counter.py +0 -0
  55. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/overlay_helper/__init__.py +0 -0
  56. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/overlay_helper/overlay_cairo.py +0 -0
  57. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/overlay_helper/overlay_opengl.py +0 -0
  58. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/overlay_helper/overlay_skia.py +0 -0
  59. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/overlay_helper/overlay_utils.py +0 -0
  60. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/overlay_helper/overlay_utils_interface.py +0 -0
  61. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/overlay_helper/overlay_vulkan.py +0 -0
  62. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/sepformer.py +0 -0
  63. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/stablediffusion.py +0 -0
  64. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/streamdemux.py +0 -0
  65. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/streammux.py +0 -0
  66. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/utils/__init__.py +0 -0
  67. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/utils/analytics_utils.py +0 -0
  68. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/utils/caption_utils.py +0 -0
  69. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/utils/format_converter.py +0 -0
  70. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/utils/gst_feature_manager.py +0 -0
  71. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/utils/metadata.py +0 -0
  72. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/utils/muxed_buffer_processor.py +0 -0
  73. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/utils/runtime_utils.py +0 -0
  74. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/video_transform.py +0 -0
  75. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/whisperlive.py +0 -0
  76. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/whisperspeechtts.py +0 -0
  77. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/whispertranscribe.py +0 -0
  78. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/plugins/python/yolo.py +0 -0
  79. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/setup.cfg +0 -0
  80. {gst_python_ml-1.0.1 → gst_python_ml-1.0.2}/tests/test_pipelines.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: gst-python-ml
3
- Version: 1.0.1
3
+ Version: 1.0.2
4
4
  Summary: An ML package for GStreamer
5
5
  Author-email: Aaron Boxer <aaron.boxer@collabora.com>
6
6
  Project-URL: Homepage, https://github.com/collabora/gst-python-ml
@@ -19,6 +19,8 @@ Requires-Dist: qwen-vl-utils[decord]==0.0.8
19
19
  Requires-Dist: autoawq==0.2.9
20
20
  Requires-Dist: accelerate==1.12.0
21
21
  Requires-Dist: bitsandbytes==0.46.1
22
+ Requires-Dist: opencv-python==4.10.0.84
23
+ Requires-Dist: opencv-contrib-python==4.10.0.84
22
24
  Requires-Dist: numpy
23
25
  Requires-Dist: huggingface-hub
24
26
  Requires-Dist: lap
@@ -81,13 +83,22 @@ sudo apt install -y python3-pip python3-venv \
81
83
  ```
82
84
 
83
85
  ##### Fedora
86
+
87
+ (adjust Fedora version from 42 to match your version number)
88
+
89
+ ```
90
+ sudo dnf install https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-42.noarch.rpm https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-42.noarch.rpm
91
+ sudo dnf update -y
92
+ sudo dnf install akmod-nvidia xorg-x11-drv-nvidia-cuda -y
93
+ ```
94
+
84
95
  ```
85
96
  sudo dnf upgrade -y
86
97
  sudo dnf install -y python3-pip \
98
+ python3-devel cairo cairo-devel cairo-gobject-devel pkgconfig git \
87
99
  gstreamer1-plugins-base gstreamer1-plugins-base-tools \
88
100
  gstreamer1-plugins-good gstreamer1-plugins-bad-free \
89
- gstreamer1-plugins-bad-free-devel python3-gstreamer1 \
90
- cairo cairo-devel git
101
+ gstreamer1-plugins-bad-free-devel python3-gstreamer1
91
102
  ```
92
103
 
93
104
 
@@ -102,6 +113,7 @@ curl -LsSf https://astral.sh/uv/install.sh | sh
102
113
  ```
103
114
  uv venv --system-site-packages
104
115
  source .venv/bin/activate
116
+ uv pip install --upgrade pip
105
117
  uv sync
106
118
  ```
107
119
 
@@ -124,7 +136,7 @@ git clone https://github.com/collabora/gst-python-ml.git
124
136
  #### Update .bashrc
125
137
 
126
138
  ```
127
- echo 'export GST_PLUGIN_PATH=$HOME/src/gst-python-ml/plugins:$GST_PLUGIN_PATH' >> ~/.bashrc
139
+ echo 'export GST_PLUGIN_PATH=$HOME/src/gst-python-ml/demos:$HOME/src/gst-python-ml/plugins:$GST_PLUGIN_PATH' >> ~/.bashrc
128
140
  source ~/.bashrc
129
141
  ```
130
142
 
@@ -156,23 +168,55 @@ sudo systemctl restart docker
156
168
  ```
157
169
 
158
170
  ##### Fedora
159
- ```
160
- curl -s -L https://nvidia.github.io/libnvidia-container/stable/rpm/nvidia-container-toolkit.repo | sudo tee /etc/yum.repos.d/
161
- nvidia-container-toolkit.repo
162
171
 
163
- sudo dnf install nvidia-container-toolkit
164
- sudo nvidia-ctk runtime configure --runtime=docker
165
- sudo nvidia-ctk runtime configure --runtime=containerd
166
- sudo systemctl restart containerd
167
- sudo systemctl restart docker
172
+ ```
173
+ sudo dnf install docker
174
+ sudo usermod -aG docker $USER
175
+ # Then either log out/in completely, or:
176
+ newgrp docker
168
177
  ```
169
178
 
170
- ##### Testing GPU Support
171
179
 
172
180
  ```
173
- docker pull nvidia/cuda:12.0.0-base-ubuntu22.04
174
- docker run --rm --runtime=nvidia --gpus all nvidia/cuda:12.0.0-base-ubuntu22.04 nvidia-smi
181
+ # 1. Add NVIDIA Container Toolkit repository
182
+ curl -s -L https://nvidia.github.io/libnvidia-container/stable/rpm/nvidia-container-toolkit.repo | \
183
+ sudo tee /etc/yum.repos.d/nvidia-container-toolkit.repo
175
184
 
185
+ # 2. Remove Fedora's conflicting partial package (if present)
186
+ sudo dnf remove -y golang-github-nvidia-container-toolkit 2>/dev/null || true
187
+
188
+ # 3. Install the full NVIDIA Container Toolkit
189
+ sudo dnf install -y nvidia-container-toolkit
190
+
191
+ # 4. Configure Docker to use the NVIDIA runtime as default
192
+ sudo mkdir -p /etc/docker
193
+ sudo tee /etc/docker/daemon.json > /dev/null <<EOF
194
+ {
195
+ "runtimes": {
196
+ "nvidia": {
197
+ "path": "/usr/bin/nvidia-container-runtime",
198
+ "runtimeArgs": []
199
+ }
200
+ },
201
+ "default-runtime": "nvidia"
202
+ }
203
+ EOF
204
+
205
+ # 5. Fix Fedora's broken dockerd ExecStart (required!)
206
+ sudo mkdir -p /etc/systemd/system/docker.service.d
207
+ sudo tee /etc/systemd/system/docker.service.d/override.conf >/dev/null <<EOF
208
+ [Service]
209
+ ExecStart=
210
+ ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock
211
+ EOF
212
+
213
+ # 6. Reload and restart Docker
214
+ sudo systemctl daemon-reload
215
+ sudo systemctl restart docker
216
+
217
+ # 7. Verify it works
218
+ docker info --format '{{.DefaultRuntime}}' # → should print: nvidia
219
+ docker run --rm --gpus all nvidia/cuda:12.0.0-base-ubuntu22.04 nvidia-smi
176
220
  ```
177
221
 
178
222
 
@@ -228,8 +272,12 @@ Run `gst-inspect-1.0 python` to list pyml elements.
228
272
  password = FOOBAR
229
273
  ```
230
274
 
231
- 2. `pip install setuptools wheel twine`
275
+ 2.
232
276
 
277
+ ```
278
+ pip install setuptools wheel twine
279
+ pip install --upgrade build
280
+ ```
233
281
  ## Build
234
282
 
235
283
  `python -m build`
@@ -40,13 +40,22 @@ sudo apt install -y python3-pip python3-venv \
40
40
  ```
41
41
 
42
42
  ##### Fedora
43
+
44
+ (adjust Fedora version from 42 to match your version number)
45
+
46
+ ```
47
+ sudo dnf install https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-42.noarch.rpm https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-42.noarch.rpm
48
+ sudo dnf update -y
49
+ sudo dnf install akmod-nvidia xorg-x11-drv-nvidia-cuda -y
50
+ ```
51
+
43
52
  ```
44
53
  sudo dnf upgrade -y
45
54
  sudo dnf install -y python3-pip \
55
+ python3-devel cairo cairo-devel cairo-gobject-devel pkgconfig git \
46
56
  gstreamer1-plugins-base gstreamer1-plugins-base-tools \
47
57
  gstreamer1-plugins-good gstreamer1-plugins-bad-free \
48
- gstreamer1-plugins-bad-free-devel python3-gstreamer1 \
49
- cairo cairo-devel git
58
+ gstreamer1-plugins-bad-free-devel python3-gstreamer1
50
59
  ```
51
60
 
52
61
 
@@ -61,6 +70,7 @@ curl -LsSf https://astral.sh/uv/install.sh | sh
61
70
  ```
62
71
  uv venv --system-site-packages
63
72
  source .venv/bin/activate
73
+ uv pip install --upgrade pip
64
74
  uv sync
65
75
  ```
66
76
 
@@ -83,7 +93,7 @@ git clone https://github.com/collabora/gst-python-ml.git
83
93
  #### Update .bashrc
84
94
 
85
95
  ```
86
- echo 'export GST_PLUGIN_PATH=$HOME/src/gst-python-ml/plugins:$GST_PLUGIN_PATH' >> ~/.bashrc
96
+ echo 'export GST_PLUGIN_PATH=$HOME/src/gst-python-ml/demos:$HOME/src/gst-python-ml/plugins:$GST_PLUGIN_PATH' >> ~/.bashrc
87
97
  source ~/.bashrc
88
98
  ```
89
99
 
@@ -115,23 +125,55 @@ sudo systemctl restart docker
115
125
  ```
116
126
 
117
127
  ##### Fedora
118
- ```
119
- curl -s -L https://nvidia.github.io/libnvidia-container/stable/rpm/nvidia-container-toolkit.repo | sudo tee /etc/yum.repos.d/
120
- nvidia-container-toolkit.repo
121
128
 
122
- sudo dnf install nvidia-container-toolkit
123
- sudo nvidia-ctk runtime configure --runtime=docker
124
- sudo nvidia-ctk runtime configure --runtime=containerd
125
- sudo systemctl restart containerd
126
- sudo systemctl restart docker
129
+ ```
130
+ sudo dnf install docker
131
+ sudo usermod -aG docker $USER
132
+ # Then either log out/in completely, or:
133
+ newgrp docker
127
134
  ```
128
135
 
129
- ##### Testing GPU Support
130
136
 
131
137
  ```
132
- docker pull nvidia/cuda:12.0.0-base-ubuntu22.04
133
- docker run --rm --runtime=nvidia --gpus all nvidia/cuda:12.0.0-base-ubuntu22.04 nvidia-smi
138
+ # 1. Add NVIDIA Container Toolkit repository
139
+ curl -s -L https://nvidia.github.io/libnvidia-container/stable/rpm/nvidia-container-toolkit.repo | \
140
+ sudo tee /etc/yum.repos.d/nvidia-container-toolkit.repo
134
141
 
142
+ # 2. Remove Fedora's conflicting partial package (if present)
143
+ sudo dnf remove -y golang-github-nvidia-container-toolkit 2>/dev/null || true
144
+
145
+ # 3. Install the full NVIDIA Container Toolkit
146
+ sudo dnf install -y nvidia-container-toolkit
147
+
148
+ # 4. Configure Docker to use the NVIDIA runtime as default
149
+ sudo mkdir -p /etc/docker
150
+ sudo tee /etc/docker/daemon.json > /dev/null <<EOF
151
+ {
152
+ "runtimes": {
153
+ "nvidia": {
154
+ "path": "/usr/bin/nvidia-container-runtime",
155
+ "runtimeArgs": []
156
+ }
157
+ },
158
+ "default-runtime": "nvidia"
159
+ }
160
+ EOF
161
+
162
+ # 5. Fix Fedora's broken dockerd ExecStart (required!)
163
+ sudo mkdir -p /etc/systemd/system/docker.service.d
164
+ sudo tee /etc/systemd/system/docker.service.d/override.conf >/dev/null <<EOF
165
+ [Service]
166
+ ExecStart=
167
+ ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock
168
+ EOF
169
+
170
+ # 6. Reload and restart Docker
171
+ sudo systemctl daemon-reload
172
+ sudo systemctl restart docker
173
+
174
+ # 7. Verify it works
175
+ docker info --format '{{.DefaultRuntime}}' # → should print: nvidia
176
+ docker run --rm --gpus all nvidia/cuda:12.0.0-base-ubuntu22.04 nvidia-smi
135
177
  ```
136
178
 
137
179
 
@@ -187,8 +229,12 @@ Run `gst-inspect-1.0 python` to list pyml elements.
187
229
  password = FOOBAR
188
230
  ```
189
231
 
190
- 2. `pip install setuptools wheel twine`
232
+ 2.
191
233
 
234
+ ```
235
+ pip install setuptools wheel twine
236
+ pip install --upgrade build
237
+ ```
192
238
  ## Build
193
239
 
194
240
  `python -m build`
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: gst-python-ml
3
- Version: 1.0.1
3
+ Version: 1.0.2
4
4
  Summary: An ML package for GStreamer
5
5
  Author-email: Aaron Boxer <aaron.boxer@collabora.com>
6
6
  Project-URL: Homepage, https://github.com/collabora/gst-python-ml
@@ -19,6 +19,8 @@ Requires-Dist: qwen-vl-utils[decord]==0.0.8
19
19
  Requires-Dist: autoawq==0.2.9
20
20
  Requires-Dist: accelerate==1.12.0
21
21
  Requires-Dist: bitsandbytes==0.46.1
22
+ Requires-Dist: opencv-python==4.10.0.84
23
+ Requires-Dist: opencv-contrib-python==4.10.0.84
22
24
  Requires-Dist: numpy
23
25
  Requires-Dist: huggingface-hub
24
26
  Requires-Dist: lap
@@ -81,13 +83,22 @@ sudo apt install -y python3-pip python3-venv \
81
83
  ```
82
84
 
83
85
  ##### Fedora
86
+
87
+ (adjust Fedora version from 42 to match your version number)
88
+
89
+ ```
90
+ sudo dnf install https://download1.rpmfusion.org/free/fedora/rpmfusion-free-release-42.noarch.rpm https://download1.rpmfusion.org/nonfree/fedora/rpmfusion-nonfree-release-42.noarch.rpm
91
+ sudo dnf update -y
92
+ sudo dnf install akmod-nvidia xorg-x11-drv-nvidia-cuda -y
93
+ ```
94
+
84
95
  ```
85
96
  sudo dnf upgrade -y
86
97
  sudo dnf install -y python3-pip \
98
+ python3-devel cairo cairo-devel cairo-gobject-devel pkgconfig git \
87
99
  gstreamer1-plugins-base gstreamer1-plugins-base-tools \
88
100
  gstreamer1-plugins-good gstreamer1-plugins-bad-free \
89
- gstreamer1-plugins-bad-free-devel python3-gstreamer1 \
90
- cairo cairo-devel git
101
+ gstreamer1-plugins-bad-free-devel python3-gstreamer1
91
102
  ```
92
103
 
93
104
 
@@ -102,6 +113,7 @@ curl -LsSf https://astral.sh/uv/install.sh | sh
102
113
  ```
103
114
  uv venv --system-site-packages
104
115
  source .venv/bin/activate
116
+ uv pip install --upgrade pip
105
117
  uv sync
106
118
  ```
107
119
 
@@ -124,7 +136,7 @@ git clone https://github.com/collabora/gst-python-ml.git
124
136
  #### Update .bashrc
125
137
 
126
138
  ```
127
- echo 'export GST_PLUGIN_PATH=$HOME/src/gst-python-ml/plugins:$GST_PLUGIN_PATH' >> ~/.bashrc
139
+ echo 'export GST_PLUGIN_PATH=$HOME/src/gst-python-ml/demos:$HOME/src/gst-python-ml/plugins:$GST_PLUGIN_PATH' >> ~/.bashrc
128
140
  source ~/.bashrc
129
141
  ```
130
142
 
@@ -156,23 +168,55 @@ sudo systemctl restart docker
156
168
  ```
157
169
 
158
170
  ##### Fedora
159
- ```
160
- curl -s -L https://nvidia.github.io/libnvidia-container/stable/rpm/nvidia-container-toolkit.repo | sudo tee /etc/yum.repos.d/
161
- nvidia-container-toolkit.repo
162
171
 
163
- sudo dnf install nvidia-container-toolkit
164
- sudo nvidia-ctk runtime configure --runtime=docker
165
- sudo nvidia-ctk runtime configure --runtime=containerd
166
- sudo systemctl restart containerd
167
- sudo systemctl restart docker
172
+ ```
173
+ sudo dnf install docker
174
+ sudo usermod -aG docker $USER
175
+ # Then either log out/in completely, or:
176
+ newgrp docker
168
177
  ```
169
178
 
170
- ##### Testing GPU Support
171
179
 
172
180
  ```
173
- docker pull nvidia/cuda:12.0.0-base-ubuntu22.04
174
- docker run --rm --runtime=nvidia --gpus all nvidia/cuda:12.0.0-base-ubuntu22.04 nvidia-smi
181
+ # 1. Add NVIDIA Container Toolkit repository
182
+ curl -s -L https://nvidia.github.io/libnvidia-container/stable/rpm/nvidia-container-toolkit.repo | \
183
+ sudo tee /etc/yum.repos.d/nvidia-container-toolkit.repo
175
184
 
185
+ # 2. Remove Fedora's conflicting partial package (if present)
186
+ sudo dnf remove -y golang-github-nvidia-container-toolkit 2>/dev/null || true
187
+
188
+ # 3. Install the full NVIDIA Container Toolkit
189
+ sudo dnf install -y nvidia-container-toolkit
190
+
191
+ # 4. Configure Docker to use the NVIDIA runtime as default
192
+ sudo mkdir -p /etc/docker
193
+ sudo tee /etc/docker/daemon.json > /dev/null <<EOF
194
+ {
195
+ "runtimes": {
196
+ "nvidia": {
197
+ "path": "/usr/bin/nvidia-container-runtime",
198
+ "runtimeArgs": []
199
+ }
200
+ },
201
+ "default-runtime": "nvidia"
202
+ }
203
+ EOF
204
+
205
+ # 5. Fix Fedora's broken dockerd ExecStart (required!)
206
+ sudo mkdir -p /etc/systemd/system/docker.service.d
207
+ sudo tee /etc/systemd/system/docker.service.d/override.conf >/dev/null <<EOF
208
+ [Service]
209
+ ExecStart=
210
+ ExecStart=/usr/bin/dockerd -H fd:// --containerd=/run/containerd/containerd.sock
211
+ EOF
212
+
213
+ # 6. Reload and restart Docker
214
+ sudo systemctl daemon-reload
215
+ sudo systemctl restart docker
216
+
217
+ # 7. Verify it works
218
+ docker info --format '{{.DefaultRuntime}}' # → should print: nvidia
219
+ docker run --rm --gpus all nvidia/cuda:12.0.0-base-ubuntu22.04 nvidia-smi
176
220
  ```
177
221
 
178
222
 
@@ -228,8 +272,12 @@ Run `gst-inspect-1.0 python` to list pyml elements.
228
272
  password = FOOBAR
229
273
  ```
230
274
 
231
- 2. `pip install setuptools wheel twine`
275
+ 2.
232
276
 
277
+ ```
278
+ pip install setuptools wheel twine
279
+ pip install --upgrade build
280
+ ```
233
281
  ## Build
234
282
 
235
283
  `python -m build`
@@ -7,6 +7,8 @@ qwen-vl-utils[decord]==0.0.8
7
7
  autoawq==0.2.9
8
8
  accelerate==1.12.0
9
9
  bitsandbytes==0.46.1
10
+ opencv-python==4.10.0.84
11
+ opencv-contrib-python==4.10.0.84
10
12
  numpy
11
13
  huggingface-hub
12
14
  lap
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "gst-python-ml"
7
- version = "1.0.1"
7
+ version = "1.0.2"
8
8
  description = "An ML package for GStreamer"
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.13"
@@ -26,6 +26,8 @@ dependencies = [
26
26
  "autoawq==0.2.9",
27
27
  "accelerate==1.12.0",
28
28
  "bitsandbytes==0.46.1",
29
+ "opencv-python==4.10.0.84",
30
+ "opencv-contrib-python==4.10.0.84",
29
31
  "numpy",
30
32
  "huggingface-hub",
31
33
  "lap",
File without changes
File without changes
File without changes