how do I write module and its arguments to launch.json in VS Code?

The codes in shell file are:

    CUDA_VISIBLE_DEVICES=2,3 python3 -m torch.distributed.launch --nproc_per_node=2 --master_port=${MASTER_PORT} ../../ \
    $data \
    --selected-cols=${selected_cols} \
    --bpe-dir=${bpe_dir} \

and so on.

I wrote the codes above into launch.json file like:

"version": "0.2.0",
"configurations": [
        "name": "train",
        "type": "python",
        "request": "launch",
        "program": "${workspaceFolder}/OFA/",
        "console": "integratedTerminal",
        "justMyCode": true,
        "module": "torch.distributed.launch",
        "args": [
            "--selected-cols", "1,4,2",
            "--bpe-dir", "../../utils/BPE",

and so on.

The problem I am facing is I have no clue how to write --proc_per_node=2 and --master_port=${MASTER_PORT} into this launch.json file. To my opinion they belong to "module" since they appear after -m torch.distributed.launch.

Does anyone know the way to integrate these extra arguments into "module"?? If they are not the part of "module", how should I write them??

great thanks to anyone answering my question

How many English words
do you know?
Test your English vocabulary size, and measure
how many words do you know
Online Test
Powered by Examplum