It has got something to do with the data augmentation. That’s why the error only appears with precompute=False. With tfms_from_model the statistics from the imagenet pictures are used and those seem to not work for mnist with the tripled channel. It should work when you use tfms = tfms_from_stats(None, sz, aug_tfms=transforms_basic).
EDIT: Sorry tfms_from_stats does not work, I forgot to switch precompute off. But it definitely works without augmentation: data = ImageClassifierData.from_arrays(PATH, trn=(X_train, y_train), val=(X_valid, y_valid), classes=classes, test=np.array(test))