First, I'd like to thank everyone for their work here. This is great stuff.
Has anyone tried to download one of the pytorch models and run on Android? I am trying to make a speech separation application, using this model: https://zenodo.org/records/3873670
Following this, I was able to load the model into Android studio, but am having trouble understanding how to call separate on it.
In Python on my PC, I was able to successfully run the following:
from asteroid.models import BaseModel
import soundfile as sf
# 'from_pretrained' automatically uses the right model class (asteroid.models.DPRNNTasNet).
model = BaseModel.from_pretrained("mpariente/DPRNNTasNet-ks2_WHAM_sepclean")
# You can pass a NumPy array:
mixture, _ = sf.read("female-female-mixture.wav", dtype="float32", always_2d=True)
# Soundfile returns the mixture as shape (time, channels), and Asteroid expects (batch, channels, time)
mixture = mixture.transpose()
mixture = mixture.reshape(1, mixture.shape[0], mixture.shape[1])
out_wavs = model.separate(mixture)
# Or simply a file name:
model.separate("female-female-mixture.wav")
However, I cannot call 'separate' in Android.
Anyone ever tried to take a model and run on Android?
First, I'd like to thank everyone for their work here. This is great stuff.
Has anyone tried to download one of the pytorch models and run on Android? I am trying to make a speech separation application, using this model: https://zenodo.org/records/3873670
Following this, I was able to load the model into Android studio, but am having trouble understanding how to call
separate
on it.In Python on my PC, I was able to successfully run the following:
However, I cannot call 'separate' in Android.
Anyone ever tried to take a model and run on Android?