Posts

Post not yet marked as solved
7 Replies
1.5k Views
I curious why so few people are posting about training on MPS - am I missing something?I'm building a trivial Convolutional Neural Network (CNN) in MPSCNN and have come across an issue with exporting the weights out.When training I run into issues when calling **MPSNNGraph.encodeBatch** when the batch size is larger than 4 (which is somewhat peculiar given that a MTLTexture has 4 channels). Anytime I increase the batch size I am returned with **nan** for the weights and bias coefficients (both via the datasources locally stored MPSCNNConvolutionWeightsAndBiasesState (from the update method) or exporting the weights from the associated filter nodes).I have increased the precision on the graph and all resultImages of the nodes to float32 and also added clipping to the optimizer, with no luck. Is there a way to tell if this is a memory issue or overflow on the data types used? Would the issue reside in the optimizer, gradients, states, or transfer from GPU to CPU?Any suggestions greatly appreciated - I've been stuck on this 'challenge' for a good part of a couple of weeks now - cheers.Some suggestion from me, to Apple and the MPS ML team:- Best practice **example** of training using MPS- Better debugging tools
Posted Last updated
.