ipython display redirect output to null code example Example: python stop stdout f = open('/dev/null', 'w') sys.stdout = f