-
Notifications
You must be signed in to change notification settings - Fork 141
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
All weights set to NaN #23
Comments
Hi Quentin, I suppose the reason might be in too large learning rate, or weight Regards, On Wed, Jul 15, 2015 at 1:02 AM, Bardeux [email protected] wrote:
PhD candidate, Sergey Demyanov http://www.demyanov.net/ |
Hi Sergey, Thanks for your answer, it seems indeed that the CNN wasn't converging. I have some decent weights now (I think) after tuning down the alpha and momentum parameters, but I just got another problem... My CNN is a simple classifier (output of size 1). My training and testing sets have half examples of positive, and half negative. Problem is after training, the cnntest function returns a prediction vector with only ones, and it is accepted as a valid answer for every sample. I have a 0% error eventhough my testing set contains negative examples. I can't understand why the CNN acknowledges only 'positive' as a response, as my sets are evenly distributed. Sorry for bothering you with this, I'm still not used to neurals networks. Thanks again, Quentin |
Hi Quentin, I guess your problem now is that you use the softmax output layer, which is Regards, On Wed, Jul 15, 2015 at 9:36 PM, Bardeux [email protected] wrote:
|
Hi Sergey, I'm ashamed I didn't realize this. I really need to work more on neural networks. Thanks a lot for your help, it was extremely useful. Good luck with your future plans, Best regards, Quentin |
No problem, thank you) On Wed, Jul 15, 2015 at 11:21 PM, Bardeux [email protected] wrote:
|
Hi RGB or Gray image have range 0 - 255 for each pixel. to fix this problem you must have range 0 - 1 for each pixel. try this line of code when you import your data: MyPicData=MyPicData/255; |
Hello,
First of all, thanks a lot for sharing your work, it is really interesting.
About my problem, I'm trying to train a CNN using RGB images as input. My training set has a size of kXSize = 33x33x3x55000. I use a typical architecture I,C,S,C,S,C,S,F,F, no modifications to any hyperparameter. I define the input layer as :
struct('type', 'i', 'mapsize', kXSize(1:2), 'outputmaps', kXSize(3)).
Input matrices are normalized and correctly defined.
Problem is, after the first epoch of training, I keep getting a vector of NaN weights. Would you have any idea why weights are not computed properly? It seems I don't specify the input properly, but I can't find out where, as your program runs 'normally' (it takes about 1500sec to do 1 epoch of training).
Thanks for your attention,
Quentin
The text was updated successfully, but these errors were encountered: