Science Score: 41.0%
This score indicates how likely this project is to be science-related based on various indicators:
-
✓CITATION.cff file
Found CITATION.cff file -
✓codemeta.json file
Found codemeta.json file -
○.zenodo.json file
-
○DOI references
-
✓Academic publication links
Links to: zenodo.org -
○Academic email domains
-
○Institutional organization owner
-
○JOSS paper metadata
-
○Scientific vocabulary similarity
Low similarity (15.5%) to scientific vocabulary
Repository
Tristan-MP v2 [public]
Basic Info
- Host: GitHub
- Owner: PrincetonUniversity
- License: bsd-3-clause
- Language: Fortran
- Default Branch: master
- Homepage: https://princetonuniversity.github.io/tristan-v2/
- Size: 657 KB
Statistics
- Stars: 14
- Watchers: 4
- Forks: 3
- Open Issues: 5
- Releases: 6
Metadata Files
README.md
Tristan v2.9
For detailed tutorials and code description please visit our wiki. If you are a new user testing the code on a new computer cluster, please consider contributing to this chapter about cluster-specific configuration to make the life easier for future generations.
Getting Started
Prerequisites
- MPI (either OpenMPI or Intel-MPI; mpich is currently untested)
- GCC or Intel Fortran compiler
- (optional) Parallel HDF5 (compiled with either OpenMPI or Intel-MPI)
On clusters typically all you need to do is to load the specific modules see here.
If you are, however, running on a local machine make sure to install the following prerequisites (assuming non-Intel compiler):
apt (Debian-like)
```sh
gcc + openmpi
sudo apt install build-essential libopenmpi-dev
hdf5
sudo apt libhdf5-openmpi-dev hdf5-tools ```
pacman (Arch-like)
```sh
gcc + openmpi
sudo pacman -S base-devel gcc gcc-fortran openmpi
hdf5
sudo pacman -S hdf5-openmpi ```
Also make sure you have a working
python3(v3.8+) installation to be able to configure the code orCmake.
Usage
Compiling with configure.py + GNU Make
```shell
to view all configuration options
python3 configure.py -h
to configure the code (example)
python3 configure.py -mpi08 --user=user2drec -2d
compile and link (-j compiles in parallel which is much faster)
make -j
executable will be in the bin/ directory
```
Compiling with cmake
Since v2.8 we also support cmake for the code configuration.
```sh
to configure the code (example)
cmake -B build -D mpi08=ON -D hdf5=ON -D user=user2drec -D dim=2
compile
cmake --build build -j
executable will be in the build/src/ directory (*.xc extension)
```
Running:
```sh
run the code (on clusters need to do srun, or irun etc. depending on the cluster)
mpirun -np
Docker
Another way to avoid the tedium of installing libraries (especially for local development) is to use Docker containers. This approach allows to quickly create an isolated linux environment with all the necessary packages already preinstalled (similar to a VM, but much lighter). The best thing is that VSCode can natively attach to a running container, and all the development can be done there (make sure to install the appropriate extension).
To get started with this approach, make sure to install the Docker (as well as the Docker-compose) then simply follow these steps.
```shell
from tristan root diretory
cd docker
launch the container in the background (first-time run might take a few mins)
docker-compose up -d
if you are attempting to also force rebuild the container, use the --build flag
docker-compose up -d --build
ensure the container is running
docker ps ```
Then you can attach to the container via VSCode, or if you prefer the terminal, simply attach to the running container by doing: ```shell docker exec -it trv2 zsh
then the code will be in the /home/$USER/tristan-v2 directory
cd /home/$USER/tristan-v2
``
To stop the container rundocker-compose stop. To stop and delete the container simply rundocker-compose downfrom the samedocker/` directory.
Each container has in principle its own isolated filesystem, aside from the shared
/root/tristan-v2directory. Any changes to the rest of the container's filesystem are discarded when the container is deleted (either viadocker-compose downor directlydocker rm <CONTAINER>).
For developers/users
Branching Policy
To prevent v2 from growing to become the Lovecraftian monster it once was we highly encourage both users and developers to follow the guidelines on branching policies.
- For development:
- all the new features shall be added to
dev/<feature>branch; - as soon as the new features are tested they can be pushed to the main development branch:
dev/main.
- all the new features shall be added to
- For users:
- user-specific branches are allowed (e.g. to test userfiles), but as soon as it works we highly encourage people to merge their new userfiles to
dev; - the naming for user-specific branches shall be the following:
user/<problem>oruser/<username>; - if any of the core routines is modified, we highly encourage to use the
dev/...branching instead of theuser/....
- user-specific branches are allowed (e.g. to test userfiles), but as soon as it works we highly encourage people to merge their new userfiles to
The dev/main branch is the most up-to-date tested version of the code, and it will be merged to master as soon as all the new features are documented.
Development
Since v2.4 code formatting policy is employed. To follow the proper formatting automatically we use the fprettify tool. To install fprettify in the local directory (via pip) one can use the dev-requirements.txt file, by running the following:
```sh
create a local pip environment
python3 -m venv .venv
activate it
source .venv/bin/activate
install required modules
pip install fprettify ```
After that one can either use the tool in a stand-alone manner:
sh
.venv/bin/fprettify -i 2 -w 4 --whitespace-assignment true --enable-decl --whitespace-decl true --whitespace-relational true --whitespace-logical true --whitespace-plusminus true --whitespace-multdiv true --whitespace-print true --whitespace-type true --whitespace-intrinsics true --enable-replacements -l 1000 [FILENAME.F90]
or in the VSCode environment (see the extension list in the .vscode/settings.json of the current repo).
Contributors (alphabetical order)
- Fabio Bacchini (KU Leuven)
- Alexander Chernoglazov (Univ. of Maryland)
- Daniel Groselj (KU Leuven)
- Hayk Hakobyan (Columbia/PPPL)
- Jens Mahlmann (Columbia)
- Arno Vanthieghem (Univ. of Paris)
Board of trustees
- Prof. Anatoly Spitkovsky (Princeton)
- Prof. Sasha Philippov (Univ. of Maryland)
Publications
@TODO
Latest Releases
v2.9Dec 2024- removed
tristanVis(seegraph-et) - cleanups & updated instructions
- minor bugfixes
- removed
v2.8Apr 2024- cmake support
- minor reformatting + bugfixes
v2.6.1Aug 2023- Fixed a buggy ordering of synchrotron cooling term and particle coordinate update (very minor correction)
v2.6Jan 2023- Minor cleanup + bugfixes
v2.6r1Nov 2022- New absorption treatment with target B-field specified in the userfile
- Fieldsolvers separated into different files
v2.5.2Nov 2022- Compton module now has
nph_over_neto mimic high photon-to-lepton ratio absorb_xnow takes care of absorbing boundary conditions, whileboundary_xis for MPI- New userfiles for compton-mediated turbulence and reconnection
- Minor non-critical bugs
- Compton module now has
v2.5.1Aug 2022- Minor configure bug when working with non-intel compilers
- Minor bug with
usroutputflag
v2.5Jul 2022- Proper makefile/compilation command
- Double precision option
- Auto converter for public version releases
v2.4Jun 2022- Stress-energy tensor output
mpiparticle alignment issue- Formatting (see the "for developers" section)
- Compilation linking with non-intel compilers
- minor warnings on gcc + intel fixed
v2.3Feb 2022- Reproducibility (blocking MPI comms)
- New boundary/injection conditions in the reconnection userfile
- Minor bugfixes
v2.2May 2021- Adaptive load balancing
- Dynamic reallocation of tiles (more stable on low memory machines, slightly slower)
- Explicit low-memory mode for clusters such as frontera (-lowmem flag)
- User-specific output added at runtime
- Updated the fulltest.py facility (see wiki)
- Debug levels (0, 1, 2)
- A facility for warnings and diagnostic output (see wiki)
- Coupling of GCA with Vay pusher
- Cooling limiter
- Fluid velocity output
- Major bugfix in the momentum output
- Major restructuring in the initializer
- Minor improvements, restructurings and bugfixes
v2.1.2Mar 2021- Dynamic reallocation of tiles
- Coupling of GCA with Vay pusher
- Major restructuring in the initializer
- A facility for warnings and diagnostic output
- Cooling limiter
- Fluid velocity output
- Lots of subroutines to be used in the future for the adaptive load balancing
- Minor improvements, restructurings and bugfixes
v2.1.1Jan 2021- Patched the Compton cross section normalization
- Minor bug fixes
v2.1Dec 2020- Pair annihilation module (+ advanced test for all QED modules coupled)
- Merging of charged particles
- Particle payloads
- Vay pusher
- Individual particle current deposition (necessary for reflecting walls and downsampling of charged particles)
- Spatial binning for spectra
- Automated testing framework with fulltest.py
- Major restructuring of output modules
- Major restructuring of QED modules
- Minor issues fixed for GCA pusher
v2.0.1Jul 2020- Compton scattering and GCA pusher added
- Slice outputs for 3d added
- Particle momentum binning improved for downsampling
- Minor bugs fixed
Owner
- Name: PrincetonUniversity
- Login: PrincetonUniversity
- Kind: organization
- Repositories: 215
- Profile: https://github.com/PrincetonUniversity
Citation (CITATION)
If you use `Tristan v2` for work/research presented in a publication (whether directly, or as a dependency to another package), we recommend and encourage the following acknowledgment:
This research made use of "Tristan v2" particle-in-cell code.
You may also use the following `bibtex` entry:
```
@software{tristan_v2,
author = {Hayk Hakobyan and
Anatoly Spitkovsky and
Alexander Chernoglazov and
Alexander Philippov and
Daniel Groselj and
Jens Mahlmann and
Fabio Bacchini and
Arno Vanthieghem},
title = {PrincetonUniversity/tristan-mp-v2: v2.9},
month = dec,
year = 2024,
publisher = {Zenodo},
version = {v2.9},
doi = {10.5281/zenodo.14564000},
url = {https://doi.org/10.5281/zenodo.14564000},
swhid = {swh:1:dir:20798c1a67f0f7c6b85b2cb20cfac127bef83439
;origin=https://doi.org/10.5281/zenodo.7566724;vis
it=swh:1:snp:10419ef8096cc0f9f9977c1660c5abd64f8ba
2c4;anchor=swh:1:rel:2bf66a253a6dfc77c989e60734d1c
638109d3893;path=PrincetonUniversity-tristan-
mp-v2-e0d1cfb
},
}
```
We also recommend to link to the source code on github: https://github.com/PrincetonUniversity/tristan-mp-v2.
GitHub Events
Total
- Create event: 1
- Release event: 1
- Issues event: 5
- Watch event: 5
- Issue comment event: 1
- Push event: 2
- Fork event: 4
Last Year
- Create event: 1
- Release event: 1
- Issues event: 5
- Watch event: 5
- Issue comment event: 1
- Push event: 2
- Fork event: 4
Issues and Pull Requests
Last synced: over 1 year ago
All Time
- Total issues: 19
- Total pull requests: 2
- Average time to close issues: 8 months
- Average time to close pull requests: 1 minute
- Total issue authors: 11
- Total pull request authors: 1
- Average comments per issue: 3.53
- Average comments per pull request: 0.0
- Merged pull requests: 2
- Bot issues: 0
- Bot pull requests: 0
Past Year
- Issues: 4
- Pull requests: 0
- Average time to close issues: N/A
- Average time to close pull requests: N/A
- Issue authors: 2
- Pull request authors: 0
- Average comments per issue: 1.25
- Average comments per pull request: 0
- Merged pull requests: 0
- Bot issues: 0
- Bot pull requests: 0
Top Authors
Issue Authors
- rgill3141 (5)
- marc-shen (4)
- haykh (1)
- SennDegrare (1)
- JiamingZhuge (1)
- chandtej11 (1)
- smallrainbow (1)
- Tissot11 (1)
- omguptaup (1)
- pcrumley (1)
- akbwyfc (1)
Pull Request Authors
- haykh (2)
Top Labels
Issue Labels
Pull Request Labels
Dependencies
- ConfigArgParse ==1.5.3
- autopep8 ==1.6.0
- fprettify ==0.3.7
- json5 ==0.9.8
- packaging ==21.3
- pycodestyle ==2.8.0
- pyparsing ==3.0.9
- toml ==0.10.2
- ubuntu 20.04 build
- tristan-v2 latest
- ubuntu 20.04 build
- tristan-v2 latest
- ConfigArgParse ==1.5.3 development
- autopep8 ==1.6.0 development
- fprettify ==0.3.7 development
- json5 ==0.9.8 development
- packaging ==21.3 development
- pycodestyle ==2.8.0 development
- pyparsing ==3.0.9 development
- toml ==0.10.2 development