VSCode debug调试通用json文件配置

{
    // Use IntelliSense to learn about possible attributes.
    // Hover to view descriptions of existing attributes.
    // For more information, visit: https://go.microsoft.com/fwlink/?linkid=830387
    "version": "0.2.0",
    "configurations": [
        {
            "name": "Python: Current File",
            "type": "python",
            "request": "launch",
            "program": "${file}",
            "console": "integratedTerminal",
            "justMyCode": true
        },
        {
            "name": "PVRCNN",
            "type": "python",
            "request": "launch",
            //要进行调试的python文件
            "program": "/data_f/sun/miniconda3/envs/openpcdet/lib/python3.8/site-packages/torch/distributed/launch.py",
            "console": "integratedTerminal",
            //修改默认采用的conda环境,注意是pythonPath,不是python
            "pythonPath":"/data_f/sun/miniconda3/envs/openpcdet/bin/python",
            //设置为false,表示会进入内置包package中代码进行调试
            "justMyCode": false,
            //相关参数python xxx.py  --xxx xxxx
            "args":[
                // "--nproc_per_node=2",
                "--nproc_per_node=1",
                "--master_addr=127.0.0.1",
                "--master_port=29500",
                "/data_f/sun/OpenPCDet/tools/train.py",
                "--launcher",
                "pytorch",
                "--cfg_file",
                "/data_f/sun/OpenPCDet/tools/cfgs/kitti_models/pv_rcnn.yaml",
            ],
            //设置采用哪几块的GPU进行训练调试
            "env": {"CUDA_VISIBLE_DEVICES":"1"},
            //修改vscode代码调试的根目录,${workspaceFolder}表示当前VSCode打开的文件夹根目录
            "cwd": "${workspaceFolder}/tools"
        },
    ]
}

  • 0
    点赞
  • 0
    收藏
    觉得还不错? 一键收藏
  • 0
    评论
评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值