DAMASK_EICMD/.gitlab-ci.yml

239 lines
8.1 KiB
YAML
Raw Normal View History

2017-05-17 13:45:30 +05:30
---
2017-04-12 16:46:27 +05:30
stages:
2021-03-26 21:45:56 +05:30
- prepare
- python
- compile
2021-03-26 17:54:11 +05:30
- fortran
2017-05-09 03:22:07 +05:30
- performance
2021-03-26 21:45:56 +05:30
- deploy
- finalize
2017-04-12 16:46:27 +05:30
###################################################################################################
default:
before_script:
- ${LOCAL_HOME}/bin/queue ${CI_JOB_ID}
- source env/DAMASK.sh
- export PATH=${TESTROOT}/bin:${PATH}
- echo Job start:" $(date)"
after_script:
- echo Job end:" $(date)"
2017-04-12 16:46:27 +05:30
###################################################################################################
variables:
2017-05-17 13:45:30 +05:30
# ===============================================================================================
2017-04-12 16:46:27 +05:30
# GitLab Settings
2017-05-17 13:45:30 +05:30
# ===============================================================================================
2021-11-13 18:33:06 +05:30
GIT_SUBMODULE_STRATEGY: normal
2017-04-12 16:46:27 +05:30
2017-05-17 13:45:30 +05:30
# ===============================================================================================
2017-04-12 16:46:27 +05:30
# Shortcut names
2017-05-17 13:45:30 +05:30
# ===============================================================================================
2021-11-13 23:51:23 +05:30
TESTROOT: "$LOCAL_HOME/GitLabCI_Pipeline_$CI_PIPELINE_ID"
2017-04-12 16:46:27 +05:30
2017-05-17 13:45:30 +05:30
# ===============================================================================================
2017-04-12 16:46:27 +05:30
# Names of module files to load
2017-05-17 13:45:30 +05:30
# ===============================================================================================
2019-03-09 22:00:29 +05:30
# ++++++++++++ Compiler +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
COMPILER_GNU: "Compiler/GNU/10"
COMPILER_INTELLLVM: "Compiler/oneAPI/2022.0.1 Libraries/IMKL/2022.0.1"
2021-12-25 17:41:45 +05:30
COMPILER_INTEL: "Compiler/Intel/2022.0.1 Libraries/IMKL/2022.0.1"
2019-03-09 22:00:29 +05:30
# ++++++++++++ MPI ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
MPI_GNU: "MPI/GNU/10/OpenMPI/4.1.1"
MPI_INTELLLVM: "MPI/oneAPI/2022.0.1/IntelMPI/2021.5.0"
MPI_INTEL: "MPI/Intel/2022.0.1/IntelMPI/2021.5.0"
2019-03-09 22:00:29 +05:30
# ++++++++++++ PETSc ++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
PETSC_GNU: "Libraries/PETSc/3.16.1/GNU-10-OpenMPI-4.1.1"
PETSC_INTELLLVM: "Libraries/PETSc/3.16.3/oneAPI-2022.0.1-IntelMPI-2021.5.0"
PETSC_INTEL: "Libraries/PETSc/3.16.3/Intel-2022.0.1-IntelMPI-2021.5.0"
# ++++++++++++ MSC Marc +++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++++
2021-12-02 13:20:59 +05:30
MSC: "FEM/MSC/2021.3.1"
IntelMarc: "Compiler/Intel/19.1.2 Libraries/IMKL/2020"
HDF5Marc: "HDF5/1.12.1/Intel-19.1.2"
2017-04-12 16:46:27 +05:30
2017-04-12 16:46:27 +05:30
###################################################################################################
create_testroot:
2021-03-26 21:45:56 +05:30
stage: prepare
2017-05-17 13:45:30 +05:30
before_script:
- ${LOCAL_HOME}/bin/queue ${CI_JOB_ID}
- echo Job start:" $(date)"
2017-04-12 16:46:27 +05:30
script:
- mkdir -p ${TESTROOT}
2017-04-12 16:46:27 +05:30
###################################################################################################
2021-11-01 03:13:06 +05:30
pytest:
stage: python
script:
- cd python
- pytest --basetemp ${TESTROOT}/python -v --cov --cov-report=term
2021-03-28 16:16:26 +05:30
- coverage report --fail-under=90
2021-11-01 03:13:06 +05:30
mypy:
stage: python
script:
- cd python
2021-11-14 00:07:40 +05:30
- mypy damask
2021-11-01 03:13:06 +05:30
###################################################################################################
grid_GNU:
stage: compile
script:
- module load ${COMPILER_GNU} ${MPI_GNU} ${PETSC_GNU}
- cd PRIVATE/testing/pytest
- pytest -k 'compile and grid' --basetemp ${TESTROOT}/compile_grid_GNU
mesh_GNU:
stage: compile
2018-08-20 12:43:20 +05:30
script:
- module load ${COMPILER_GNU} ${MPI_GNU} ${PETSC_GNU}
- cd PRIVATE/testing/pytest
- pytest -k 'compile and mesh' --basetemp ${TESTROOT}/compile_mesh_GNU
2018-08-20 12:43:20 +05:30
grid_GNU-64bit:
2021-12-27 17:11:55 +05:30
stage: compile
script:
- module load Compiler/GNU/10 Libraries/PETSc/3.16.2/64bit
- cd PRIVATE/testing/pytest
- pytest -k 'compile and grid' --basetemp ${TESTROOT}/compile_grid_GNU-64bit
mesh_GNU-64bit:
stage: compile
script:
- module load Compiler/GNU/10 Libraries/PETSc/3.16.2/64bit
- cd PRIVATE/testing/pytest
- pytest -k 'compile and mesh' --basetemp ${TESTROOT}/compile_mesh_GNU-64bit
grid_IntelLLVM:
stage: compile
script:
- module load ${COMPILER_INTELLLVM} ${MPI_INTELLLVM} ${PETSC_INTELLLVM}
- cd PRIVATE/testing/pytest
- pytest -k 'compile and grid' --basetemp ${TESTROOT}/compile_grid_IntelLLVM
mesh_IntelLLVM:
stage: compile
script:
- module load ${COMPILER_INTELLLVM} ${MPI_INTELLLVM} ${PETSC_INTELLLVM}
- cd PRIVATE/testing/pytest
- pytest -k 'compile and mesh' --basetemp ${TESTROOT}/compile_mesh_IntelLLVM
grid_Intel:
stage: compile
2018-08-20 12:43:20 +05:30
script:
- module load ${COMPILER_INTEL} ${MPI_INTEL} ${PETSC_INTEL}
- cd PRIVATE/testing/pytest
- pytest -k 'compile and grid' --basetemp ${TESTROOT}/compile_grid_Intel
mesh_Intel:
stage: compile
script:
- module load ${COMPILER_INTEL} ${MPI_INTEL} ${PETSC_INTEL}
- cd PRIVATE/testing/pytest
- pytest -k 'compile and mesh' --basetemp ${TESTROOT}/compile_mesh_Intel
2018-08-20 12:43:20 +05:30
Marc_Intel:
stage: compile
script:
- module load $IntelMarc $HDF5Marc $MSC
- cd PRIVATE/testing/pytest
- pytest -k 'compile and Marc' --basetemp ${TESTROOT}/compile_Marc
setup_grid:
stage: compile
2017-04-19 14:20:07 +05:30
script:
- module load ${COMPILER_INTEL} ${MPI_INTEL} ${PETSC_INTEL}
- cd $(mktemp -d)
2021-11-13 23:51:23 +05:30
- cmake -DDAMASK_SOLVER=GRID -DCMAKE_INSTALL_PREFIX=${TESTROOT} ${CI_PROJECT_DIR}
- make -j2 all install
setup_mesh:
stage: compile
script:
- module load ${COMPILER_INTEL} ${MPI_INTEL} ${PETSC_INTEL}
- cd $(mktemp -d)
2021-11-13 23:51:23 +05:30
- cmake -DDAMASK_SOLVER=MESH -DCMAKE_INSTALL_PREFIX=${TESTROOT} ${CI_PROJECT_DIR}
- make -j2 all install
2017-05-17 13:45:30 +05:30
setup_Marc:
stage: compile
script:
- module load $IntelMarc $HDF5Marc $MSC
- cd $(mktemp -d)
- cp ${CI_PROJECT_DIR}/examples/Marc/* .
2021-11-15 23:40:37 +05:30
- python3 -c "import damask;damask.solver.Marc().submit_job('r-value','texture',True,'h')"
2021-11-16 02:23:30 +05:30
- mkdir ${TESTROOT}/src
2021-11-16 03:35:44 +05:30
- mv ${CI_PROJECT_DIR}/src/DAMASK_Marc.marc ${TESTROOT}/src
###################################################################################################
2021-11-16 02:23:30 +05:30
open-source:
2021-03-26 17:54:11 +05:30
stage: fortran
2020-09-25 11:45:22 +05:30
script:
- module load ${COMPILER_INTEL} ${MPI_INTEL} ${PETSC_INTEL}
- cd PRIVATE/testing/pytest
2021-11-16 03:35:44 +05:30
- pytest -k 'not compile and not Marc' --basetemp ${TESTROOT}/open-source -v
2021-11-16 02:23:30 +05:30
Marc:
stage: fortran
script:
- cd PRIVATE/testing/pytest
2021-11-16 03:35:44 +05:30
- pytest -k 'not compile and Marc' --damask-root=${TESTROOT} --basetemp ${TESTROOT}/Marc -v
2020-09-25 11:45:22 +05:30
2021-06-22 03:55:27 +05:30
# Needs closer look
# Phenopowerlaw_singleSlip:
# stage: fortran
# script: Phenopowerlaw_singleSlip/test.py
2021-06-22 03:55:27 +05:30
2017-05-09 03:22:07 +05:30
###################################################################################################
grid_runtime:
2017-05-09 03:22:07 +05:30
stage: performance
before_script:
- ${LOCAL_HOME}/bin/queue ${CI_JOB_ID} --blocking
- source env/DAMASK.sh
- echo Job start:" $(date)"
2017-04-12 16:46:27 +05:30
script:
- module load ${COMPILER_INTEL} ${MPI_INTEL} ${PETSC_INTEL}
2021-11-13 23:43:10 +05:30
- cd $(mktemp -d)
2021-11-16 19:11:46 +05:30
- cmake -DOPTIMIZATION=AGGRESSIVE -DDAMASK_SOLVER=GRID -DCMAKE_INSTALL_PREFIX=./ ${CI_PROJECT_DIR}
2021-11-13 23:43:10 +05:30
- make -j2 all install
2021-11-16 19:11:46 +05:30
- export PATH=${PWD}/bin:${PATH}
- cd $(mktemp -d)
- git clone -q git@git.damask.mpie.de:damask/performance.git .
2021-11-16 03:35:44 +05:30
- >
${CI_PROJECT_DIR}/PRIVATE/testing/runtime.py
--input_dir ${CI_PROJECT_DIR}/examples/grid
--output_dir ./
2021-11-16 03:35:44 +05:30
--tag ${CI_COMMIT_SHA}
- if [ ${CI_COMMIT_BRANCH} == development ]; then git commit -am ${CI_PIPELINE_ID}_${CI_COMMIT_SHA}; git push; fi
2017-05-17 13:45:30 +05:30
###################################################################################################
2021-03-26 21:45:56 +05:30
source_distribution:
stage: deploy
script:
- cd $(mktemp -d)
- ${CI_PROJECT_DIR}/PRIVATE/releasing/tar.xz/create.sh ${CI_PROJECT_DIR} ${CI_COMMIT_SHA}
###################################################################################################
update_revision:
stage: finalize
before_script:
- ${LOCAL_HOME}/bin/queue ${CI_JOB_ID}
- echo Job start:" $(date)"
2017-05-09 03:22:07 +05:30
script:
- cd $(mktemp -d)
- git clone -q git@git.damask.mpie.de:damask/DAMASK.git .
- git pull
- export VERSION=$(git describe ${CI_COMMIT_SHA})
- echo ${VERSION} > python/damask/VERSION
- git commit python/damask/VERSION -m "[skip ci] updated version information after successful test of $VERSION"
- if [ ${CI_COMMIT_SHA} == $(git rev-parse HEAD^) ]; then git push origin HEAD:master HEAD:development; fi
2017-05-09 03:22:07 +05:30
only:
- development