#NEWLINE# def GpuArray_unpickler( npa , ctx_name ) : #NEWLINE# #INDENT# if config . experimental . unpickle_gpu_on_cpu : #NEWLINE# #INDENT# warnings . warn ( 'config.experimental.unpickle_gpu_on_cpu is set to True. Unpickling GpuArray as numpy.ndarray' ) #NEWLINE# return npa #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# if pygpu : #NEWLINE# #INDENT# ctx = get_context ( ctx_name ) #NEWLINE# return pygpu . gpuarray . array ( npa , copy = True , context = ctx_name ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# raise ImportError ( 'pygpu not found. Cannot unpickle GpuArray' )