#NEWLINE# def from_array_like( ary , stream = 0 , gpu_data = None ) : #NEWLINE# #INDENT# 'Create a DeviceNDArray object that is like ary.' #NEWLINE# if ( ary . ndim == 0 ) : #NEWLINE# #INDENT# ary = ary . reshape ( 1 ) #NEWLINE# #UNINDENT# return DeviceNDArray ( ary . shape , ary . strides , ary . dtype , writeback = ary , stream = stream , gpu_data = gpu_data )