def NumpyAsParameter(numpy_array):
 assert (numpy_array.dtype == 'float32'), 'Saved arrays should be float32.'
 return numpy_array.tostring()

def NumpyAsParameter ( numpy_array ) : assert ( numpy_array . dtype == 'float32' ) , 'Saved arrays should be float32.' return numpy_array . tostring ( )
converts a numpy array into a serialized parameter string .