# XProf (+ Tensorboard Profiler Plugin)
XProf includes a suite of tools for [JAX](https://jax.readthedocs.io/), [TensorFlow](https://www.tensorflow.org/), and [PyTorch/XLA](https://github.com/pytorch/xla). These tools help you understand, debug and optimize programs to run on CPUs, GPUs and TPUs.
XProf offers a number of tools to analyse and visualize the
performance of your model across multiple devices. Some of the tools include:
* **Overview**: A high-level overview of the performance of your model. This
is an aggregated overview for your host and all devices. It includes:
* Performance summary and breakdown of step times.
* A graph of individual step times.
* A table of the top 10 most expensive operations.
* **Trace Viewer**: Displays a timeline of the execution of your model that shows:
* The duration of each op.
* Which part of the system (host or device) executed an op.
* The communication between devices.
* **Memory Profile Viewer**: Monitors the memory usage of your model.
* **Graph Viewer**: A visualization of the graph structure of HLOs of your model.
## Demo
First time user? Come and check out this [Colab Demo](https://docs.jaxstack.ai/en/latest/JAX_for_LLM_pretraining.html).
## Prerequisites
* tensorboard-plugin-profile >= 2.19.0
* (optional) TensorBoard >= 2.19.0
Note: XProf requires access to the Internet to load the [Google Chart library](https://developers.google.com/chart/interactive/docs/basic_load_libs#basic-library-loading).
Some charts and tables may be missing if you run TensorBoard entirely offline on
your local machine, behind a corporate firewall, or in a datacenter.
To profile on a **single GPU** system, the following NVIDIA software must be
installed on your system:
1. NVIDIA GPU drivers and CUDA Toolkit:
* CUDA 12.5 requires 525.60.13 and higher.
2. Ensure that CUPTI 10.1 exists on the path.
```shell
$ /sbin/ldconfig -N -v $(sed 's/:/ /g' <<< $LD_LIBRARY_PATH) | grep libcupti
```
If you don't see `libcupti.so.12.5` on the path, prepend its installation
directory to the $LD_LIBRARY_PATH environmental variable:
```shell
$ export LD_LIBRARY_PATH=/usr/local/cuda/extras/CUPTI/lib64:$LD_LIBRARY_PATH
```
Run the ldconfig command above again to verify that the CUPTI 12.5 library is
found.
If this doesn't work, try:
```shell
$ sudo apt-get install libcupti-dev
```
To profile a system with **multiple GPUs**, see this [guide](https://github.com/tensorflow/profiler/blob/master/docs/profile_multi_gpu.md) for details.
To profile multi-worker GPU configurations, profile individual workers
independently.
To profile cloud TPUs, you must have access to Google Cloud TPUs.
## Quick Start
In order to get the latest version of the profiler plugin, you can install the
nightly package.
To install the nightly version of profiler:
```
$ pip uninstall xprof
$ pip install xprof-nightly
```
Without TensorBoard:
```
$ xprof --logdir=profiler/demo --port=6006
```
With TensorBoard:
```
$ tensorboard --logdir=profiler/demo
```
If you are behind a corporate firewall, you may need to include the `--bind_all`
tensorboard flag.
Go to `localhost:6006/#profile` of your browser, you should now see the demo
overview page show up.
Congratulations! You're now ready to capture a profile.
## Next Steps
* JAX Profiling Guide: https://jax.readthedocs.io/en/latest/profiling.html
* TensorFlow Profiling Guide: https://tensorflow.org/guide/profiler
* Cloud TPU Profiling Guide: https://cloud.google.com/tpu/docs/cloud-tpu-tools
* Colab Tutorial: https://www.tensorflow.org/tensorboard/tensorboard_profiling_keras
* Tensorflow Colab: https://www.tensorflow.org/tensorboard/tensorboard_profiling_keras
Raw data
{
"_id": null,
"home_page": "https://github.com/openxla/xprof",
"name": "xprof-nightly",
"maintainer": null,
"docs_url": null,
"requires_python": "!=3.0.*,!=3.1.*,>=2.7",
"maintainer_email": null,
"keywords": "jax pytorch xla tensorflow tensorboard xprof profile plugin",
"author": "Google Inc.",
"author_email": "packages@tensorflow.org",
"download_url": "https://files.pythonhosted.org/packages/d0/43/3deb71725c8a076f74c4fc1964cbf9aa2ee4bf158eec5519f3866aeed2be/xprof_nightly-2.21.4a20250727.tar.gz",
"platform": null,
"description": "# XProf (+ Tensorboard Profiler Plugin)\nXProf includes a suite of tools for [JAX](https://jax.readthedocs.io/), [TensorFlow](https://www.tensorflow.org/), and [PyTorch/XLA](https://github.com/pytorch/xla). These tools help you understand, debug and optimize programs to run on CPUs, GPUs and TPUs.\n\nXProf offers a number of tools to analyse and visualize the\nperformance of your model across multiple devices. Some of the tools include:\n\n* **Overview**: A high-level overview of the performance of your model. This\n is an aggregated overview for your host and all devices. It includes:\n * Performance summary and breakdown of step times.\n * A graph of individual step times.\n * A table of the top 10 most expensive operations.\n* **Trace Viewer**: Displays a timeline of the execution of your model that shows:\n * The duration of each op.\n * Which part of the system (host or device) executed an op.\n * The communication between devices.\n* **Memory Profile Viewer**: Monitors the memory usage of your model.\n* **Graph Viewer**: A visualization of the graph structure of HLOs of your model.\n\n## Demo\nFirst time user? Come and check out this [Colab Demo](https://docs.jaxstack.ai/en/latest/JAX_for_LLM_pretraining.html).\n\n## Prerequisites\n\n* tensorboard-plugin-profile >= 2.19.0\n* (optional) TensorBoard >= 2.19.0\n\nNote: XProf requires access to the Internet to load the [Google Chart library](https://developers.google.com/chart/interactive/docs/basic_load_libs#basic-library-loading).\nSome charts and tables may be missing if you run TensorBoard entirely offline on\nyour local machine, behind a corporate firewall, or in a datacenter.\n\nTo profile on a **single GPU** system, the following NVIDIA software must be\ninstalled on your system:\n\n1. NVIDIA GPU drivers and CUDA Toolkit:\n * CUDA 12.5 requires 525.60.13 and higher.\n2. Ensure that CUPTI 10.1 exists on the path.\n\n ```shell\n $ /sbin/ldconfig -N -v $(sed 's/:/ /g' <<< $LD_LIBRARY_PATH) | grep libcupti\n ```\n\n If you don't see `libcupti.so.12.5` on the path, prepend its installation\n directory to the $LD_LIBRARY_PATH environmental variable:\n\n ```shell\n $ export LD_LIBRARY_PATH=/usr/local/cuda/extras/CUPTI/lib64:$LD_LIBRARY_PATH\n ```\n Run the ldconfig command above again to verify that the CUPTI 12.5 library is\n found.\n\n If this doesn't work, try:\n ```shell\n $ sudo apt-get install libcupti-dev\n ```\n\nTo profile a system with **multiple GPUs**, see this [guide](https://github.com/tensorflow/profiler/blob/master/docs/profile_multi_gpu.md) for details.\n\nTo profile multi-worker GPU configurations, profile individual workers\nindependently.\n\nTo profile cloud TPUs, you must have access to Google Cloud TPUs.\n\n## Quick Start\nIn order to get the latest version of the profiler plugin, you can install the\nnightly package.\n\nTo install the nightly version of profiler:\n\n```\n$ pip uninstall xprof\n$ pip install xprof-nightly\n```\n\nWithout TensorBoard:\n```\n$ xprof --logdir=profiler/demo --port=6006\n```\n\nWith TensorBoard:\n\n```\n$ tensorboard --logdir=profiler/demo\n```\nIf you are behind a corporate firewall, you may need to include the `--bind_all`\ntensorboard flag.\n\nGo to `localhost:6006/#profile` of your browser, you should now see the demo\noverview page show up.\nCongratulations! You're now ready to capture a profile.\n\n## Next Steps\n\n* JAX Profiling Guide: https://jax.readthedocs.io/en/latest/profiling.html\n* TensorFlow Profiling Guide: https://tensorflow.org/guide/profiler\n* Cloud TPU Profiling Guide: https://cloud.google.com/tpu/docs/cloud-tpu-tools\n* Colab Tutorial: https://www.tensorflow.org/tensorboard/tensorboard_profiling_keras\n* Tensorflow Colab: https://www.tensorflow.org/tensorboard/tensorboard_profiling_keras\n",
"bugtrack_url": null,
"license": "Apache 2.0",
"summary": "XProf Profiler Plugin",
"version": "2.21.4a20250727",
"project_urls": {
"Homepage": "https://github.com/openxla/xprof"
},
"split_keywords": [
"jax",
"pytorch",
"xla",
"tensorflow",
"tensorboard",
"xprof",
"profile",
"plugin"
],
"urls": [
{
"comment_text": null,
"digests": {
"blake2b_256": "59963997667f9551bb8504c1f11da09573a1b4d1bcadbc75d5a8f3db868e72ae",
"md5": "23a026ae2982cd4042ef59cd7ab88ca6",
"sha256": "aca2d6232c2d01a738b8233ea1dfb12ab8596e2e384b277eaee352af4504bdc8"
},
"downloads": -1,
"filename": "xprof_nightly-2.21.4a20250727-cp310-none-macosx_12_0_arm64.whl",
"has_sig": false,
"md5_digest": "23a026ae2982cd4042ef59cd7ab88ca6",
"packagetype": "bdist_wheel",
"python_version": "cp310",
"requires_python": "!=3.0.*,!=3.1.*,>=2.7",
"size": 10902202,
"upload_time": "2025-07-27T09:11:59",
"upload_time_iso_8601": "2025-07-27T09:11:59.269152Z",
"url": "https://files.pythonhosted.org/packages/59/96/3997667f9551bb8504c1f11da09573a1b4d1bcadbc75d5a8f3db868e72ae/xprof_nightly-2.21.4a20250727-cp310-none-macosx_12_0_arm64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "4d2ef4fd4b1e47e5647e357d2fa4678bcf7e3fb5c40a0d69e27fa7106f6a0819",
"md5": "e33ae9f591a0c42da8f8fb30e7bd492a",
"sha256": "faa6341470b674bf0c0b5b5c032a2163019340681c5c26d5c96edc3b3930eb22"
},
"downloads": -1,
"filename": "xprof_nightly-2.21.4a20250727-cp310-none-manylinux2014_x86_64.whl",
"has_sig": false,
"md5_digest": "e33ae9f591a0c42da8f8fb30e7bd492a",
"packagetype": "bdist_wheel",
"python_version": "cp310",
"requires_python": "!=3.0.*,!=3.1.*,>=2.7",
"size": 12766208,
"upload_time": "2025-07-27T09:33:30",
"upload_time_iso_8601": "2025-07-27T09:33:30.288013Z",
"url": "https://files.pythonhosted.org/packages/4d/2e/f4fd4b1e47e5647e357d2fa4678bcf7e3fb5c40a0d69e27fa7106f6a0819/xprof_nightly-2.21.4a20250727-cp310-none-manylinux2014_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "bf9eeb3135ae9d3d085e8b40e9c2da1fd754100e320a7a26d3ddc16a90c1fb73",
"md5": "c202516935360e96ba543618f91b31d5",
"sha256": "4e2a4b4c531728c1a6e4203b810c76cd24ee022e644d1485d66722732911a0f3"
},
"downloads": -1,
"filename": "xprof_nightly-2.21.4a20250727-cp310-none-win_amd64.whl",
"has_sig": false,
"md5_digest": "c202516935360e96ba543618f91b31d5",
"packagetype": "bdist_wheel",
"python_version": "cp310",
"requires_python": "!=3.0.*,!=3.1.*,>=2.7",
"size": 10684866,
"upload_time": "2025-07-27T09:27:37",
"upload_time_iso_8601": "2025-07-27T09:27:37.084047Z",
"url": "https://files.pythonhosted.org/packages/bf/9e/eb3135ae9d3d085e8b40e9c2da1fd754100e320a7a26d3ddc16a90c1fb73/xprof_nightly-2.21.4a20250727-cp310-none-win_amd64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "c3d43dd720042cefde6ea9024be4d633f0f4aba2c1334c2f814efd944d5bedb6",
"md5": "11812e957bc9774e33511fc4be5245c4",
"sha256": "906a55b5a819b2eca271dd8eb32154c006f7d5b78c43e4000590d06a385ce037"
},
"downloads": -1,
"filename": "xprof_nightly-2.21.4a20250727-cp311-none-macosx_12_0_arm64.whl",
"has_sig": false,
"md5_digest": "11812e957bc9774e33511fc4be5245c4",
"packagetype": "bdist_wheel",
"python_version": "cp311",
"requires_python": "!=3.0.*,!=3.1.*,>=2.7",
"size": 10904347,
"upload_time": "2025-07-27T09:11:57",
"upload_time_iso_8601": "2025-07-27T09:11:57.877482Z",
"url": "https://files.pythonhosted.org/packages/c3/d4/3dd720042cefde6ea9024be4d633f0f4aba2c1334c2f814efd944d5bedb6/xprof_nightly-2.21.4a20250727-cp311-none-macosx_12_0_arm64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "9ee65420b742dcede2d8b123f8850f65b1074fb9d1fc0e1a4161ecf76504c2cf",
"md5": "2482ca57c189ea634107afcff85951cf",
"sha256": "bb72cbf88dba97e0a51a4ddf3f32455887ba91987017824dd81747d4e2e9f8a9"
},
"downloads": -1,
"filename": "xprof_nightly-2.21.4a20250727-cp311-none-manylinux2014_x86_64.whl",
"has_sig": false,
"md5_digest": "2482ca57c189ea634107afcff85951cf",
"packagetype": "bdist_wheel",
"python_version": "cp311",
"requires_python": "!=3.0.*,!=3.1.*,>=2.7",
"size": 12768441,
"upload_time": "2025-07-27T09:36:08",
"upload_time_iso_8601": "2025-07-27T09:36:08.749315Z",
"url": "https://files.pythonhosted.org/packages/9e/e6/5420b742dcede2d8b123f8850f65b1074fb9d1fc0e1a4161ecf76504c2cf/xprof_nightly-2.21.4a20250727-cp311-none-manylinux2014_x86_64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "60046022383081e6907faee33e9d700dfeb4f1a5762a82f7b1d2154d02ab7165",
"md5": "3e268b9e6f50c38954d470c12d317e82",
"sha256": "e9028a49e3a5636abe553b09e47dd008c4bce2162cb5c1ed0cb30cdcdd824437"
},
"downloads": -1,
"filename": "xprof_nightly-2.21.4a20250727-cp311-none-win_amd64.whl",
"has_sig": false,
"md5_digest": "3e268b9e6f50c38954d470c12d317e82",
"packagetype": "bdist_wheel",
"python_version": "cp311",
"requires_python": "!=3.0.*,!=3.1.*,>=2.7",
"size": 10686357,
"upload_time": "2025-07-27T09:38:09",
"upload_time_iso_8601": "2025-07-27T09:38:09.554097Z",
"url": "https://files.pythonhosted.org/packages/60/04/6022383081e6907faee33e9d700dfeb4f1a5762a82f7b1d2154d02ab7165/xprof_nightly-2.21.4a20250727-cp311-none-win_amd64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "ad7b43146bc5e3d48983719f54138e3c1868db81a9c08f89352d70e0e61f86ef",
"md5": "f90379fc61e680c4f5472ff93b639013",
"sha256": "be1487d9a68fe38aad73fb727562d4f6f5fc201326cb867c5849f28ddc1f1a96"
},
"downloads": -1,
"filename": "xprof_nightly-2.21.4a20250727-cp312-none-macosx_12_0_arm64.whl",
"has_sig": false,
"md5_digest": "f90379fc61e680c4f5472ff93b639013",
"packagetype": "bdist_wheel",
"python_version": "cp312",
"requires_python": "!=3.0.*,!=3.1.*,>=2.7",
"size": 10904561,
"upload_time": "2025-07-27T09:11:46",
"upload_time_iso_8601": "2025-07-27T09:11:46.816469Z",
"url": "https://files.pythonhosted.org/packages/ad/7b/43146bc5e3d48983719f54138e3c1868db81a9c08f89352d70e0e61f86ef/xprof_nightly-2.21.4a20250727-cp312-none-macosx_12_0_arm64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "1e7bfb8f1ea2be4df31000aabd841c09fe6971d10870e5695757b2ad6c7c45e4",
"md5": "17d49d1e73b045da03175467072aa0ef",
"sha256": "83ce032642c7751b30ef9ed025c8651a7d9d78579bdcace42f4cb025a3a60964"
},
"downloads": -1,
"filename": "xprof_nightly-2.21.4a20250727-cp312-none-win_amd64.whl",
"has_sig": false,
"md5_digest": "17d49d1e73b045da03175467072aa0ef",
"packagetype": "bdist_wheel",
"python_version": "cp312",
"requires_python": "!=3.0.*,!=3.1.*,>=2.7",
"size": 10685534,
"upload_time": "2025-07-27T09:15:57",
"upload_time_iso_8601": "2025-07-27T09:15:57.255449Z",
"url": "https://files.pythonhosted.org/packages/1e/7b/fb8f1ea2be4df31000aabd841c09fe6971d10870e5695757b2ad6c7c45e4/xprof_nightly-2.21.4a20250727-cp312-none-win_amd64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "6f72831ce1831c516a1399be397ea58c5c8748f0f53f88a76dcb03f24f56ccf3",
"md5": "593be548923a84a90ba078f63fbba459",
"sha256": "e661ef0bc56441539892f9fae269653f3d2d631d2a67c0d11cb217b72f77e9b2"
},
"downloads": -1,
"filename": "xprof_nightly-2.21.4a20250727-cp39-none-win_amd64.whl",
"has_sig": false,
"md5_digest": "593be548923a84a90ba078f63fbba459",
"packagetype": "bdist_wheel",
"python_version": "cp39",
"requires_python": "!=3.0.*,!=3.1.*,>=2.7",
"size": 10684852,
"upload_time": "2025-07-27T09:38:15",
"upload_time_iso_8601": "2025-07-27T09:38:15.644969Z",
"url": "https://files.pythonhosted.org/packages/6f/72/831ce1831c516a1399be397ea58c5c8748f0f53f88a76dcb03f24f56ccf3/xprof_nightly-2.21.4a20250727-cp39-none-win_amd64.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "c3eeb47af2cc9799b08e05398d7414f9dfaf43408e20c4176c12925fbfb2ee43",
"md5": "44f2508502f7d0e13f11aeb7d2ea7d83",
"sha256": "7ca3208a53701c515d1785915e6f482ffd645b46f544f2a2d8244d2842a55651"
},
"downloads": -1,
"filename": "xprof_nightly-2.21.4a20250727-py3-none-any.whl",
"has_sig": false,
"md5_digest": "44f2508502f7d0e13f11aeb7d2ea7d83",
"packagetype": "bdist_wheel",
"python_version": "py3",
"requires_python": "!=3.0.*,!=3.1.*,>=2.7",
"size": 6086488,
"upload_time": "2025-07-27T09:31:44",
"upload_time_iso_8601": "2025-07-27T09:31:44.904818Z",
"url": "https://files.pythonhosted.org/packages/c3/ee/b47af2cc9799b08e05398d7414f9dfaf43408e20c4176c12925fbfb2ee43/xprof_nightly-2.21.4a20250727-py3-none-any.whl",
"yanked": false,
"yanked_reason": null
},
{
"comment_text": null,
"digests": {
"blake2b_256": "d0433deb71725c8a076f74c4fc1964cbf9aa2ee4bf158eec5519f3866aeed2be",
"md5": "6fac290d6dc3f55886e2c9d7383152f6",
"sha256": "e81f50d05de20cf44da02e51c69c3553186c496546cd222dbe6600fed7e9adf1"
},
"downloads": -1,
"filename": "xprof_nightly-2.21.4a20250727.tar.gz",
"has_sig": false,
"md5_digest": "6fac290d6dc3f55886e2c9d7383152f6",
"packagetype": "sdist",
"python_version": "source",
"requires_python": "!=3.0.*,!=3.1.*,>=2.7",
"size": 5996767,
"upload_time": "2025-07-27T09:31:46",
"upload_time_iso_8601": "2025-07-27T09:31:46.701475Z",
"url": "https://files.pythonhosted.org/packages/d0/43/3deb71725c8a076f74c4fc1964cbf9aa2ee4bf158eec5519f3866aeed2be/xprof_nightly-2.21.4a20250727.tar.gz",
"yanked": false,
"yanked_reason": null
}
],
"upload_time": "2025-07-27 09:31:46",
"github": true,
"gitlab": false,
"bitbucket": false,
"codeberg": false,
"github_user": "openxla",
"github_project": "xprof",
"travis_ci": false,
"coveralls": false,
"github_actions": false,
"lcname": "xprof-nightly"
}