Spaces:
Sleeping
Sleeping
Update sonogram.py
Browse files- sonogram.py +2 -2
sonogram.py
CHANGED
|
@@ -112,7 +112,7 @@ class Sonogram():
|
|
| 112 |
min_duration_off=self.pipeline.segmentation.min_duration_off,
|
| 113 |
)
|
| 114 |
# keep track of group speakers
|
| 115 |
-
group_speakers = np.any(embeddingClasses >= 2,axis=1
|
| 116 |
start = None
|
| 117 |
for timeStep in range(group_speakers.shape[0]):
|
| 118 |
if group_speakers[timeStep] > 0:
|
|
@@ -181,7 +181,7 @@ class Sonogram():
|
|
| 181 |
individuals.add(sas[j])
|
| 182 |
if silenceCount > windowSize / 2:
|
| 183 |
decision = 'silence'
|
| 184 |
-
elif groupCount > windowSize / 2 or len(individuals) >
|
| 185 |
decision = 'group'
|
| 186 |
else:
|
| 187 |
decision = 'individual'
|
|
|
|
| 112 |
min_duration_off=self.pipeline.segmentation.min_duration_off,
|
| 113 |
)
|
| 114 |
# keep track of group speakers
|
| 115 |
+
group_speakers = np.any(embeddingClasses >= 2,axis=1)
|
| 116 |
start = None
|
| 117 |
for timeStep in range(group_speakers.shape[0]):
|
| 118 |
if group_speakers[timeStep] > 0:
|
|
|
|
| 181 |
individuals.add(sas[j])
|
| 182 |
if silenceCount > windowSize / 2:
|
| 183 |
decision = 'silence'
|
| 184 |
+
elif groupCount > windowSize / 2 or len(individuals) > 2:
|
| 185 |
decision = 'group'
|
| 186 |
else:
|
| 187 |
decision = 'individual'
|