Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 8957327
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 15, 20262026-06-15T14:57:53+00:00 2026-06-15T14:57:53+00:00

This question is almost the same as How to profile PyCuda code with the

  • 0

This question is almost the same as How to profile PyCuda code with the Visual Profiler? except about the new NVIDIA Nsight IDE with CUDA 5 for Linux.

I have a PyCUDA Python script that I’d like to profile using fancy Nsight.

I set up a Build External Tools Configuration, pointing to the example script (with executable permissions, included below). I can then run this, and see the printouts in the Console. Then I go to Profile mode and click Run -> Profile—I see the printouts in the Console but no profiler information visible. How do I get the timing plots and occupancy calculators and NVIDIA’s suggestions for my code that appear when I run a C/CUDA program in Nsight?

Total IDE noob here (mostly command-line), sorry if my question doesn’t include key information. Ubuntu 11.10, PyCUDA 2012.1.

Nsight screenshot

example.py:

#!/usr/bin/env python
import pycuda.autoinit
import pycuda.driver as drv
import numpy

from pycuda.compiler import SourceModule

mod = SourceModule("""
__global__ void multiply_them(float *dest, float *a, float *b)
{
  const int i = threadIdx.x;
  dest[i] = a[i] * b[i];
}
""")

multiply_them = mod.get_function("multiply_them")

a = numpy.random.randn(400).astype(numpy.float32)
b = numpy.random.randn(400).astype(numpy.float32)

dest = numpy.zeros_like(a)
multiply_them(
        drv.Out(dest), drv.In(a), drv.In(b),
        block=(400,1,1), grid=(1,1))

print "error:", numpy.sum(numpy.abs(dest - a*b).ravel())
print "Done"
#pycuda.autoinit.context.detach() # seems to break PyCUDA 2012.1
  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-15T14:57:54+00:00Added an answer on June 15, 2026 at 2:57 pm

    I used nvvp to get the timeline and the program analysis. Just chmod 755 the script and add a #!/usr/bin/env python at the top and give it to nvvp.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

this is almost the same as this question except using NH's mapping-by-code. I really
In reference to this question, I am facing almost the same scenario except that
My question is almost exactly the same as this post , except that I'm
I've seen some question here about almost the same thing, but, after following their
This question is about this topic: Vb.net all combinations Question: I use this code
My question looks almost the same as this Is it possible to put variables
Almost the same question as this one here: What's the easiest way to grab
This question is almost the same as a previous question , but differs enough
This is almost exactly the same as this question json get key names as
I have almost the same problem as this unanswered question . The only difference

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.