crnn icon indicating copy to clipboard operation
crnn copied to clipboard

Preprocessing of Training Images

Open rayush7 opened this issue 7 years ago • 3 comments

Hi @bgshih

Is subtracting the mean and dividing by the standard deviation important preprocessing step in CRNN?

rayush7 avatar May 26 '17 15:05 rayush7

@rayush7 I guess so. Unnormalized data will probably result in divergence at the beginning of training.

bgshih avatar May 26 '17 16:05 bgshih

@bgshih Could you please explain whether you used raw images from vgg synthetic dataset as an input to the crnn model or normalized them before training crnn on them?

rayush7 avatar May 26 '17 18:05 rayush7

@rayush7 input original image , no need to normalize. in config.lua: local model = nn.Sequential() model:add(nn.Copy('torch.ByteTensor', 'torch.CudaTensor', false, true)) model:add(nn.AddConstant(-128.0)) model:add(nn.MulConstant(1.0 / 128))

northeastsquare avatar Dec 07 '17 11:12 northeastsquare