# Fail to profile remote python scripts by nsight system/compute

**URL:** <https://forums.developer.nvidia.com/t/fail-to-profile-remote-python-scripts-by-nsight-system-compute/195119>\
**Category:** Jetson AGX Xavier\
**Tags:** python, tensorrt\
**Created:** [November 15, 2021, 7:21am UTC](https://forums.developer.nvidia.com/t/fail-to-profile-remote-python-scripts-by-nsight-system-compute/195119 "2021-11-15T07:21:42Z")\
**Posts on this page:** 7\
**Page:** 1

<div class="post-metadata">

**Author:** ![nv-u](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@nv-u](https://forums.developer.nvidia.com/u/nv-u)\
**Post date:** [November 15, 2021, 7:21am UTC](https://forums.developer.nvidia.com/t/fail-to-profile-remote-python-scripts-by-nsight-system-compute/195119/1 "2021-11-15T07:21:42Z")

</div>

Hello, I encountered problems when trying to profile a remote python script by nsight-system-gui and nsight-compute-gui.

1. For nsight-system-gui, I configured as below.  
 ![image](https://global.discourse-cdn.com/nvidia/original/3X/3/0/3097a3ef2169050e523682907d7417932e19cb38.png)  
What I got is shown as below.  
 ![image](https://global.discourse-cdn.com/nvidia/original/3X/a/f/af063b5bd4382fdd224c7d484a993df12d3595d1.png)  
There is no error message but the profile result is apparently not what I expected, as no GPU events are captured.
2. For nsight-compute-gui, I configured as below.  
 ![image](https://global.discourse-cdn.com/nvidia/original/3X/c/0/c04560607efd1220b1de6fdcd9c8918d09f8e15a.png)  
After I start to profile, progress log shows below message with an error code 103.  
 ![image](https://global.discourse-cdn.com/nvidia/original/3X/0/3/0304851c03a934e9c8f79b62db47133ff9c421e7.png)

I can succeed to profile another ELF executable and watch related GPU events, so I must ignore something important in configuration. My question is how should I do to profile python scripts.

Environment information:  
Jetson AGX Xavier: JetPack 4.5.1 firmware  
Host: Ubuntu 18.04 LTS in VirtualBox  
Nsight System version: 2020-5.3.17 (just matched with JetPack)  
Nsight Compute version: 2019.5.0 (just matched with JetPack)

---

<div class="post-metadata">

**Author:** ![AastaLLL](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/aastalll/32/14043_2.png) [@AastaLLL](https://forums.developer.nvidia.com/u/AastaLLL)\
**Post date:** [November 15, 2021, 7:46am UTC](https://forums.developer.nvidia.com/t/fail-to-profile-remote-python-scripts-by-nsight-system-compute/195119/3 "2021-11-15T07:46:09Z")

</div>

Hi,

Do you _ssh_ the device with root account?  
If not, would you mind giving it a try?

> [@No timeline for profiler Xavier: nvvp and nsight compute is not working in Jetson Xavier](https://forums.developer.nvidia.com/t/no-timeline-for-profiler-xavier-nvvp-and-nsight-compute-is-not-working-in-jetson-xavier/75072/7):
>
> Hi, Have you setup the root password first? The process should like this: 1.Setup root password $ sudo passwd root 2.Edit /etc/ssh/sshd\_config diff --git a/sshd\_config b/sshd\_config index a32dc1d..d21cacd 100644 --- a/sshd\_config +++ b/sshd\_config @@ -30,6 +30,7 @@ #LoginGraceTime 2m #PermitRootLogin prohibit-password +PermitRootLogin yes #StrictModes yes #MaxAuthTries 6 #MaxSessions 10 @@ -54,7 +55,7 @@ # To disable tunneled clear text passwords, change to no here! #PasswordAut…

Thanks.

---

<div class="post-metadata">

**Author:** ![nv-u](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@nv-u](https://forums.developer.nvidia.com/u/nv-u)\
**Post date:** [November 15, 2021, 8:14am UTC](https://forums.developer.nvidia.com/t/fail-to-profile-remote-python-scripts-by-nsight-system-compute/195119/4 "2021-11-15T08:14:02Z")

</div>

Thanks for your reply!

In my case, I use root account for Nsight Compute, otherwise it won’t profile ELF executable files successfully. I use a sudo user for Nsight System, because it is enough to profile ELF executable files.

I follow your suggestion to connect the device with root account in Nsight System, and I got the same results.

So sad…

---

<div class="post-metadata">

**Author:** ![nv-u](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@nv-u](https://forums.developer.nvidia.com/u/nv-u)\
**Post date:** [November 15, 2021, 8:34am UTC](https://forums.developer.nvidia.com/t/fail-to-profile-remote-python-scripts-by-nsight-system-compute/195119/5 "2021-11-15T08:34:00Z")

</div>

I add `time.sleep(20)` in the target python script at the very first place, then use `Attach by PID` mode to profile, like this.

 ![image](https://global.discourse-cdn.com/nvidia/original/3X/5/0/500dcd609eee2b14fd7dd153dccbbd6f91a265ee.png)

In this way, it captures complete CPU events and GPU contexts, but no concrete GPU events, shown as below.

 ![image](https://global.discourse-cdn.com/nvidia/original/3X/7/9/7934ba02ef344311d298b34aeefb794d04671750.png)

The 14 warnings in the upper right corner seem to have no effect, shown as below.

 ![image](https://global.discourse-cdn.com/nvidia/original/3X/2/e/2e4e8bc067eacd7cc22139bc56ac0a64f6295d74.png)

---

<div class="post-metadata">

**Author:** ![nv-u](https://developer.download.nvidia.com/images/forums/profile-default-devtalk-84.png) [@nv-u](https://forums.developer.nvidia.com/u/nv-u)\
**Post date:** [November 16, 2021, 12:38pm UTC](https://forums.developer.nvidia.com/t/fail-to-profile-remote-python-scripts-by-nsight-system-compute/195119/6 "2021-11-16T12:38:37Z")

</div>

Any ideas?

---

<div class="post-metadata">

**Author:** ![AastaLLL](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/aastalll/32/14043_2.png) [@AastaLLL](https://forums.developer.nvidia.com/u/AastaLLL)\
**Post date:** [November 25, 2021, 7:31am UTC](https://forums.developer.nvidia.com/t/fail-to-profile-remote-python-scripts-by-nsight-system-compute/195119/7 "2021-11-25T07:31:43Z")

</div>

**There is no update from you for a period, assuming this is not an issue any more.  
Hence we are closing this topic. If need further support, please open a new one.  
Thanks**

Hi,

Would you mind sharing what is the script doing?  
For GPU events, do you profile it with Nsight compute?

Thanks.

---

<div class="post-metadata">

**Author:** ![system](https://sea2.discourse-cdn.com/nvidia/user_avatar/forums.developer.nvidia.com/system/32/68080_2.png) [@system](https://forums.developer.nvidia.com/u/system)\
**Post date:** [December 22, 2021, 2:08am UTC](https://forums.developer.nvidia.com/t/fail-to-profile-remote-python-scripts-by-nsight-system-compute/195119/9 "2021-12-22T02:08:28Z")

</div>

Closed on December 22, 2021, 2:08am UTC

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
