def _undo_op(arg, string, strict=False):
 if hasattr(arg.owner, 'op'):
  owner = arg.owner
  if (string in str(owner.op)):
   return owner.inputs[0]
  elif strict:
   raise ValueError((((string + ' not found in op ') + str(owner.op)) + '.'))
 elif strict:
  raise ValueError((((string + ' op not found in variable ') + str(arg)) + '.'))
 return arg

def _undo_op ( arg , string , strict = False ) : if hasattr ( arg . owner , 'op' ) : owner = arg . owner if ( string in str ( owner . op ) ) : return owner . inputs [ 0 ] elif strict : raise ValueError ( ( ( ( string + ' not found in op ' ) + str ( owner . op ) ) + '.' ) ) elif strict : raise ValueError ( ( ( ( string + ' op not found in variable ' ) + str ( arg ) ) + '.' ) ) return arg
undo symbolic op if string is in str .