def testLoadNsynth(self, batch_size, sample_length): with tf.Graph().as_default(): net = fastgen.load_nsynth(batch_size=batch_size, sample_length=sample_length) encodings_length = int(sample_length / 512) self.assertEqual(net['X'].shape, (batch_size, sample_length)) self.assertEqual(net['encoding'].shape, (batch_size, encodings_length, 16)) self.assertEqual(net['predictions'].shape, (batch_size * sample_length, 256))
def testLoadNsynth(self, batch_size, sample_length): with tf.Graph().as_default(): net = fastgen.load_nsynth(batch_size=batch_size, sample_length=sample_length) encodings_length = int(sample_length/512) self.assertEqual(net['X'].shape, (batch_size, sample_length)) self.assertEqual(net['encoding'].shape, (batch_size, encodings_length, 16)) self.assertEqual(net['predictions'].shape, (batch_size * sample_length, 256))