assert 1 > 2, "Error"
输出:
Traceback (most recent call last):
File "G:/Python_Tensorflow/Faster-RCNN-TensorFlow-Python3.5-master/test.py", line 1, in <module>
assert 1 > 2, "Error"
AssertionError: Error
如果不加提示:
assert 1 > 2
输出:
Traceback (most recent call last):
File "G:/Python_Tensorflow/Faster-RCNN-TensorFlow-Python3.5-master/test.py", line 1, in <module>
assert 1 > 2
AssertionError