• Cagri's avatar
    Helper script for rocTX run and parse (#985) · 4f9a0ce7
    Cagri authored
    This provides a helper script to run rocTX markers with migraphx-driver and reduces the number of steps a user would go through running rocTX knob.
    Run:
    python roctx.py --run --onnx_file <ONNX_FILE> --migraphx_args "--onnx --gpu --fp16 --batch 16" --out outputfolder
    Runs and parses the run output (JSON file). An example output is given below:
    
                                                         SUM  MIN  MAX
    Marker start: gpu::convolution                      5272   10  563
    Marker start: gpu::add_relu                          605   12   18
    Marker start: gpu::gather                            299  145  154
    Marker start: gpu::mul_add                           227   14   57
    Marker start: gpu::sub                               177   13   42
    Marker start: gpu::concat                            169   22   31
    Marker start: gpu::triadd_relu                       163   15   18
    Marker start: load                                   141    0    3
    Marker start: hip::hip_copy_literal                  111    0    3
    Marker start: gpu::add                                58   13   17
    Marker start: broadcast                               52    0    3
    Marker start: gpu::convert                            31   15   16
    Marker start: slice                                   11    0    1
    Marker start: gpu::pooling                             9    9    9
    Marker start: step                                     2    2    2
    Marker start: @param                                   2    0    1
    Marker start: reshape                                  1    0    1
    Marker start: hip::hip_allocate_memory                 1    1    1
    Marker start: check_context::migraphx::version_...     0  ERR  ERR
    
    TOTAL TIME: 7331 us
    
    JSON FILE PATH: [...]/rpl_data_211019_195229_9369/input_results_211019_195229/trace.json
    Parse:
    python roctx.py --parse --json_path <JSON PATH FROM RUN>
    Note: The parse knob is made available if the user wants to parse an already existing JSON output.
    4f9a0ce7
roctx.py 11.6 KB