Skip to content

It seems impossible to generate with scalar_input on? #291

Open
@carykh

Description

@carykh

The two options for inputs are scalar and one-hot, with one-hot being the default, right?

If I set the parameters in wavenet_params.json to use scalar, the network trains just fine. But when I try to generate, it says "Incremental generation does not support scalar input yet." That seems fair enough. It looks like the easiest solution to this is to turn off "fast_generation", which will call the function predict_proba instead of predict_proba_incremental. However, when I do that, I get this error:

ValueError: Shape must be rank 4 but is rank 3 for 'wavenet_1/causal_layer/causal_conv/conv1d/Conv2D' (op: 'Conv2D') with input shapes: [?,1,1], [1,32,1,32].

This kinda makes sense to me, because a scalar has one fewer dimension than a one-hot vector, so I could understand why the resulting tensor's shape now has 3 dimensions instead of 4. However, when I tried reshaping the tensor to have 4 dimensions, I still couldn't get it to work. I don't think I understand TensorFlow or this code closely enough to fix this problem. Help!

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions