It seems to be quite difficult to run the profiler with unified-memory-profiling for me. Is the output of the profiler without  unified-memory-profiling any use?
RuntimeError: CUDA out of memory. Tried to allocate 30.90 GiB (GPU 0; 10.92 GiB total capacity; 2.48 GiB already allocated; 7.21 GiB free; 1023.50 KiB cached)
==9== Profiling application: python bug.py
==9== Profiling result:
            Type  Time(%)      Time     Calls       Avg       Min       Max  Name
 GPU activities:  100.00%  54.839ms         3  18.280ms     960ns  54.432ms  [CUDA memcpy HtoD]
      API calls:   98.56%  3.93209s         6  655.35ms  18.299us  3.92879s  cudaMalloc
                    1.38%  54.952ms         3  18.317ms  10.057us  54.483ms  cudaMemcpyAsync
                    0.02%  940.22us       185  5.0820us     628ns  191.37us  cuDeviceGetAttribute
                    0.02%  788.03us         2  394.01us  390.98us  397.05us  cudaGetDeviceProperties
                    0.01%  365.55us         2  182.78us  182.22us  183.34us  cuDeviceTotalMem
                    0.00%  164.13us         3  54.709us  4.5400us  83.042us  cudaStreamSynchronize
                    0.00%  120.34us         1  120.34us  120.34us  120.34us  cudaMemGetInfo
                    0.00%  83.531us         2  41.765us  39.391us  44.140us  cuDeviceGetName
                    0.00%  48.126us        42  1.1450us     768ns  5.3780us  cudaGetDevice
                    0.00%  31.360us        23  1.3630us     768ns  5.5880us  cudaSetDevice
                    0.00%  10.195us        13     784ns     629ns  1.2570us  cudaGetDeviceCount
                    0.00%  2.7930us         3     931ns     768ns  1.2570us  cuDeviceGetCount
                    0.00%  2.4440us         3     814ns     699ns     907ns  cuDeviceGet
                    0.00%  1.5360us         2     768ns     698ns     838ns  cudaGetLastError
                    0.00%     978ns         1     978ns     978ns     978ns  cuInit
                    0.00%     978ns         1     978ns     978ns     978ns  cuDriverGetVersion
======== Error: Application returned non-zero code 1

Let me know if it is not, I will see if I can dig any deeper to try and get the profiler to work.