Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
190 commits
Select commit Hold shift + click to select a range
1920f44
Add bulk velocity as moment output.
Aug 22, 2024
bdd96be
Update input.
Aug 26, 2024
a52d07d
Bugfix in moment calculation.
Oct 16, 2024
3e1848a
prep for conductor boundaries
LudwigBoess Feb 21, 2025
bacbe24
first stubborn attempt at conductor boundaries (broken)
LudwigBoess Feb 21, 2025
2081a39
first attempt at ConductorBoundaries_kernel
LudwigBoess Feb 21, 2025
b7a863c
bugfix
LudwigBoess Feb 21, 2025
f383e49
first attempt at Kokkos::parallel_for loop (broken)
LudwigBoess Feb 21, 2025
7666918
Ongoing.
Feb 22, 2025
af06544
Ongoing.
Feb 22, 2025
0d3cc1c
Ongoing.
Feb 22, 2025
4a57c38
Ongoing.
Feb 22, 2025
ff5a3ee
Ongoing.
Feb 22, 2025
d6b2b1c
Ongoing.
Feb 22, 2025
f0ed6c7
Ongoing.
Feb 22, 2025
79d3237
Ongoing.
Feb 22, 2025
17b469b
Ongoing.
Feb 22, 2025
e234173
Ongoing.
Feb 22, 2025
de510ea
Ongoing.
Feb 22, 2025
0524d78
Ongoing.
Feb 23, 2025
9d78b9e
Ongoing.
Feb 23, 2025
cec22b0
Ongoing.
Feb 23, 2025
b3754e2
Ongoing.
Feb 23, 2025
83dba37
Ongoing.
Feb 23, 2025
a7ef051
Ongoing.
Feb 23, 2025
d219fc4
Ongoing.
Feb 23, 2025
044ccea
Ongoing.
Feb 23, 2025
2af41d8
Ongoing.
Feb 23, 2025
056c629
Ongoing.
Feb 23, 2025
7d9a1a3
Ongoing.
Feb 23, 2025
d8abf1b
Ongoing.
Feb 26, 2025
a17db62
Ongoing.
Feb 26, 2025
1d109a0
Ongoing.
Feb 27, 2025
bee7530
Ongoing.
Feb 27, 2025
2a269fd
Ongoing.
Feb 27, 2025
49820ff
Ongoing.
Feb 27, 2025
d2167da
first attempt at single particle injection
LudwigBoess Feb 28, 2025
fc3e647
Ongoing.
Feb 28, 2025
83c144f
Ongoing.
Feb 28, 2025
7c7c3f9
Ongoing.
Feb 28, 2025
939369e
Ongoing.
Feb 28, 2025
fa5a38f
Ongoing.
Feb 28, 2025
eeca02d
Ongoing.
Feb 28, 2025
c18840c
Ongoing.
Feb 28, 2025
9085afd
Ongoing.
Feb 28, 2025
87b37be
Ongoing.
Feb 28, 2025
5712e3b
Ongoing.
Feb 28, 2025
af258c6
Ongoing.
Feb 28, 2025
86f0597
Ongoing.
Feb 28, 2025
d0ce7c8
cleanup of conductor BCs
LudwigBoess Mar 3, 2025
0fd05b9
add 3D case and set correct boundary cells to zero
LudwigBoess Mar 3, 2025
425abe5
Ongoing
jmahlmann Mar 4, 2025
cfee51e
Ongoing
jmahlmann Mar 4, 2025
7d317e6
Ongoing
jmahlmann Mar 4, 2025
21d9937
Ongoing
jmahlmann Mar 4, 2025
bd723f3
minor reformatting of conductor BC
haykh Mar 7, 2025
28a02f1
filters adapted for conducting BCs
haykh Mar 7, 2025
b800b61
revert to old pgen for testing
LudwigBoess Mar 8, 2025
2b269f3
enforce B0/E0 at boundary
LudwigBoess Mar 8, 2025
9b23732
filter test fixed
haykh Mar 8, 2025
179fafe
removed extra kokkos flags
haykh Mar 9, 2025
db1a393
Merge branch 'dev/conductor_boundary' of github.com:entity-toolkit/en…
haykh Mar 9, 2025
e644b65
nix cfgs
haykh Mar 9, 2025
158c385
Add bulk velocity as moment output.
Aug 22, 2024
334a8b1
Update input.
Aug 26, 2024
d0c98ae
Bugfix in moment calculation.
Oct 16, 2024
e7976ca
minor bookkeeping for 3vel output
haykh Mar 9, 2025
c9d69ce
implemented and tested bulk V output
haykh Mar 9, 2025
e3bc62b
rebase to 1.2.0rc
haykh Mar 9, 2025
b6fe114
revert to zero at boundary
LudwigBoess Mar 10, 2025
15ffa1b
types made uniform
haykh Mar 13, 2025
85811c9
Minor fixes of npart_t
jmahlmann Mar 13, 2025
777d1fb
cleanup of pgen
LudwigBoess Mar 13, 2025
ef5c854
update example parameter file
LudwigBoess Mar 13, 2025
66cb136
Minor fixes of npart_t
jmahlmann Mar 13, 2025
38e76bd
minor bugfix dx_min comparison + nonexistent species
haykh Mar 13, 2025
2d4e2bf
bugfix in mpihdf5 test
haykh Mar 13, 2025
330b173
Merge pull request #88 from entity-toolkit/bug/nonexistspec
haykh Mar 13, 2025
84e047c
revert to cleaner injector for shocktest
LudwigBoess Mar 19, 2025
69d4a0d
implemented new `arch::Piston` spatial distribution to set up shock p…
LudwigBoess Mar 20, 2025
e4d5979
fix inconsistency in return type
LudwigBoess Mar 20, 2025
cbc2021
Added `MovingInjector` (wip)
LudwigBoess Mar 21, 2025
70ea9af
Added `CustomPostStep` for shock pgen to continually inject particles…
LudwigBoess Mar 21, 2025
9727507
bugfix
LudwigBoess Mar 22, 2025
d7d12a3
added start time of injection and explicitly enforce injection region…
LudwigBoess Mar 22, 2025
6cf0dc8
small bugfix
LudwigBoess Mar 22, 2025
22a0479
shock pgen changed
haykh Mar 24, 2025
13da0dd
reduce resolution for faster test
LudwigBoess Mar 24, 2025
54f083f
cleanup and bugfix
LudwigBoess Mar 24, 2025
9f45d04
removed unnecessary parameter
LudwigBoess Mar 24, 2025
aa8b8e7
applied formatting to `MovingInjector`
LudwigBoess Mar 24, 2025
d0fb4ca
first attempt at moving-window injection
LudwigBoess Mar 31, 2025
4bcb1a2
extended field reset box to the right to squash waves propagating int…
LudwigBoess Apr 1, 2025
ebe6080
contribs
haykh Apr 1, 2025
08de689
rm tasks (RUNTEST)
haykh Apr 1, 2025
2132b33
bulk grpic prohibit (RUNTEST)
haykh Apr 1, 2025
0f2c91e
minor bug in tests (RUNTEST)
haykh Apr 1, 2025
a22cd96
minor bug in mpi-output tests (RUNTEST)
haykh Apr 1, 2025
068f524
Merge pull request #70 from entity-toolkit/dev/bulk
haykh Apr 1, 2025
420f36f
bugfix: added check to truncate the injection box at the end of the d…
LudwigBoess Apr 1, 2025
7686748
Lf -> f in fmt
haykh Apr 1, 2025
614e31a
Merge pull request #86 from entity-toolkit/dev/inttypes
haykh Apr 1, 2025
4ee44ec
dx_min between domains *10 acc
haykh Apr 1, 2025
8c887cb
Merge pull request #89 from entity-toolkit/bug/mpidomdx
haykh Apr 1, 2025
18f02f6
fix unit conversion bug in field reset
LudwigBoess Apr 2, 2025
e96a2d3
conductor in all directions
haykh Apr 4, 2025
af42012
prep for conductor boundaries
LudwigBoess Feb 21, 2025
7c6ddf4
first stubborn attempt at conductor boundaries (broken)
LudwigBoess Feb 21, 2025
9333b76
first attempt at ConductorBoundaries_kernel
LudwigBoess Feb 21, 2025
1565070
bugfix
LudwigBoess Feb 21, 2025
6a136fb
first attempt at Kokkos::parallel_for loop (broken)
LudwigBoess Feb 21, 2025
861e783
Ongoing.
Feb 22, 2025
cd81a5b
Ongoing.
Feb 22, 2025
aec0d41
Ongoing.
Feb 22, 2025
1c7105b
Ongoing.
Feb 22, 2025
de66f25
Ongoing.
Feb 22, 2025
2f8a01e
Ongoing.
Feb 22, 2025
2c7019b
Ongoing.
Feb 22, 2025
c041467
Ongoing.
Feb 22, 2025
b85346e
Ongoing.
Feb 22, 2025
b51a8bb
Ongoing.
Feb 22, 2025
f94e0fb
Ongoing.
Feb 22, 2025
7536825
Ongoing.
Feb 23, 2025
f313624
Ongoing.
Feb 23, 2025
dd6056e
Ongoing.
Feb 23, 2025
67a6a19
Ongoing.
Feb 23, 2025
679d037
Ongoing.
Feb 23, 2025
80043ef
Ongoing.
Feb 23, 2025
aff570e
Ongoing.
Feb 23, 2025
6d4eb13
Ongoing.
Feb 23, 2025
c3aa545
Ongoing.
Feb 23, 2025
f5d9bec
Ongoing.
Feb 23, 2025
2c2d595
Ongoing.
Feb 23, 2025
54b0222
Ongoing.
Feb 26, 2025
e023e37
Ongoing.
Feb 26, 2025
4254906
Ongoing.
Feb 27, 2025
20ae9a4
Ongoing.
Feb 27, 2025
9facba7
Ongoing.
Feb 27, 2025
8f0e72c
Ongoing.
Feb 27, 2025
cedf47a
first attempt at single particle injection
LudwigBoess Feb 28, 2025
77dc646
Ongoing.
Feb 28, 2025
afc0fe9
Ongoing.
Feb 28, 2025
c6a01f8
Ongoing.
Feb 28, 2025
4f3d261
Ongoing.
Feb 28, 2025
bec35fd
Ongoing.
Feb 28, 2025
400feb0
Ongoing.
Feb 28, 2025
906d276
Ongoing.
Feb 28, 2025
8bf2718
Ongoing.
Feb 28, 2025
5534983
Ongoing.
Feb 28, 2025
1a60a7a
Ongoing.
Feb 28, 2025
d50abcd
Ongoing.
Feb 28, 2025
fbdfb92
Ongoing.
Feb 28, 2025
b7bed42
cleanup of conductor BCs
LudwigBoess Mar 3, 2025
6249918
add 3D case and set correct boundary cells to zero
LudwigBoess Mar 3, 2025
268f35a
Ongoing
jmahlmann Mar 4, 2025
c4325e7
minor reformatting of conductor BC
haykh Mar 7, 2025
6e66aa2
filters adapted for conducting BCs
haykh Mar 7, 2025
81d51f9
filter test fixed
haykh Mar 8, 2025
8bb8428
removed extra kokkos flags
haykh Mar 9, 2025
b167d37
revert to old pgen for testing
LudwigBoess Mar 8, 2025
ec88a4f
enforce B0/E0 at boundary
LudwigBoess Mar 8, 2025
680b950
revert to zero at boundary
LudwigBoess Mar 10, 2025
de24703
cleanup of pgen
LudwigBoess Mar 13, 2025
a41bbe2
update example parameter file
LudwigBoess Mar 13, 2025
5d9fe73
revert to cleaner injector for shocktest
LudwigBoess Mar 19, 2025
6d43018
implemented new `arch::Piston` spatial distribution to set up shock p…
LudwigBoess Mar 20, 2025
4f5b1d8
fix inconsistency in return type
LudwigBoess Mar 20, 2025
3e9c4ac
Added `MovingInjector` (wip)
LudwigBoess Mar 21, 2025
e724b50
Added `CustomPostStep` for shock pgen to continually inject particles…
LudwigBoess Mar 21, 2025
236060b
bugfix
LudwigBoess Mar 22, 2025
2391bee
added start time of injection and explicitly enforce injection region…
LudwigBoess Mar 22, 2025
d67f6c7
small bugfix
LudwigBoess Mar 22, 2025
bb8e308
shock pgen changed
haykh Mar 24, 2025
31ef100
reduce resolution for faster test
LudwigBoess Mar 24, 2025
b324687
cleanup and bugfix
LudwigBoess Mar 24, 2025
2d1a454
removed unnecessary parameter
LudwigBoess Mar 24, 2025
b3ee77b
applied formatting to `MovingInjector`
LudwigBoess Mar 24, 2025
8d61ce8
first attempt at moving-window injection
LudwigBoess Mar 31, 2025
b2c738a
extended field reset box to the right to squash waves propagating int…
LudwigBoess Apr 1, 2025
fb16928
bugfix: added check to truncate the injection box at the end of the d…
LudwigBoess Apr 1, 2025
884a157
fix unit conversion bug in field reset
LudwigBoess Apr 2, 2025
3f4c565
conductor in all directions
haykh Apr 4, 2025
6ae91c9
minor formatting
haykh Apr 4, 2025
a31c9c7
rm TODOs
haykh Apr 4, 2025
58a6214
conductor filters in full 3D
haykh Apr 4, 2025
0303acf
rebase to 1.2.0rc
haykh Apr 4, 2025
0bee5ca
rebase to 1.2.0rc (attempt 2)
haykh Apr 4, 2025
dd8a35b
(RUNTEST)
haykh Apr 4, 2025
cb34e94
mpi tests fixed (RUNTEST)
haykh Apr 4, 2025
0bc510f
added non-mpi cpu test action (RUNTEST)
haykh Apr 4, 2025
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 6 additions & 1 deletion .github/workflows/actions.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,9 +27,14 @@ jobs:
matrix:
device: [cpu, amd-gpu, nvidia-gpu]
precision: [double, single]
mpi: [serial, parallel]
exclude: # my AMD GPU doesn't support fp64 atomics : (
- device: amd-gpu
precision: double
- device: amd-gpu
mpi: parallel
- device: nvidia-gpu
mpi: parallel
runs-on: [self-hosted, "${{ matrix.device }}"]
steps:
- name: Checkout
Expand All @@ -47,7 +52,7 @@ jobs:
fi
elif [ "${{ matrix.device }}" = "amd-gpu" ]; then
FLAGS="-D Kokkos_ENABLE_HIP=ON -D Kokkos_ARCH_AMD_GFX1100=ON"
elif [ "${{ matrix.device }}" = "cpu" ]; then
elif [ "${{ matrix.mpi }}" = "parallel" ]; then
FLAGS="-D mpi=ON"
fi
cmake -B build -D TESTS=ON -D output=ON -D precision=${{ matrix.precision }} $FLAGS
Expand Down
4 changes: 4 additions & 0 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -24,10 +24,14 @@ Our [detailed documentation](https://entity-toolkit.github.io/) includes everyth

## Contributors (alphabetical)

🎸 __Ludwig Böss__ {[@LudwigBoess](https://github.com/LudwigBoess): PIC, framework}

👀 __Yangyang Cai__ {[@StaticObserver](https://github.com/StaticObserver): GRPIC}

🍵 __Benjamin Crinquand__ {[@bcrinquand](https://github.com/bcrinquand): GRPIC, cubed-sphere}

🚂 __Evgeny Gorbunov__ {[@Alcauchy](https://github.com/Alcauchy): PIC, framework}

:radio: __Siddhant Solanki__ {[@sidruns30](https://github.com/sidruns30): framework}

🤷 __Arno Vanthieghem__ {[@vanthieg](https://github.com/vanthieg): framework, PIC}
Expand Down
9 changes: 0 additions & 9 deletions TASKLIST.md

This file was deleted.

35 changes: 0 additions & 35 deletions cmake/kokkosConfig.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -37,41 +37,6 @@ set(Kokkos_ENABLE_OPENMP
${default_KOKKOS_ENABLE_OPENMP}
CACHE BOOL "Enable OpenMP")

# set memory space
if(${Kokkos_ENABLE_CUDA})
add_compile_definitions(CUDA_ENABLED)
set(ACC_MEM_SPACE Kokkos::CudaSpace)
elseif(${Kokkos_ENABLE_HIP})
add_compile_definitions(HIP_ENABLED)
set(ACC_MEM_SPACE Kokkos::HIPSpace)
else()
set(ACC_MEM_SPACE Kokkos::HostSpace)
endif()

set(HOST_MEM_SPACE Kokkos::HostSpace)

# set execution space
if(${Kokkos_ENABLE_CUDA})
set(ACC_EXE_SPACE Kokkos::Cuda)
elseif(${Kokkos_ENABLE_HIP})
set(ACC_EXE_SPACE Kokkos::HIP)
elseif(${Kokkos_ENABLE_OPENMP})
set(ACC_EXE_SPACE Kokkos::OpenMP)
else()
set(ACC_EXE_SPACE Kokkos::Serial)
endif()

if(${Kokkos_ENABLE_OPENMP})
set(HOST_EXE_SPACE Kokkos::OpenMP)
else()
set(HOST_EXE_SPACE Kokkos::Serial)
endif()

add_compile_options("-D AccelExeSpace=${ACC_EXE_SPACE}")
add_compile_options("-D AccelMemSpace=${ACC_MEM_SPACE}")
add_compile_options("-D HostExeSpace=${HOST_EXE_SPACE}")
add_compile_options("-D HostMemSpace=${HOST_MEM_SPACE}")

if(${BUILD_TESTING} STREQUAL "OFF")
set(Kokkos_ENABLE_TESTS
OFF
Expand Down
4 changes: 2 additions & 2 deletions dev/nix/adios2.nix
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
pkgs ? import <nixpkgs> { },
hdf5 ? false,
mpi ? false,
hdf5,
mpi,
}:

let
Expand Down
17 changes: 8 additions & 9 deletions dev/nix/kokkos.nix
Original file line number Diff line number Diff line change
@@ -1,11 +1,10 @@
{
pkgs ? import <nixpkgs> { },
arch ? "native",
gpu ? "none",
arch,
gpu,
}:

let
gpuUpper = pkgs.lib.toUpper gpu;
name = "kokkos";
version = "4.5.01";
compilerPkgs = {
Expand All @@ -30,35 +29,35 @@ let
};
getArch =
_:
if gpu != "none" && arch == "native" then
if gpu != "NONE" && arch == "NATIVE" then
throw "Please specify an architecture when the GPU support is enabled. Available architectures: https://kokkos.org/kokkos-core-wiki/keywords.html#architectures"
else
pkgs.lib.toUpper arch;
arch;

in
pkgs.stdenv.mkDerivation {
pname = "${name}";
version = "${version}";
src = pkgs.fetchgit {
url = "https://github.com/kokkos/kokkos/";
rev = "v${version}";
rev = "${version}";
sha256 = "sha256-cI2p+6J+8BRV5fXTDxxHTfh6P5PeeLUiF73o5zVysHQ=";
};

nativeBuildInputs = with pkgs; [
cmake
];

propagatedBuildInputs = compilerPkgs.${gpuUpper};
propagatedBuildInputs = compilerPkgs.${gpu};

cmakeFlags = [
"-D CMAKE_CXX_STANDARD=17"
"-D CMAKE_CXX_EXTENSIONS=OFF"
"-D CMAKE_POSITION_INDEPENDENT_CODE=TRUE"
"-D Kokkos_ARCH_${getArch { }}=ON"
(if gpu != "none" then "-D Kokkos_ENABLE_${gpuUpper}=ON" else "")
(if gpu != "none" then "-D Kokkos_ENABLE_${gpu}=ON" else "")
"-D CMAKE_BUILD_TYPE=Release"
] ++ cmakeFlags.${gpuUpper};
] ++ cmakeFlags.${gpu};

enableParallelBuilding = true;
}
66 changes: 56 additions & 10 deletions dev/nix/shell.nix
Original file line number Diff line number Diff line change
@@ -1,15 +1,45 @@
{
pkgs ? import <nixpkgs> { },
gpu ? "NONE",
arch ? "NATIVE",
hdf5 ? true,
mpi ? false,
hdf5 ? false,
gpu ? "none",
arch ? "native",
}:

let
gpuUpper = pkgs.lib.toUpper gpu;
archUpper = pkgs.lib.toUpper arch;
name = "entity-dev";
adios2Pkg = (pkgs.callPackage ./adios2.nix { inherit pkgs mpi hdf5; });
kokkosPkg = (pkgs.callPackage ./kokkos.nix { inherit pkgs arch gpu; });
kokkosPkg = (
pkgs.callPackage ./kokkos.nix {
inherit pkgs;
arch = archUpper;
gpu = gpuUpper;
}
);
envVars = {
compiler = rec {
NONE = {
CXX = "g++";
CC = "gcc";
};
HIP = {
CXX = "hipcc";
CC = "hipcc";
};
CUDA = NONE;
};
kokkos = {
HIP = {
Kokkos_ENABLE_HIP = "ON";
};
CUDA = {
Kokkos_ENABLE_CUDA = "ON";
};
NONE = { };
};
};
in
pkgs.mkShell {
name = "${name}-env";
Expand Down Expand Up @@ -39,11 +69,27 @@ pkgs.mkShell {
pkgs.zlib
]);

shellHook = ''
BLUE='\033[0;34m'
NC='\033[0m'
shellHook =
''
BLUE='\033[0;34m'
NC='\033[0m'

echo "following environment variables are set:"
''
+ pkgs.lib.concatStringsSep "" (
pkgs.lib.mapAttrsToList (
category: vars:
pkgs.lib.concatStringsSep "" (
pkgs.lib.mapAttrsToList (name: value: ''
export ${name}=${value}
echo -e " ''\${BLUE}${name}''\${NC}=${value}"
'') vars.${gpuUpper}
)
) envVars
)
+ ''
echo ""
echo -e "${name} nix-shell activated"
'';

echo ""
echo -e "${name} nix-shell activated"
'';
}
4 changes: 2 additions & 2 deletions input.example.toml
Original file line number Diff line number Diff line change
Expand Up @@ -90,7 +90,7 @@
# Boundary conditions for fields:
# @required
# @type: 1/2/3-size array of string tuples, each of size 1 or 2
# @valid: "PERIODIC", "MATCH", "FIXED", "ATMOSPHERE", "CUSTOM", "HORIZON"
# @valid: "PERIODIC", "MATCH", "FIXED", "ATMOSPHERE", "CUSTOM", "HORIZON", "CONDUCTOR"
# @example: [["CUSTOM", "MATCH"]] (for 2D spherical [[rmin, rmax]])
# @note: When periodic in any of the directions, you should only set one value: [..., ["PERIODIC"], ...]
# @note: In spherical, bondaries in theta/phi are set automatically (only specify bc @ [rmin, rmax]): [["ATMOSPHERE", "MATCH"]]
Expand Down Expand Up @@ -340,7 +340,7 @@
# Field quantities to output:
# @type: array of strings
# @valid: fields: "E", "B", "J", "divE"
# @valid: moments: "Rho", "Charge", "N", "Nppc", "T0i", "Tij"
# @valid: moments: "Rho", "Charge", "N", "Nppc", "T0i", "Tij", "Vi"
# @valid: for GR: "D", "H", "divD", "A"
# @default: []
# @note: For T, you can use unspecified indices, e.g., Tij, T0i, or specific ones, e.g., Ttt, T00, T02, T23
Expand Down
10 changes: 5 additions & 5 deletions legacy/tests/kernels-sr.cpp
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
#include "wrapper.h"

#include <Kokkos_Core.hpp>

#include <iostream>
#include <stdexcept>

#include "wrapper.h"

#include METRIC_HEADER
#include PGEN_HEADER

#include "particle_macros.h"

#include "kernels/particle_pusher_sr.hpp"

#include "particle_macros.h"

template <typename T>
void put_value(ntt::array_t<T*>& arr, T value, int i) {
auto arr_h = Kokkos::create_mirror_view(arr);
Expand Down Expand Up @@ -221,4 +221,4 @@ auto main(int argc, char* argv[]) -> int {
ntt::GlobalFinalize();

return 0;
}
}
Loading