2
$\begingroup$

I've built a fully-connected feed-forward neural network to recognize handwritten digits. I used MNIST and another very similar dataset (containing Arabic digits - same training set and test set count as those of MNIST).

For a network with exactly the same architecture (1 hidden layer, same learning rate, same weight sampling), I tested on a sub-sample that used 100 images for training. The test accuracy was very low, but what I noticed was that for the Arabic digits, the network took significantly longer to train (double the amount of time than for English digits - 33ms and 15ms, respectively).

What could be the reason for this?

$\endgroup$
2
  • $\begingroup$ If you have more images, train your model on them and time the training. It'll interesting to know the difference in training time. $\endgroup$ Aug 25, 2018 at 3:22
  • $\begingroup$ Are you referring to the amount of time per epoch or the total time to train the network? $\endgroup$ Sep 24, 2018 at 3:18

1 Answer 1

1
$\begingroup$

There could be multiple factors that could cause this to happen:

  1. If the data types are different for the two images - np.float32 vs np.float64

  2. Your computer might be performing some compression and decompression to optimize memory usage. If most of the pixels are very different from each other in the Arabic dataset, then the compressed size may be larger and require more time to decompress.

  3. Your computer happened to have other competing processes running at the same time and distorted the execution results for one of your runs.

I would suggest you to use methods like timeit that do multiple runs to verify that this behaviour is consistent.

$\endgroup$

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service, privacy policy and cookie policy

Not the answer you're looking for? Browse other questions tagged or ask your own question.