syncnet-python 0.1.0__tar.gz → 0.1.1__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 (61) hide show
  1. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/PKG-INFO +9 -3
  2. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/README.md +7 -1
  3. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/pyproject.toml +2 -2
  4. syncnet_python-0.1.1/syncnet/core/types.py +67 -0
  5. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python/__init__.py +1 -1
  6. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python.egg-info/PKG-INFO +9 -3
  7. syncnet_python-0.1.0/syncnet/core/types.py +0 -48
  8. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/CLAUDE.md +0 -0
  9. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/INSTALL.md +0 -0
  10. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/LICENSE +0 -0
  11. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/MANIFEST.in +0 -0
  12. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/example/speech.wav +0 -0
  13. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/example/video.avi +0 -0
  14. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/requirements.txt +0 -0
  15. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/script/SyncNetInstance.py +0 -0
  16. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/script/SyncNetModel.py +0 -0
  17. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/script/detectors/__init__.py +0 -0
  18. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/script/detectors/s3fd/__init__.py +0 -0
  19. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/script/detectors/s3fd/box_utils.py +0 -0
  20. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/script/detectors/s3fd/nets.py +0 -0
  21. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/script/run_syncnet_pipeline_on_1example.py +0 -0
  22. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/script/run_syncnet_pipeline_on_mocha_generation_on_mocha_bench.py +0 -0
  23. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/script/run_syncnet_pipeline_on_your_own_model_results.py +0 -0
  24. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/script/syncnet_pipeline.py +0 -0
  25. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/scripts/run_batch.py +0 -0
  26. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/scripts/run_example.py +0 -0
  27. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/setup.cfg +0 -0
  28. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/setup.py +0 -0
  29. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/__init__.py +0 -0
  30. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/cli.py +0 -0
  31. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/core/__init__.py +0 -0
  32. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/core/compat.py +0 -0
  33. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/core/inference.py +0 -0
  34. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/core/models.py +0 -0
  35. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/detectors/__init__.py +0 -0
  36. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/detectors/s3fd/__init__.py +0 -0
  37. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/detectors/s3fd/detector.py +0 -0
  38. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/detectors/s3fd/utils.py +0 -0
  39. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/pipeline/__init__.py +0 -0
  40. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/pipeline/config.py +0 -0
  41. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/pipeline/pipeline.py +0 -0
  42. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/utils/__init__.py +0 -0
  43. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/utils/exceptions.py +0 -0
  44. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/utils/face_detection.py +0 -0
  45. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet/utils/video.py +0 -0
  46. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python/SyncNetInstance.py +0 -0
  47. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python/SyncNetModel.py +0 -0
  48. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python/cli.py +0 -0
  49. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python/detectors/__init__.py +0 -0
  50. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python/detectors/s3fd/__init__.py +0 -0
  51. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python/detectors/s3fd/box_utils.py +0 -0
  52. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python/detectors/s3fd/nets.py +0 -0
  53. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python/run_syncnet_pipeline_on_1example.py +0 -0
  54. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python/run_syncnet_pipeline_on_mocha_generation_on_mocha_bench.py +0 -0
  55. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python/run_syncnet_pipeline_on_your_own_model_results.py +0 -0
  56. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python/syncnet_pipeline.py +0 -0
  57. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python.egg-info/SOURCES.txt +0 -0
  58. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python.egg-info/dependency_links.txt +0 -0
  59. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python.egg-info/entry_points.txt +0 -0
  60. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python.egg-info/requires.txt +0 -0
  61. {syncnet_python-0.1.0 → syncnet_python-0.1.1}/syncnet_python.egg-info/top_level.txt +0 -0
@@ -1,7 +1,7 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: syncnet-python
3
- Version: 0.1.0
4
- Summary: SyncNet: Audio-visual synchronization detection using deep learning
3
+ Version: 0.1.1
4
+ Summary: SyncNet: Audio-visual synchronization detection using deep learning. Updated version of https://github.com/joonson/syncnet_python for modern Python versions.
5
5
  Author: SyncNet Python Contributors
6
6
  Maintainer: SyncNet Python Contributors
7
7
  License: MIT
@@ -49,6 +49,8 @@ Dynamic: license-file
49
49
 
50
50
  Audio-visual synchronization detection using deep learning.
51
51
 
