fix test_mlp.py: work with versions of numpy whose astype don't accept keyword args