ipykernel_launcher.py: error: unrecognized arguments:

args = parser.parse_args()

引发的错误:

 

usage: ipykernel_launcher.py [-h] [--data_path DATA_PATH] [--dataset DATASET]
ipykernel_launcher.py: error: unrecognized arguments: -f C:\Users\hp\AppData\Roaming\jupyter\runtime\kernel-0701c135-8f2b-4af6-8cf1-bae93dd7be83.json
An exception has occurred, use %tb to see the full traceback.

SystemExit: 2

 

解决方法:

args = parser.parse_args()

修改为

args,unknow =parser.parse_know_args()

问题迎刃而解

 

你可能感兴趣的:(python)