52
+ This is an updated version of the original [SyncNet implementation](https://github.com/joonson/syncnet_python) by Joon Son Chung, compatible with modern Python versions (3.9+).
53
+
52
54
  ## Overview
53
55
 
54
56
  SyncNet Python is a PyTorch implementation of the SyncNet model, which detects audio-visual synchronization in videos. It can identify lip-sync errors by analyzing the correspondence between mouth movements and spoken audio.
@@ -126,9 +128,13 @@ syncnet-python video.mp4 --device cpu
126
128
  - CUDA (optional but recommended)
127
129
  - FFmpeg
128
130
 
131
+ ## Credits
132
+
133
+ This package is based on the original [SyncNet implementation](https://github.com/joonson/syncnet_python) by Joon Son Chung.
134
+
129
135
  ## Citation
130
136
 
131
- If you use this code in your research, please cite:
137
+ If you use this code in your research, please cite the original paper:
132
138
 
133
139
  ```bibtex
134
140
  @inproceedings{chung2016out,
@@ -2,6 +2,8 @@
2
2
 
3
3
  Audio-visual synchronization detection using deep learning.
4
4
 
5
+ This is an updated version of the original [SyncNet implementation](https://github.com/joonson/syncnet_python) by Joon Son Chung, compatible with modern Python versions (3.9+).
6
+
5
7
  ## Overview
6
8
 
7
9
  SyncNet Python is a PyTorch implementation of the SyncNet model, which detects audio-visual synchronization in videos. It can identify lip-sync errors by analyzing the correspondence between mouth movements and spoken audio.
@@ -79,9 +81,13 @@ syncnet-python video.mp4 --device cpu
79
81
  - CUDA (optional but recommended)
80
82
  - FFmpeg
81
83
 
84
+ ## Credits
85
+
86
+ This package is based on the original [SyncNet implementation](https://github.com/joonson/syncnet_python) by Joon Son Chung.
87
+
82
88
  ## Citation
83
89
 
84
- If you use this code in your research, please cite:
90
+ If you use this code in your research, please cite the original paper:
85
91
 
86
92
  ```bibtex
87
93
  @inproceedings{chung2016out,
@@ -4,8 +4,8 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "syncnet-python"
7
- version = "0.1.0"
8
- description = "SyncNet: Audio-visual synchronization detection using deep learning"
7
+ version = "0.1.1"
8
+ description = "SyncNet: Audio-visual synchronization detection using deep learning. Updated version of https://github.com/joonson/syncnet_python for modern Python versions."
9
9
  readme = "README.md"
10
10
  requires-python = ">=3.9"
11
11
  license = {text = "MIT"}
@@ -0,0 +1,67 @@
1
+ """Type definitions for SyncNet components."""
2
+
3
+ from pathlib import Path
4
+ from typing import TypedDict
5
+ try:
6
+ from typing import TypeAlias, NotRequired
7
+ except ImportError:
8
+ # Python 3.9 compatibility
9
+ from typing import Dict, Tuple, List
10
+ TypeAlias = type
11
+ NotRequired = lambda x: x
12
+ import numpy as np
13
+ import torch
14
+
15
+ # Basic type aliases
16
+ if 'TypeAlias' in globals() and TypeAlias != type:
17
+ BBox: TypeAlias = tuple[float, float, float, float]
18
+ Frame: TypeAlias = np.ndarray
19
+ AudioData: TypeAlias = np.ndarray
20
+ MFCCFeatures: TypeAlias = np.ndarray
21
+ else:
22
+ # Python 3.9 compatibility
23
+ BBox = Tuple[float, float, float, float]
24
+ Frame = np.ndarray
25
+ AudioData = np.ndarray
26
+ MFCCFeatures = np.ndarray
27
+
28
+ # Detection types
29
+ class Detection(TypedDict):
30
+ """Face detection result."""
31
+ frame_idx: int
32
+ bbox: BBox
33
+ confidence: float
34
+ landmarks: NotRequired[np.ndarray]
35
+
36
+ # Track types
37
+ class Track(TypedDict):
38
+ """Face track information."""
39
+ frame: np.ndarray
40
+ bbox: np.ndarray
41
+ start_frame: int
42
+ end_frame: int
43
+
44
+ # Result types
45
+ class SyncResult(TypedDict):
46
+ """Synchronization result."""
47
+ offset: int
48
+ confidence: float
49
+ dists: list[float]
50
+ track_id: NotRequired[int]
51
+
52
+ class PipelineResult(TypedDict):
53
+ """Complete pipeline result."""
54
+ video_path: str | Path
55
+ sync_results: list[SyncResult]
56
+ num_tracks: int
57
+ processing_time: float
58
+ error: NotRequired[str]
59
+
60
+ # Model types
61
+ if 'TypeAlias' in globals() and TypeAlias != type:
62
+ ModelState: TypeAlias = dict[str, torch.Tensor]
63
+ EmbeddingBatch: TypeAlias = torch.Tensor # Shape: [batch_size, embedding_dim]
64
+ else:
65
+ # Python 3.9 compatibility
66
+ ModelState = Dict[str, torch.Tensor]
67
+ EmbeddingBatch = torch.Tensor
@@ -4,7 +4,7 @@ This package provides a PyTorch implementation of SyncNet for detecting
4
4
  synchronization between audio and video in multimedia content.
5
5
  """
6
6
 
7
- __version__ = "0.1.0"
7
+ __version__ = "0.1.1"
8
8
 
9
9
  # Import main components
10
10
  try:
@@ -1,7 +1,7 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: syncnet-python
3
- Version: 0.1.0
4
- Summary: SyncNet: Audio-visual synchronization detection using deep learning
3
+ Version: 0.1.1
4
+ Summary: SyncNet: Audio-visual synchronization detection using deep learning. Updated version of https://github.com/joonson/syncnet_python for modern Python versions.
5
5
  Author: SyncNet Python Contributors
6
6
  Maintainer: SyncNet Python Contributors
7
7
  License: MIT
@@ -49,6 +49,8 @@ Dynamic: license-file
49
49
 
50
50
  Audio-visual synchronization detection using deep learning.
51
51
 
52
+ This is an updated version of the original [SyncNet implementation](https://github.com/joonson/syncnet_python) by Joon Son Chung, compatible with modern Python versions (3.9+).
53
+
52
54
  ## Overview
53
55
 
54
56
  SyncNet Python is a PyTorch implementation of the SyncNet model, which detects audio-visual synchronization in videos. It can identify lip-sync errors by analyzing the correspondence between mouth movements and spoken audio.
@@ -126,9 +128,13 @@ syncnet-python video.mp4 --device cpu
126
128
  - CUDA (optional but recommended)
127
129
  - FFmpeg
128
130
 
131
+ ## Credits
132
+
133
+ This package is based on the original [SyncNet implementation](https://github.com/joonson/syncnet_python) by Joon Son Chung.
134
+
129
135
  ## Citation
130
136
 
131
- If you use this code in your research, please cite:
137
+ If you use this code in your research, please cite the original paper:
132
138
 
133
139
  ```bibtex
134
140
  @inproceedings{chung2016out,
@@ -1,48 +0,0 @@
1
- """Type definitions for SyncNet components."""
2
-
3
- from pathlib import Path
4
- from typing import TypeAlias, TypedDict, NotRequired
5
- import numpy as np
6
- import torch
7
-
8
- # Basic type aliases
9
- BBox: TypeAlias = tuple[float, float, float, float]
10
- Frame: TypeAlias = np.ndarray
11
- AudioData: TypeAlias = np.ndarray
12
- MFCCFeatures: TypeAlias = np.ndarray
13
-
14
- # Detection types
15
- class Detection(TypedDict):
16
- """Face detection result."""
17
- frame_idx: int
18
- bbox: BBox
19
- confidence: float
20
- landmarks: NotRequired[np.ndarray]
21
-
22
- # Track types
23
- class Track(TypedDict):
24
- """Face track information."""
25
- frame: np.ndarray
26
- bbox: np.ndarray
27
- start_frame: int
28
- end_frame: int
29
-
30
- # Result types
31
- class SyncResult(TypedDict):
32
- """Synchronization result."""
33
- offset: int
34
- confidence: float
35
- dists: list[float]
36
- track_id: NotRequired[int]
37
-
38
- class PipelineResult(TypedDict):
39
- """Complete pipeline result."""
40
- video_path: str | Path
41
- sync_results: list[SyncResult]
42
- num_tracks: int
43
- processing_time: float
44
- error: NotRequired[str]
45
-
46
- # Model types
47
- ModelState: TypeAlias = dict[str, torch.Tensor]
48
- EmbeddingBatch: TypeAlias = torch.Tensor # Shape: [batch_size, embedding_dim]
File without changes
File without changes
File without changes
File without changes