-
Notifications
You must be signed in to change notification settings - Fork 3
/
Jenkinsfile
129 lines (115 loc) · 4.28 KB
/
Jenkinsfile
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
pipeline {
triggers { pollSCM('') } // Run tests whenever a new commit is detected.
agent { dockerfile {args '--gpus all'}} // Use the Dockerfile defined in the root Flash-X directory
environment {
// Get rid of Read -1, expected <someNumber>, errno =1 error
// See https://github.com/open-mpi/ompi/issues/4948
OMPI_MCA_btl_vader_single_copy_mechanism = 'none'
}
stages {
//=============================//
// Set up submodules and amrex //
//=============================//
stage('Prerequisites'){ steps{
sh 'mpicc -v'
sh 'nvidia-smi'
sh 'nvcc -V'
sh 'git submodule update --init'
sh 'cp makefiles/GNUmakefile_jenkins Exec/GNUmakefile'
dir('Exec'){
sh 'make generate; make -j'
}
}}
//=======//
// Tests //
//=======//
stage('MSW'){ steps{
dir('Exec'){
sh 'python ../Scripts/initial_conditions/st0_msw_test.py'
sh 'mpirun -np 4 ./main3d.gnu.TPROF.MPI.CUDA.ex ../sample_inputs/inputs_msw_test'
sh 'python ../Scripts/tests/msw_test.py'
sh 'rm -rf plt*'
}
}}
stage('Bipolar'){ steps{
dir('Exec'){
sh 'python ../Scripts/initial_conditions/st1_bipolar_test.py'
sh 'mpirun -np 4 ./main3d.gnu.TPROF.MPI.CUDA.ex ../sample_inputs/inputs_bipolar_test'
sh 'rm -rf plt*'
}
}}
stage('Fast Flavor'){ steps{
dir('Exec'){
sh 'python ../Scripts/initial_conditions/st2_2beam_fast_flavor.py'
sh 'mpirun -np 4 ./main3d.gnu.TPROF.MPI.CUDA.ex ../sample_inputs/inputs_fast_flavor'
sh 'python ../Scripts/tests/fast_flavor_test.py'
sh 'rm -rf plt*'
}
}}
stage('Fast Flavor k'){ steps{
dir('Exec'){
sh 'python ../Scripts/initial_conditions/st3_2beam_fast_flavor_nonzerok.py'
sh 'mpirun -np 4 ./main3d.gnu.TPROF.MPI.CUDA.ex ../sample_inputs/inputs_fast_flavor_nonzerok'
sh 'python ../Scripts/tests/fast_flavor_k_test.py'
sh 'rm -rf plt*'
}
}}
stage('Fiducial 2F GPU Binary'){ steps{
dir('Exec'){
sh 'python ../Scripts/initial_conditions/st4_linear_moment_ffi.py'
sh 'mpirun -np 4 ./main3d.gnu.TPROF.MPI.CUDA.ex ../sample_inputs/inputs_1d_fiducial'
sh 'python ../Scripts/data_reduction/reduce_data_fft.py'
sh 'python ../Scripts/data_reduction/reduce_data.py'
sh 'python ../Scripts/data_reduction/combine_files.py plt _reduced_data.h5'
sh 'python ../Scripts/data_reduction/combine_files.py plt _reduced_data_fft_power.h5'
sh 'python ../Scripts/babysitting/avgfee.py'
sh 'python ../Scripts/babysitting/power_spectrum.py'
sh 'python ../Scripts/data_reduction/convertToHDF5.py'
sh 'gnuplot ../Scripts/babysitting/avgfee_gnuplot.plt'
archiveArtifacts artifacts: '*.pdf'
sh 'rm -rf plt*'
}
}}
stage('Fiducial 3F CPU HDF5'){ steps{
dir('Exec'){
sh 'cp ../makefiles/GNUmakefile_jenkins_HDF5 GNUmakefile'
sh 'make realclean; make generate; make -j'
sh 'python ../Scripts/initial_conditions/st4_linear_moment_ffi_3F.py'
sh 'mpirun -np 4 ./main3d.gnu.TPROF.MPI.ex ../sample_inputs/inputs_1d_fiducial'
sh 'python3 ../Scripts/babysitting/avgfee_HDF5.py'
sh 'rm -rf plt*'
}
}}
stage('Collisions flavor instability'){ steps{
dir('Exec'){
sh 'cp ../makefiles/GNUmakefile_jenkins GNUmakefile'
sh 'make realclean; make generate NUM_FLAVORS=2; make -j NUM_FLAVORS=2'
sh 'python ../Scripts/initial_conditions/st8_coll_inst_test.py'
sh 'mpirun -np 4 ./main3d.gnu.TPROF.MPI.CUDA.ex ../sample_inputs/inputs_coll_equi_test'
sh 'python ../Scripts/data_reduction/reduce_data.py'
sh 'python ../Scripts/tests/coll_equi_test.py'
sh 'rm -rf plt*'
}
}}
stage('Collisions to equilibrium'){ steps{
dir('Exec'){
sh 'cp ../makefiles/GNUmakefile_jenkins GNUmakefile'
sh 'make realclean; make generate NUM_FLAVORS=3; make -j NUM_FLAVORS=3'
sh 'python ../Scripts/initial_conditions/st7_empty_particles.py'
sh 'mpirun -np 4 ./main3d.gnu.TPROF.MPI.CUDA.ex ../sample_inputs/inputs_coll_equi_test'
sh 'python ../Scripts/tests/coll_equi_test.py'
sh 'rm -rf plt*'
}
}}
} // stages{
post {
always {
cleanWs(
cleanWhenNotBuilt: true,
deleteDirs: true,
disableDeferredWipeout: false,
notFailBuild: true,
patterns: [[pattern: 'submodules', type: 'EXCLUDE']] ) // allow submodules to be cached
}
}
} // pipeline{