Skip to main content

A thin python wrapper for the nvToolsExt (NVTX) library, using pybind11

Project description

PyNVTX

A thin python wrapper for the nvToolsExt (NVTX) library, using pybind11. This wrapper is meant to be as thin as possible -- so only provides minimal support. Currently supported features are:

  1. NVTX markers: nvtxRangePushA and nvtxRangePop
  2. Function decorator: PyNVTX.wrap

NVTX Markers (nvtxRangePushA / nvtxRangePop)

import PyNVTX as nvtx

nvtx.RangePushA("Doing some work")

# code to time goes here

nvtx.RangePop()

Function Decorator

This will put RangePushA and RangePop the the beginning and and of the function call:

@nvtx.mark("test_function")
def test():
    # You code goes here

Example Code

To get you started, take a look at test/test-nvtx.py

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

PyNVTX-0.1.2.tar.gz (5.8 kB view hashes)

Uploaded Source

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page