How to get HiPACE++ running on Glen White's PC
Useful documentation on building/installing HiPACE++: https://hipace.readthedocs.io/en/latest/building/building.html
ssh into Glen's PC (from my laptop, typically I would ssh into
centos7
and then ssh intopc95258
).I set up an ssh hop proxy for ease of access (in
.ssh/config
):Host centos7-proxy
HostName centos7.slac.stanford.edu
User mvarvera
ControlMaster auto
ControlPath ~/.ssh/master-%r@%h:%p
Host pc95258-proxy
HostName pc95258
User mvarvera
ControlMaster auto
ControlPath ~/.ssh/master-%r@%h:%p
ProxyJump centos7-proxy
Use Spack to create an environment for HiPACE++
spack env create hipace-dev spack env activate hipace-dev spack add ccache % gcc@11.3.0
spack add cmake % gcc@11.3.0
spack add fftw % gcc@11.3.0
spack add hdf5 % gcc@11.3.0 spack add mpi % gcc@11.3.0
spack add pkgconfig % gcc@11.3.0
spack add cuda % gcc@11.3.0 spack install % gcc@11.3.0It will take a while to install everything...(As per the HiPACE++ documentation: in new terminals, re-activate the environment with
spack env activate hipace-dev
again)
Then edit thespack config
and changeunify: true
tounify: when_possible
spack config edit Configure the compiler
export CC=$(which gcc) export CXX=$(which g++)
export CUDACXX=$(which nvcc) export CUDAHOSTCXX=$(which g++-7)For some reason g++ versions above 8 are unsupported with the version of CUDA I used, so you have to manually set
CUDAHOSTCXX
to yourg++-7
path (version 8 is not on this machine I guess but 7 seems to work for my purposes)- Clone the HiPACE++ GitHub repo:
`git clone https://github.com/Hi-PACE/hipace.git $HOME/src/hipace # or choose your preferred path`
- configure the program (run this in
$HOME/src/hipace
directory):cmake -S . -B build -DHiPACE_COMPUTE=CUDA
- build using
n
threads (replace n with an integer, 4 for example):
cmake --build build -j <n> - To run a simulation, you can execute:
<path>/<to>/hipace/build/bin/hipace <input_file_name>
Useful links
GitHub with relevant code: https://github.com/MaxVarverakis/PositronPWFA
Summer internship overview slides: https://docs.google.com/presentation/d/11A7qlPXztxuoElt8Cbj2m_hojxxPuYZjqP9pSMLbxg4/edit?usp=sharing
Slides from meeting with Severin Diederichs, Carl Schroeder, Spencer Gessner, Robert Holtzapple: https://docs.google.com/presentation/d/1VmR9LG82rfL51h9zfaRNk5lMi9Xj31UNgLKcDrwNl9o/edit?usp=sharing
Linear regime analysis notes/comparisons to simulations: Linear_WFA_Notes.pdf