-
Notifications
You must be signed in to change notification settings - Fork 4
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
the forward_propagation、predict function batched forward and the signal_predict function, same input but predict output different. #45
Comments
So according to this: It seems in keras the same cell-state is used for both predicting and training. Do you need single_predict to use the same cell-state as well? |
I think it should be same cell. how about keras predict use one imge? |
So according to this: Keras (by default) resets its state after each sequence of batches. |
Sorry, now the result seems worse, predict and simgle_predict function output: training... forward_propagation inputdata------------------------------------ |
I fell that, batched forward the forward_propagation and predict is same fuction, but forward_propagation fuction is best,so predict is seems unnecessary. But the single_predict is the most common function, because we all predict with one image or one record. So concentrate on the single_predict function. |
Hi, I just added:
To the Neural_Network class. In commit 05a9daf I am still debugging why there is a slight difference between the two. |
Checking now. Are you testing in debug mode or release mode? |
I only test release mode. Need to test debug model? |
I do not (that would take very long too!). Just checking so I could replicate it |
Did it crash on the first call to predict? (Are you using malloc to create the neuralnetwork?) |
Yes, i create the neuralnetwork. Now use the first network struct, every time break, in release mode. I am test debug model. |
My example:
|
I was able to reproduce the error. |
OK. How about this compile error? |
I added a fix for the predict_bug. 2405b82 |
Yes, now the forward_propagation and the predict function is same. We should focus on the single_predict function. |
How about them? Four days have no updata. You are busying in your work? |
Oh so sorry! I thought I had responded to you. I have been working on this branch: |
Hi! I just added max_pooling: #49 Next steps: Is single-predict still giving different results? |
yes, it is still a problem. Perhaps, you data is samll, but in my data, the litte different will result in the big different output data,this is the three function input and output, the single_predict the output is so big: Neural Network architecture: training... forward_propagation MAPE loss: 0.0321961 forward_propagation output predict data------------------------------------ predict inputdata------------------------------------ predict output predict data------------------------------------ single_predict inputdata------------------------------------ |
|
I think you shoul be the next steps: |
I found the issue with single_predict, some of the data wasn't being copied correctly in recurrent layers. |
I test it, it seems NO: |
Did you use Example:
|
I believe single_predict is working: Added minor changes as of b812d74
Test:
Output:
|
Yes, now the predic and single_predict function, the same input and same output, but compare to forward_propagation function, them is not. It should be this, or still something wrong with it?
|
In windows predict and forward_propagation use the same cell-state so they should be different if you run them one after another. Do you need/want predict to have a seperate cell-state from forward_propagation? |
oh. It means it should be this, predict and forward_propagation? I don't know whether predict should be seperate cell-state, but if i load the model, whether have the same result as not load? |
Load is only saving the weights but it also needs to save the inputs/outputs of each layer. (However it is currently giving different results so its something I have to fix) |
OK. Thank you very much. |
So the network is saving variables and weights. |
This issue has been resolved, |
No description provided.
The text was updated successfully, but these errors were encountered: