def scalarconsts_rest(inputs, elemwise=True, only_process_constants=False):
 consts = []
 origconsts = []
 nonconsts = []
 for i in inputs:
  try:
   v = get_scalar_constant_value(i, elemwise=elemwise, only_process_constants=only_process_constants)
   consts.append(v)
   origconsts.append(i)
  except NotScalarConstantError:
   nonconsts.append(i)
 return (consts, origconsts, nonconsts)

def scalarconsts_rest ( inputs , elemwise = True , only_process_constants = False ) : consts = [ ] origconsts = [ ] nonconsts = [ ] for i in inputs : try : v = get_scalar_constant_value ( i , elemwise = elemwise , only_process_constants = only_process_constants ) consts . append ( v ) origconsts . append ( i ) except NotScalarConstantError : nonconsts . append ( i ) return ( consts , origconsts , nonconsts )
partition a list of variables into two kinds: scalar constants .