Skip to content
GitLab
Explore
Sign in
Primary navigation
Search or go to…
Project
lbmpy
Manage
Activity
Members
Labels
Plan
Issues
Issue boards
Milestones
Wiki
Code
Merge requests
Repository
Branches
Commits
Tags
Repository graph
Compare revisions
Snippets
Build
Pipelines
Jobs
Pipeline schedules
Artifacts
Deploy
Releases
Model registry
Operate
Environments
Monitor
Incidents
Analyze
Value stream analytics
Contributor analytics
CI/CD analytics
Repository analytics
Model experiments
Help
Help
Support
GitLab documentation
Compare GitLab plans
Community forum
Contribute to GitLab
Provide feedback
Terms and privacy
Keyboard shortcuts
?
Snippets
Groups
Projects
Show more breadcrumbs
pycodegen
lbmpy
Commits
f07d42b7
Commit
f07d42b7
authored
3 months ago
by
Frederik Hennig
Browse files
Options
Downloads
Patches
Plain Diff
update noxfile and CI
parent
a2a08c23
No related branches found
No related tags found
1 merge request
!172
Changes for compatibility with pystencils 2.0
Pipeline
#77916
canceled
3 months ago
Stage: Code Quality
Stage: Tests
Stage: Prerelease-Tests
Stage: docs
Changes
2
Pipelines
2
Hide whitespace changes
Inline
Side-by-side
Showing
2 changed files
.gitlab-ci.yml
+41
-87
41 additions, 87 deletions
.gitlab-ci.yml
noxfile.py
+20
-1
20 additions, 1 deletion
noxfile.py
with
61 additions
and
88 deletions
.gitlab-ci.yml
+
41
−
87
View file @
f07d42b7
stages
:
-
"
Code
Quality"
-
pret
est
-
t
est
-
prerelease
-
"
T
est
s"
-
"
Prerelease-T
est
s"
-
integration
-
nightly
-
docs
-
deploy
...
...
@@ -25,11 +25,25 @@ stages:
rules
:
-
if
:
$CI_PIPELINE_SOURCE == "schedule"
# -------------------------- Pre Tests --------------------------------------------------------------------------------
# -------------------------- Code Quality --------------------------------------------------------------------------------
# Linter for code formatting
flake8-lint
:
stage
:
"
Code
Quality"
extends
:
.every-commit
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/nox:alpine
script
:
-
nox -s lint
tags
:
-
docker
# -------------------------- Tests --------------------------------------------------------------------------------
# Normal test - runs on every commit all but "long run" tests
testsuite-cuda-py3.10
:
stage
:
pret
est
stage
:
"
T
est
s"
extends
:
.every-commit
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/nox:ubuntu24.04-cuda12.6
needs
:
[]
...
...
@@ -53,21 +67,19 @@ testsuite-cuda-py3.10:
path
:
coverage.xml
junit
:
report.xml
# Test against latest pystencils 2.0 development version
pystencils-2.0dev
:
stage
:
pret
est
testsuite-cpu-py3.13
:
stage
:
"
T
est
s"
extends
:
.every-commit
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/nox:ubuntu24.04-cuda12.6
allow_failure
:
true
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/nox:alpine
needs
:
[]
script
:
-
mkdir -p ~/.config/matplotlib
-
echo "backend:template" > ~/.config/matplotlib/matplotlibrc
-
nox -s "tests
_pystencils2(cupy12)
"
-
nox -s "tests
uite_cpu-3.13
"
tags
:
-
docker
-
AVX
-
cuda11
artifacts
:
when
:
always
paths
:
...
...
@@ -75,9 +87,10 @@ pystencils-2.0dev:
reports
:
junit
:
report.xml
# Normal test with longruns
tests-and-coverage-with-longrun
:
stage
:
t
est
stage
:
"
T
est
s"
when
:
manual
allow_failure
:
true
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/full
...
...
@@ -96,102 +109,43 @@ tests-and-coverage-with-longrun:
-
cuda11
-
AVX
# Linter for code formatting
flake8-lint
:
stage
:
"
Code
Quality"
extends
:
.every-commit
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/nox:alpine
script
:
-
nox -s lint
tags
:
-
docker
# -------------------------- Tests -------------------------------------------------------------------------------------
# -------------------------- Nightly and Pre-Release Tests --------------------------------------------------------------------------------
#
pipeline with latest python
version
latest-python
:
stage
:
t
est
#
Test against latest pystencils 2.0 development
version
pystencils-2.0dev
:
stage
:
"
Prerelease-T
est
s"
extends
:
.every-commit
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/
latest_python
before_script
:
-
pip install git+https://gitlab-ci-token:${CI_JOB_TOKEN}@i10git.cs.fau.de/pycodegen/pystencils.git@master#egg=pystencils
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/
nox:ubuntu24.04-cuda12.6
allow_failure
:
true
needs
:
[]
script
:
-
env
-
pip list
-
export NUM_CORES=$(nproc --all)
-
mkdir -p ~/.config/matplotlib
-
echo "backend:template" > ~/.config/matplotlib/matplotlibrc
-
mkdir public
-
py.test -v -n $NUM_CORES -m "not longrun" --junitxml=report.xml
-
nox -s "testsuite_pystencils2(cupy12)"
tags
:
-
docker
-
AVX
-
cuda11
artifacts
:
when
:
always
paths
:
-
test-report
reports
:
junit
:
report.xml
# Minimal tests in windows environment
#minimal-windows:
# stage: test
# except:
# variables:
# - $ENABLE_NIGHTLY_BUILDS
# tags:
# - win
# script:
# - export NUM_CORES=$(nproc --all)
# - export MPLBACKEND=Agg
# - source /cygdrive/c/Users/build/Miniconda3/Scripts/activate
# - source activate pystencils
# - pip install git+https://gitlab-ci-token:${CI_JOB_TOKEN}@i10git.cs.fau.de/pycodegen/pystencils.git@master#egg=pystencils
# - python -c "import numpy"
# - pip install sympy==1.9
# - py.test -v -m "not (notebook or longrun)"
minimal-sympy-master
:
stage
:
t
est
stage
:
"
Prerelease-T
est
s"
extends
:
.every-commit
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/minimal_conda
before_script
:
-
pip install -e .
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/nox:alpine
script
:
-
pip install git+https://gitlab-ci-token:${CI_JOB_TOKEN}@i10git.cs.fau.de/pycodegen/pystencils.git@master#egg=pystencils
-
python -m pip install --upgrade git+https://github.com/sympy/sympy.git
-
pip list
-
python quicktest.py
-
nox -s quicktest -- --sympy-master
allow_failure
:
true
tags
:
-
docker
-
cuda
ubuntu
:
stage
:
test
extends
:
.every-commit
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/ubuntu
before_script
:
# - apt-get -y remove python3-sympy
-
ln -s /usr/include/locale.h /usr/include/xlocale.h
# - pip3 install `grep -Eo 'sympy[>=]+[0-9\.]+' setup.py | sed 's/>/=/g'`
-
pip3 install git+https://gitlab-ci-token:${CI_JOB_TOKEN}@i10git.cs.fau.de/pycodegen/pystencils.git@master#egg=pystencils
script
:
-
export NUM_CORES=$(nproc --all)
-
mkdir -p ~/.config/matplotlib
-
echo "backend:template" > ~/.config/matplotlib/matplotlibrc
-
env
-
pip3 list
-
pytest -v -n $NUM_CORES -m "not longrun" --junitxml=report.xml
tags
:
-
docker
-
cuda11
artifacts
:
when
:
always
reports
:
junit
:
report.xml
pycodegen-integration
:
image
:
i10git.cs.fau.de:5005/pycodegen/pycodegen/full
stage
:
test
stage
:
integration
when
:
manual
allow_failure
:
true
script
:
...
...
This diff is collapsed.
Click to expand it.
noxfile.py
+
20
−
1
View file @
f07d42b7
from
__future__
import
annotations
from
typing
import
Sequence
from
argparse
import
ArgumentParser
import
os
import
nox
...
...
@@ -74,6 +75,9 @@ def install_pystencils_master(session: nox.Session):
session
.
install
(
"
git+https://i10git.cs.fau.de/pycodegen/pystencils.git@master
"
)
def
install_sympy_master
(
session
:
nox
.
Session
):
session
.
install
(
"
git+https://i10git.cs.fau.de/pycodegen/pystencils.git@master
"
)
@nox.session
(
python
=
"
3.10
"
,
tags
=
[
"
qa
"
,
"
code-quality
"
])
def
lint
(
session
:
nox
.
Session
):
"""
Lint code using flake8
"""
...
...
@@ -128,7 +132,7 @@ def testsuite_gpu(session: nox.Session, cupy_version: str | None):
@nox.parametrize
(
"
cupy_version
"
,
[
None
,
"
12
"
,
"
13
"
],
ids
=
[
"
cpu
"
,
"
cupy12
"
,
"
cupy13
"
])
@nox.session
(
python
=
"
3.10
"
,
tags
=
[
"
test
"
])
def
tests_pystencils2
(
session
:
nox
.
Session
,
cupy_version
:
str
|
None
):
def
tests
uite
_pystencils2
(
session
:
nox
.
Session
,
cupy_version
:
str
|
None
):
if
cupy_version
is
not
None
:
install_cupy
(
session
,
cupy_version
,
skip_if_no_cuda
=
True
)
...
...
@@ -136,3 +140,18 @@ def tests_pystencils2(session: nox.Session, cupy_version: str | None):
editable_install
(
session
,
[
"
alltrafos
"
,
"
use_cython
"
,
"
interactive
"
,
"
tests
"
])
run_testsuite
(
session
)
@nox.session
def
quicktest
(
session
:
nox
.
Session
):
parser
=
ArgumentParser
()
parser
.
add_argument
(
"
--sympy-master
"
,
action
=
"
store_true
"
,
help
=
"
Use latest SymPy master revision
"
)
args
=
parser
.
parse_args
(
session
.
posargs
)
install_pystencils_master
(
session
)
editable_install
(
session
)
if
args
.
sympy_master
:
install_sympy_master
(
session
)
session
.
run
(
"
python
"
,
"
quicktest.py
"
)
This diff is collapsed.
Click to expand it.
Preview
0%
Loading
Try again
or
attach a new file
.
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Save comment
Cancel
Please
register
or
sign in
to comment