NSynth TFRecord for DDSP framework from original NSynth TFRecord ?

45 views
Skip to first unread message

Pierre-Amaury Grumiaux

unread,
Oct 5, 2022, 12:43:52 PM10/5/22
to Magenta Discuss
Hi everyone,

I downloaded the NSynth tfrecord file (either split works for me) from Magenta's website, which contains the original features for each sound, e.g., note, instrument, pitch, velocity, sample_rate, etc. I now want to employ it in the DDSP framework, probably using the class ddsp.training.data.TFRecordProvider (I don't want to use tensorflow_datasets for practical reasons).

So I need to create an adapted TFRecord file which contains DDSP features such as f0_hz, f0_confidence or loudness_db. How to do that from the original TFRecord file ?

The ddsp_prepare_tfrecord lib seems to be usable only from .wav files, and it seems a bit cumbersome to regenerate .wav files from waveforms in the original TFRecord.

I didn't find any useful insight in the tutorials or demos. Sorry if this is trivial, any help would be very useful :)

Thanks
Pierre-Amaury

Jesse Engel

unread,
Oct 17, 2022, 1:30:05 AM10/17/22
to Pierre-Amaury Grumiaux, Magenta Discuss
You should be able to use the built-in NSynthTfds DataProvider to get it from TFDS: https://github.com/magenta/ddsp/blob/main/ddsp/training/data.py#L139

Cheers,
Jesse

--
Magenta project: magenta.tensorflow.org
To post to this group, send email to magenta...@tensorflow.org
To unsubscribe from this group, send email to magenta-discu...@tensorflow.org
---
To unsubscribe from this group and stop receiving emails from it, send an email to magenta-discu...@tensorflow.org.
Reply all
Reply to author
Forward
0 new messages