fix flake8 issue

This commit is contained in:
dscripka 2024-01-18 20:16:41 -05:00 committed by GitHub
parent db418ab9f3
commit e3f1046ebb
No known key found for this signature in database
GPG key ID: B5690EEEBB952194

View file

@ -269,7 +269,7 @@ class AudioFeatures():
result = self._get_melspectrogram(batch)
elif pool:
chunksize = batch.shape[0]//ncpu if batch.shape[0]>=ncpu else 1
chunksize = batch.shape[0]//ncpu if batch.shape[0] >= ncpu else 1
result = np.array(pool.map(self._get_melspectrogram,
batch, chunksize=chunksize))
@ -331,7 +331,7 @@ class AudioFeatures():
result = self.embedding_model_predict(batch)
elif pool:
chunksize = batch.shape[0]//ncpu if batch.shape[0]>=ncpu else 1
chunksize = batch.shape[0]//ncpu if batch.shape[0] >= ncpu else 1
result = np.array(pool.map(self._get_embeddings_from_melspec,
batch, chunksize=chunksize))