Code Monkey home page Code Monkey logo

programming-massively-parallel-processors's Introduction

Programming-Massively-Parallel-Processors

About

This repository is splitted into two sections:

  • The first section found in Chapters contains source code and information from the book "Programming Massively Parallel Processors" by David B. Kirk and Wen-mei W. Hwu. You can find the book here.

  • The second section found in Performance-Tests-NvBench contains benchmarks done with the NvBench Project.


Preperation for the benchmarks

To use this project and run the benchmarks, you will need:

  • A NVIDIA GPU with CUDA support. You can find a list of supported GPUs here.
  • The NVIDIA CUDA Toolkit installed on your system. You can find the latest version here.
  • The CMAKE tool installed on your system. You can find the latest version here.
  • Git installed on your system. You can find the latest version here.
  • (Optional) Python installed on your system. You can find the latest version here.
  • (Optional) Miniconda installed on your system. You can find the latest version here.

The Optional tools are only needed if you want to run the python script extract_stats.py to generate plots from the csv files generated by the benchmarks.


How to use this project

Clone this repository to your local machine:

git clone --recursive https://github.com/R100001/Programming-Massively-Parallel-Processors.git

Then, create a build directory and run CMAKE:

cd Performance-Tests-NvBench
mkdir build
cd build
cmake ..

Finally, build the project:

cmake --build .

This project contains ready CMAKELISTS.txt files for the benchmarks. You can change them to fit your needs.


How to run the benchmarks

After building the project, you can run the benchmarks by executing the out files in the corresponding directories.

You can also change the source code of the benchmarks. You can see some examples here.

There is a python script extract_stats.py that can generate plots using the csv files generated by the benchmarks. You can generate csv files by running the benchmarks with the following command:

/path/to/benchmark/executable.out --csv /path/to/csv/file.csv

You can generate the results for the benchmarks in Markdown format using the optional argument:

/path/to/benchmark/executable.out --md /path/to/markdown/file.md

To run the script it is recommended to use a virtual environment. You can create one with the following commands:

conda create -n nvbench python matplotlib
conda activate nvbench

Then, you can run the script with the following command:

python extract_stats.py --path /path/to/csvs/directory --output /path/to/output/directory --data_to_plot x1 x2 ... xn
  • x1 x2 ... xn are the column numbers in the csv files that you want to plot. You can find the names of the columns in the first line of the csv files.

programming-massively-parallel-processors's People

Contributors

r100001 avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.