#NEWLINE# @ staticmethod #NEWLINE# def _convert_indices( ind ) : #NEWLINE# #INDENT# reqs = [ ] #NEWLINE# subset = False #NEWLINE# for i in ind : #NEWLINE# #INDENT# if isinstance ( i , slice ) : #NEWLINE# #INDENT# if ( ( i . start is None ) and ( i . stop is None ) and ( i . step is None ) ) : #NEWLINE# #INDENT# reqs . append ( ':' ) #NEWLINE# #UNINDENT# else : #NEWLINE# #INDENT# subset = True #NEWLINE# slice_str = ( ( str ( i . start ) + ':' ) + str ( ( i . stop - 1 ) ) ) #NEWLINE# if i . step : #NEWLINE# #INDENT# slice_str += ( ':' + str ( i . step ) ) #NEWLINE# #UNINDENT# reqs . append ( slice_str ) #NEWLINE# #UNINDENT# #UNINDENT# else : #NEWLINE# #INDENT# reqs . append ( str ( i ) ) #NEWLINE# subset = True #NEWLINE# #UNINDENT# #UNINDENT# return ( ( ( '(' + ',' . join ( reqs ) ) + ')' ) if subset else '' )