Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

ValueError: Cannot feed value of shape (256, 9, 129) for Tensor 'model/labels:0', which has shape '( #17

Open
MayMiao0923 opened this issue Jul 4, 2019 · 6 comments

Comments

@MayMiao0923
Copy link

When I ran the main.py , the following error occurred.
001
When I ran the main.py, the following error occurred.At this point, the model used is fnn.
003
Later, when I checked the fnn model in the trnmodle.py, I found the cause of the error.
002
However, I did not modify the parameters or commands in the datareader.py. and the same error occurred when I used the lstm model.
ValueError: Cannot feed value of shape (256, 9, 129, 1) for Tensor 'model/inputs:0', which has shape '(?, 129, 1, 1)'
004
005
However, my RAW file is made using the MATLAB program you gave, for example
006
Excuse me, what should I do to solve this problem?Is there any wrong operation when I am making RAW files? I made all the voices in the TRAIN folder in TIMIT into the RAW files needed in the SE, and did not set the verification file.
And I read your paper. The neural network used in the TSN algorithm you proposed in the paper is DNN. Is that right?
@jtkim-kaist

@jtkim-kaist
Copy link
Owner

  1. The problem occurs from the mismatch of datareader and model's placeholder. According to your debugging, the datareader outputs the dnn's inputs but the model is set to lstm.

Please verify your log directory is clean, if not, the program automatically re-load previous model so that mismatch can occur.

  1. Yes, in partial. TSN consists of DNN (pri-NN) and CNN (post-NN).

I'm really sorry about your effort because of code problems. Cheer up and If you have another question, please tagging me again.

@jtkim-kaist
Copy link
Owner

jtkim-kaist commented Jul 7, 2019

Also the first problem you mentioned is not the code problem, but some environmental problem. How about changing your environment to ubuntu 16.04 from window? Actually, all of my projects were run in ubuntu 16.04 so I cannot expect my project will run in window correctly. Also, my co-workers had not suffered from code problems to run this project in ubuntu environment.

@MayMiao0923
Copy link
Author

Do you mean that the two mode models should be defined the same when I run the code? Is it the form in the picture below?
捕获28

I will try to run your project in the ubantu environment, if I have any questions, I will ask you again.
thanks for your help.
@jtkim-kaist

@MayMiao0923
Copy link
Author

Or, I need to modify the config.mode=="lstm" and config.mode=="tsn" commands in the datareader. In other words, when I use the following in the config.py file, do I need to ensure that the mode in config.py should be lstm instead of fnn?
in datareader.py is
捕获29
At this time, mode is lstm
In config.py, do I need to change mode='fnn" to mode="lstm? such as,
捕获30

@MayMiao0923
Copy link
Author

@jtkim-kaist

@jtkim-kaist
Copy link
Owner

Don't change the code and at first, just set mode='fnn' (basic mode)
and in main.py try to set reset=True, train_reset=True, test_only=False

Also, clean your files in logs. and remove some .npy in your data directory (if .npy exists)

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants