nkululeko 0.45.0__tar.gz → 0.45.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.
- {nkululeko-0.45.0 → nkululeko-0.45.2}/CHANGELOG.md +7 -0
- {nkululeko-0.45.0/nkululeko.egg-info → nkululeko-0.45.2}/PKG-INFO +8 -2
- {nkululeko-0.45.0 → nkululeko-0.45.2}/README.md +0 -1
- nkululeko-0.45.2/nkululeko/constants.py +1 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/experiment.py +19 -15
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/explore.py +3 -2
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/util.py +6 -1
- {nkululeko-0.45.0 → nkululeko-0.45.2/nkululeko.egg-info}/PKG-INFO +8 -2
- {nkululeko-0.45.0 → nkululeko-0.45.2}/setup.cfg +1 -1
- nkululeko-0.45.0/nkululeko/constants.py +0 -1
- {nkululeko-0.45.0 → nkululeko-0.45.2}/LICENSE +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/__init__.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/augment.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/augmenter.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/balancer.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/cacheddataset.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/dataset.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/dataset_csv.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/dataset_ravdess.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/demo.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/demo_predictor.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/feats_analyser.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/feats_audmodel.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/feats_audmodel_dim.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/feats_clap.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/feats_import.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/feats_mld.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/feats_opensmile.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/feats_oxbow.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/feats_praat.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/feats_trill.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/feats_wav2vec2.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/feature_extractor.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/featureset.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/feinberg_praat.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/filter_data.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/glob_conf.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/loss_ccc.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/loss_softf1loss.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model_bayes.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model_cnn.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model_gmm.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model_knn.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model_knn_reg.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model_mlp.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model_mlp_regression.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model_svm.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model_svr.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model_tree.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model_tree_reg.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model_xgb.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/model_xgr.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/modelrunner.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/nkululeko.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/plots.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/reporter.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/result.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/runmanager.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/scaler.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/test.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko/test_predictor.py +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko.egg-info/SOURCES.txt +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko.egg-info/dependency_links.txt +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko.egg-info/requires.txt +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/nkululeko.egg-info/top_level.txt +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/pyproject.toml +0 -0
- {nkululeko-0.45.0 → nkululeko-0.45.2}/setup.py +0 -0
@@ -6,6 +6,13 @@ Version 0.44.1
|
|
6
6
|
* bugfixing: feature importance: https://github.com/felixbur/nkululeko/issues/23
|
7
7
|
* bugfixing: loading csv database with filewise index https://github.com/felixbur/nkululeko/issues/24
|
8
8
|
|
9
|
+
Version 0.45.2
|
10
|
+
--------------
|
11
|
+
* added sample_selection for sample distribution plots
|
12
|
+
|
13
|
+
Version 0.45.1
|
14
|
+
--------------
|
15
|
+
* fixed dataframe.append bug
|
9
16
|
|
10
17
|
Version 0.45.0
|
11
18
|
--------------
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: nkululeko
|
3
|
-
Version: 0.45.
|
3
|
+
Version: 0.45.2
|
4
4
|
Summary: Machine learning audio prediction experiments based on templates
|
5
5
|
Home-page: https://github.com/felixbur/nkululeko
|
6
6
|
Author: Felix Burkhardt
|
@@ -123,7 +123,6 @@ There's my [blog](http://blog.syntheticspeech.de/?s=nkululeko) with tutorials:
|
|
123
123
|
* [Combine feature sets](http://blog.syntheticspeech.de/2022/06/30/how-to-combine-feature-sets-with-nkululeko/)
|
124
124
|
* [Classifying continuous variables](http://blog.syntheticspeech.de/2022/01/26/nkululeko-classifying-continuous-variables/)
|
125
125
|
* [Try out / demo a trained model](http://blog.syntheticspeech.de/2022/01/24/nkululeko-try-out-demo-a-trained-model/)
|
126
|
-
* [Plot distributions of feature values](http://blog.syntheticspeech.de/2023/02/16/nkululeko-how-to-plot-distributions-of-feature-values/)
|
127
126
|
* [Perform cross database experiments](http://blog.syntheticspeech.de/2021/10/05/nkululeko-perform-cross-database-experiments/)
|
128
127
|
* [Meta parameter optimization](http://blog.syntheticspeech.de/2021/09/03/perform-optimization-with-nkululeko/)
|
129
128
|
* [How to set up wav2vec embedding](http://blog.syntheticspeech.de/2021/12/03/how-to-set-up-wav2vec-embedding-for-nkululeko/)
|
@@ -217,6 +216,13 @@ Version 0.44.1
|
|
217
216
|
* bugfixing: feature importance: https://github.com/felixbur/nkululeko/issues/23
|
218
217
|
* bugfixing: loading csv database with filewise index https://github.com/felixbur/nkululeko/issues/24
|
219
218
|
|
219
|
+
Version 0.45.2
|
220
|
+
--------------
|
221
|
+
* added sample_selection for sample distribution plots
|
222
|
+
|
223
|
+
Version 0.45.1
|
224
|
+
--------------
|
225
|
+
* fixed dataframe.append bug
|
220
226
|
|
221
227
|
Version 0.45.0
|
222
228
|
--------------
|
@@ -107,7 +107,6 @@ There's my [blog](http://blog.syntheticspeech.de/?s=nkululeko) with tutorials:
|
|
107
107
|
* [Combine feature sets](http://blog.syntheticspeech.de/2022/06/30/how-to-combine-feature-sets-with-nkululeko/)
|
108
108
|
* [Classifying continuous variables](http://blog.syntheticspeech.de/2022/01/26/nkululeko-classifying-continuous-variables/)
|
109
109
|
* [Try out / demo a trained model](http://blog.syntheticspeech.de/2022/01/24/nkululeko-try-out-demo-a-trained-model/)
|
110
|
-
* [Plot distributions of feature values](http://blog.syntheticspeech.de/2023/02/16/nkululeko-how-to-plot-distributions-of-feature-values/)
|
111
110
|
* [Perform cross database experiments](http://blog.syntheticspeech.de/2021/10/05/nkululeko-perform-cross-database-experiments/)
|
112
111
|
* [Meta parameter optimization](http://blog.syntheticspeech.de/2021/09/03/perform-optimization-with-nkululeko/)
|
113
112
|
* [How to set up wav2vec embedding](http://blog.syntheticspeech.de/2021/12/03/how-to-set-up-wav2vec-embedding-for-nkululeko/)
|
@@ -0,0 +1 @@
|
|
1
|
+
VERSION = '0.45.2'
|
@@ -247,17 +247,20 @@ class Experiment:
|
|
247
247
|
def plot_distribution(self):
|
248
248
|
"""Plot the distribution of samples and speaker per target class and biological sex"""
|
249
249
|
plot = Plots()
|
250
|
-
|
251
|
-
|
252
|
-
|
253
|
-
|
254
|
-
|
255
|
-
|
256
|
-
|
250
|
+
sample_selection = self.util.config_val('EXPL', 'sample_selection', 'all')
|
251
|
+
if sample_selection=='all':
|
252
|
+
df_labels = pd.concat([self.df_train, self.df_test])
|
253
|
+
self.util.copy_flags(self.df_train, df_labels)
|
254
|
+
elif sample_selection=='train':
|
255
|
+
df_labels = self.df_train
|
256
|
+
self.util.copy_flags(self.df_train, df_labels)
|
257
|
+
elif sample_selection=='test':
|
258
|
+
df_labels = self.df_test
|
259
|
+
self.util.copy_flags(self.df_test, df_labels)
|
257
260
|
else:
|
258
|
-
|
259
|
-
|
260
|
-
|
261
|
+
self.util.error(f'unkown sample selection specifier {sample_selection}, should be [all | train | test]')
|
262
|
+
|
263
|
+
plot.describe_df(f'{sample_selection}_set', df_labels, self.target, f'{sample_selection}_distplot')
|
261
264
|
|
262
265
|
def extract_test_feats(self):
|
263
266
|
self.feats_test = pd.DataFrame()
|
@@ -303,7 +306,7 @@ class Experiment:
|
|
303
306
|
# self.df_train = self.df_train.append(df_train_aug)
|
304
307
|
|
305
308
|
|
306
|
-
def analyse_features(self):
|
309
|
+
def analyse_features(self, needs_feats):
|
307
310
|
"""
|
308
311
|
Do a feature exploration
|
309
312
|
|
@@ -311,7 +314,8 @@ class Experiment:
|
|
311
314
|
|
312
315
|
if self.util.config_val('EXPL', 'value_counts', False):
|
313
316
|
self.plot_distribution()
|
314
|
-
|
317
|
+
if not needs_feats:
|
318
|
+
return
|
315
319
|
sample_selection = self.util.config_val('EXPL', 'sample_selection', 'False')
|
316
320
|
if sample_selection=='all':
|
317
321
|
df_feats = pd.concat([self.feats_train, self.feats_test])
|
@@ -325,7 +329,7 @@ class Experiment:
|
|
325
329
|
elif sample_selection=='False':
|
326
330
|
pass
|
327
331
|
else:
|
328
|
-
self.util.error(f'unkown
|
332
|
+
self.util.error(f'unkown sample selection specifier {sample_selection}, should be [all | train | test]')
|
329
333
|
if sample_selection in ('all', 'train', 'test'):
|
330
334
|
feat_analyser = FeatureAnalyser(sample_selection, df_labels, df_feats)
|
331
335
|
feat_analyser.analyse()
|
@@ -336,8 +340,8 @@ class Experiment:
|
|
336
340
|
scatters = ast.literal_eval(glob_conf.config['EXPL']['scatter'])
|
337
341
|
if self.util.exp_is_classification():
|
338
342
|
plots = Plots()
|
339
|
-
all_feats =self.feats_train
|
340
|
-
all_labels = self.df_train['class_label']
|
343
|
+
all_feats = pd.concat([self.feats_train, self.feats_test])
|
344
|
+
all_labels = pd.concat([self.df_train['class_label'], self.df_test['class_label']])
|
341
345
|
for scatter in scatters:
|
342
346
|
plots.scatter_plot(all_feats, all_labels, scatter)
|
343
347
|
else:
|
@@ -42,12 +42,13 @@ def main(src_dir):
|
|
42
42
|
scatter = eval(util.config_val('EXPL', 'scatter', 'False'))
|
43
43
|
model_type = util.config_val('EXPL', 'model', False)
|
44
44
|
plot_tree = eval(util.config_val('EXPL', 'plot_tree', 'False'))
|
45
|
+
needs_feats = False
|
45
46
|
if plot_feats or tsne or scatter or model_type or plot_tree:
|
46
47
|
# these investigations need features to explore
|
47
48
|
expr.extract_feats()
|
48
|
-
|
49
|
+
needs_feats = True
|
49
50
|
# explore
|
50
|
-
expr.analyse_features()
|
51
|
+
expr.analyse_features(needs_feats)
|
51
52
|
|
52
53
|
print('DONE')
|
53
54
|
|
@@ -226,4 +226,9 @@ class Util:
|
|
226
226
|
elif format == 'csv':
|
227
227
|
return audformat.utils.read_csv(name)
|
228
228
|
else:
|
229
|
-
self.error(f'unkown store format: {format}')
|
229
|
+
self.error(f'unkown store format: {format}')
|
230
|
+
|
231
|
+
def copy_flags(self, df_source, df_target):
|
232
|
+
df_target.is_labeled = df_source.is_labeled
|
233
|
+
df_target.got_gender = df_source.got_gender
|
234
|
+
df_target.got_speaker = df_source.got_speaker
|
@@ -1,6 +1,6 @@
|
|
1
1
|
Metadata-Version: 2.1
|
2
2
|
Name: nkululeko
|
3
|
-
Version: 0.45.
|
3
|
+
Version: 0.45.2
|
4
4
|
Summary: Machine learning audio prediction experiments based on templates
|
5
5
|
Home-page: https://github.com/felixbur/nkululeko
|
6
6
|
Author: Felix Burkhardt
|
@@ -123,7 +123,6 @@ There's my [blog](http://blog.syntheticspeech.de/?s=nkululeko) with tutorials:
|
|
123
123
|
* [Combine feature sets](http://blog.syntheticspeech.de/2022/06/30/how-to-combine-feature-sets-with-nkululeko/)
|
124
124
|
* [Classifying continuous variables](http://blog.syntheticspeech.de/2022/01/26/nkululeko-classifying-continuous-variables/)
|
125
125
|
* [Try out / demo a trained model](http://blog.syntheticspeech.de/2022/01/24/nkululeko-try-out-demo-a-trained-model/)
|
126
|
-
* [Plot distributions of feature values](http://blog.syntheticspeech.de/2023/02/16/nkululeko-how-to-plot-distributions-of-feature-values/)
|
127
126
|
* [Perform cross database experiments](http://blog.syntheticspeech.de/2021/10/05/nkululeko-perform-cross-database-experiments/)
|
128
127
|
* [Meta parameter optimization](http://blog.syntheticspeech.de/2021/09/03/perform-optimization-with-nkululeko/)
|
129
128
|
* [How to set up wav2vec embedding](http://blog.syntheticspeech.de/2021/12/03/how-to-set-up-wav2vec-embedding-for-nkululeko/)
|
@@ -217,6 +216,13 @@ Version 0.44.1
|
|
217
216
|
* bugfixing: feature importance: https://github.com/felixbur/nkululeko/issues/23
|
218
217
|
* bugfixing: loading csv database with filewise index https://github.com/felixbur/nkululeko/issues/24
|
219
218
|
|
219
|
+
Version 0.45.2
|
220
|
+
--------------
|
221
|
+
* added sample_selection for sample distribution plots
|
222
|
+
|
223
|
+
Version 0.45.1
|
224
|
+
--------------
|
225
|
+
* fixed dataframe.append bug
|
220
226
|
|
221
227
|
Version 0.45.0
|
222
228
|
--------------
|
@@ -1 +0,0 @@
|
|
1
|
-
VERSION = '0.45.0'
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|
File without changes
|