https://github.com/ucl/research-computing-with-cpp
UCL-ARC *C++ for Research* course
https://github.com/ucl/research-computing-with-cpp
c-plus-plus course gpu mpi openmp ucl
Last synced: 9 months ago
JSON representation
UCL-ARC *C++ for Research* course
- Host: GitHub
- URL: https://github.com/ucl/research-computing-with-cpp
- Owner: UCL
- Created: 2014-09-22T11:07:01.000Z (over 11 years ago)
- Default Branch: main
- Last Pushed: 2025-03-19T11:26:20.000Z (10 months ago)
- Last Synced: 2025-03-28T20:18:53.222Z (10 months ago)
- Topics: c-plus-plus, course, gpu, mpi, openmp, ucl
- Language: Ruby
- Homepage: https://github-pages.ucl.ac.uk/research-computing-with-cpp/
- Size: 19.4 MB
- Stars: 28
- Watchers: 33
- Forks: 20
- Open Issues: 15
-
Metadata Files:
- Readme: README.md
Awesome Lists containing this project
README
research-computing-with-cpp
===========================
Deployed at:
http://github-pages.ucl.ac.uk/research-computing-with-cpp
How to build the lessons locally
-----------------------------------
Clone and build the various output files (that step will need some dependencies)
``` bash
git clone https://github.com/UCL-RITS/research-computing-with-cpp
cd research-computing-with-cpp
./build.sh
```
Then you can proceed to build the website locally. The easiest is via docker.
```bash
mkdir ../bundle # To don't download every single time the ruby dependencies
docker run --rm --volume="$PWD:/srv/jekyll" --volume="$PWD/../bundle:/usr/local/bundle" -it jekyll/jekyll:4 jekyll build
python -m http.server -d _site
```
Dependencies
-------------
All the dependencies are set in the `.github/{texlive,python}/requirements.txt` for an ubuntu machine.
On a Mac, we use g++ installed via [homebrew](https://brew.sh/). So, for g++ version 7, we would run the build command as:
``` bash
CC=gcc-7 CXX=g++-7 ./build.sh
```
The explicit compiler selection is needed on Mac OS for OpenMP (and possibly MPI)
examples to build. Update the version number as necessary.
You will need to have a bunch of stuff installed in order for the build to succeed.
For Mac:
* Libraries:
* `brew install boost`
* For building MPI and OpenMP examples:
* `brew install open-mpi`
* `brew install gcc`
* Ruby stuff:
* `brew install ruby`
* `gem install jekyll --version '~> 4'`
* `gem install kramdown --version '~> 2.3.1'
* `gem install jekyll-remote-theme`
`
* Other utilities:
* `brew install wget`
* Python libraries:
* `matplotlib` (plus several other scientific python libraries)
A full LaTeX distribution needs to be available to generate a PDF version of the course notes by the build script.
Alternatively, you can build the docker container available and build the site through it:
```
$ docker build -t rcpp
$ docker run -it --rm --volume=$PWD:/root rcpp:latest bash
# cd
# ITK_DIR=/usr/lib/InsightToolkit ./build.sh
# make _site
```
Then in folder _site, you'll have the `html`'s.
Or, for a shortcut: `make preview`
See https://github.com/UCL-RITS/research-computing-with-cpp/blob/master/01cpp/index.md for an example of how to reference a C file, CMake file, and run an executable
And https://github.com/UCL-RITS/research-computing-with-cpp/tree/master/01cpp/cpp/hello
for the corresponding code