Compare commits

..
8 Commits
Author SHA1 Message Date
Theophile Terraz eae1f83a73 remove GL doublons 2023-12-20 14:53:18 +01:00
Theophile Terraz a738bf3679 merge 2023-12-20 14:10:33 +01:00
Theophile Terraz 888002cd10 another purge criterion 2023-10-03 13:13:52 +02:00
Theophile Terraz e1880c6549 work on purge 2023-09-28 17:09:40 +02:00
Theophile Terraz 9f0caaaa69 Merge branch 'master' into mesh 2023-09-27 10:16:02 +02:00
Theophile Terraz fa35d49a42 add purge 2023-07-06 11:33:59 +02:00
Theophile Terraz 4935069864 add a basic st_to_m method 2023-07-05 15:49:30 +02:00
Theophile Terraz 6438d23304 begin interpolation 2023-06-28 15:32:24 +02:00
692 changed files with 13036 additions and 103392 deletions

No files matched your search

-238
View File
@@ -9,8 +9,6 @@
*.class
tmp
mage8
adists
*.tar
*.tar.*
@@ -21,8 +19,6 @@ adists
*.pdf
*.odt
!doc/**/*.pdf
doc/dev/images/auto_*
doc/dev/documentation.*
!doc/dev/*.org
@@ -41,9 +37,6 @@ __old__
*-venv
mage8
adists
### END CUSTOM ###
# Created by https://www.toptal.com/developers/gitignore/api/python
@@ -275,7 +268,6 @@ flycheck_*.el
# End of https://www.toptal.com/developers/gitignore/api/emacs
# Created by https://www.toptal.com/developers/gitignore/api/qt
# Edit at https://www.toptal.com/developers/gitignore?templates=qt
@@ -651,233 +643,3 @@ TSWLatexianTemp*
*.glstex
# End of https://www.toptal.com/developers/gitignore/api/latex
# Created by https://www.toptal.com/developers/gitignore/api/intellij
# Edit at https://www.toptal.com/developers/gitignore?templates=intellij
### Intellij ###
# Covers JetBrains IDEs: IntelliJ, RubyMine, PhpStorm, AppCode, PyCharm, CLion, Android Studio, WebStorm and Rider
# Reference: https://intellij-support.jetbrains.com/hc/en-us/articles/206544839
# User-specific stuff
.idea/**/workspace.xml
.idea/**/tasks.xml
.idea/**/usage.statistics.xml
.idea/**/dictionaries
.idea/**/shelf
# AWS User-specific
.idea/**/aws.xml
# Generated files
.idea/**/contentModel.xml
# Sensitive or high-churn files
.idea/**/dataSources/
.idea/**/dataSources.ids
.idea/**/dataSources.local.xml
.idea/**/sqlDataSources.xml
.idea/**/dynamic.xml
.idea/**/uiDesigner.xml
.idea/**/dbnavigator.xml
# Gradle
.idea/**/gradle.xml
.idea/**/libraries
# Gradle and Maven with auto-import
# When using Gradle or Maven with auto-import, you should exclude module files,
# since they will be recreated, and may cause churn. Uncomment if using
# auto-import.
# .idea/artifacts
# .idea/compiler.xml
# .idea/jarRepositories.xml
# .idea/modules.xml
# .idea/*.iml
# .idea/modules
# *.iml
# *.ipr
# CMake
cmake-build-*/
# Mongo Explorer plugin
.idea/**/mongoSettings.xml
# File-based project format
*.iws
# IntelliJ
out/
# mpeltonen/sbt-idea plugin
.idea_modules/
# JIRA plugin
atlassian-ide-plugin.xml
# Cursive Clojure plugin
.idea/replstate.xml
# SonarLint plugin
.idea/sonarlint/
# Crashlytics plugin (for Android Studio and IntelliJ)
com_crashlytics_export_strings.xml
crashlytics.properties
crashlytics-build.properties
fabric.properties
# Editor-based Rest Client
.idea/httpRequests
# Android studio 3.1+ serialized cache file
.idea/caches/build_file_checksums.ser
### Intellij Patch ###
# Comment Reason: https://github.com/joeblau/gitignore.io/issues/186#issuecomment-215987721
# *.iml
# modules.xml
# .idea/misc.xml
# *.ipr
# Sonarlint plugin
# https://plugins.jetbrains.com/plugin/7973-sonarlint
.idea/**/sonarlint/
# SonarQube Plugin
# https://plugins.jetbrains.com/plugin/7238-sonarqube-community-plugin
.idea/**/sonarIssues.xml
# Markdown Navigator plugin
# https://plugins.jetbrains.com/plugin/7896-markdown-navigator-enhanced
.idea/**/markdown-navigator.xml
.idea/**/markdown-navigator-enh.xml
.idea/**/markdown-navigator/
# Cache file creation bug
# See https://youtrack.jetbrains.com/issue/JBR-2257
.idea/$CACHE_FILE$
# CodeStream plugin
# https://plugins.jetbrains.com/plugin/12206-codestream
.idea/codestream.xml
# Azure Toolkit for IntelliJ plugin
# https://plugins.jetbrains.com/plugin/8053-azure-toolkit-for-intellij
.idea/**/azureSettings.xml
# End of https://www.toptal.com/developers/gitignore/api/intellij
# Created by https://www.toptal.com/developers/gitignore/api/visualstudiocode
# Edit at https://www.toptal.com/developers/gitignore?templates=visualstudiocode
### VisualStudioCode ###
.vscode/*
!.vscode/settings.json
!.vscode/tasks.json
!.vscode/launch.json
!.vscode/extensions.json
!.vscode/*.code-snippets
# Local History for Visual Studio Code
.history/
# Built Visual Studio Code Extensions
*.vsix
### VisualStudioCode Patch ###
# Ignore all local history of files
.history
.ionide
# End of https://www.toptal.com/developers/gitignore/api/visualstudiocode
# Created by https://www.toptal.com/developers/gitignore/api/linux
# Edit at https://www.toptal.com/developers/gitignore?templates=linux
### Linux ###
*~
# temporary files which can be created if a process still has a handle open of a deleted file
.fuse_hidden*
# KDE directory preferences
.directory
# Linux trash folder which might appear on any partition or disk
.Trash-*
# .nfs files are created when an open file is removed but is still being accessed
.nfs*
# End of https://www.toptal.com/developers/gitignore/api/linux
# Created by https://www.toptal.com/developers/gitignore/api/macos
# Edit at https://www.toptal.com/developers/gitignore?templates=macos
### macOS ###
# General
.DS_Store
.AppleDouble
.LSOverride
# Icon must end with two \r
Icon
# Thumbnails
._*
# Files that might appear in the root of a volume
.DocumentRevisions-V100
.fseventsd
.Spotlight-V100
.TemporaryItems
.Trashes
.VolumeIcon.icns
.com.apple.timemachine.donotpresent
# Directories potentially created on remote AFP share
.AppleDB
.AppleDesktop
Network Trash Folder
Temporary Items
.apdisk
### macOS Patch ###
# iCloud generated files
*.icloud
# End of https://www.toptal.com/developers/gitignore/api/macos
# Created by https://www.toptal.com/developers/gitignore/api/windows
# Edit at https://www.toptal.com/developers/gitignore?templates=windows
### Windows ###
# Windows thumbnail cache files
Thumbs.db
Thumbs.db:encryptable
ehthumbs.db
ehthumbs_vista.db
# Dump file
*.stackdump
# Folder config file
[Dd]esktop.ini
# Recycle Bin used on file shares
$RECYCLE.BIN/
# Windows Installer files
*.cab
*.msi
*.msix
*.msm
*.msp
# Windows shortcuts
*.lnk
# End of https://www.toptal.com/developers/gitignore/api/windows
+60 -336
View File
@@ -1,5 +1,5 @@
# .gitlab-ci.yml -- Pamhyr gitlab-ci
# Copyright (C) 2023-2024 INRAE
# Copyright (C) 2023 INRAE
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -20,121 +20,45 @@ stages:
- test
- build
- package
- hash
- antivirus
- release
#############
# DOWNLOADS #
#############
variables:
MAGE_8_VERSION: "permalink/latest"
ADISTS_VERSION: "permalink/latest"
RUBAR_VERSION: "permalink/latest"
dl-mage8-doc:
dl-mage-linux:
stage: downloads
tags:
- linux
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
script:
- mkdir -p doc
- cd doc
- curl -L -o mage8.pdf https://forge.inrae.fr/river-hydraulics/mage/-/releases/$MAGE_8_VERSION/downloads/documents/Mage-8_Documentation.pdf
- curl -L -o mage.tgz https://gitlab.irstea.fr/jean-baptiste.faure/mage/-/releases/v8.3.0/downloads/packages/mage_linux.tgz
- mkdir -p mage-linux
- cd mage-linux
- tar xvf ../mage.tgz
artifacts:
paths:
- doc/mage8.pdf
- mage-linux/mage
- mage-linux/mage_extraire
- mage-linux/mailleurPF
dl-mage8-linux:
dl-mage-windows:
stage: downloads
tags:
- linux
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
script:
- curl -L -o mage8.tgz https://forge.inrae.fr/river-hydraulics/mage/-/releases/$MAGE_8_VERSION/downloads/packages/mage_linux.tgz
- mkdir -p mage8-linux
- cd mage8-linux
- tar xvf ../mage8.tgz
- curl -L -o mage.tgz https://gitlab.irstea.fr/jean-baptiste.faure/mage/-/releases/v8.3.0/downloads/packages/mage_windows.tgz
- mkdir -p mage-windows
- cd mage-windows
- tar xvf ../mage.tgz
artifacts:
paths:
- mage8-linux/mage
dl-mage8-windows:
stage: downloads
tags:
- linux
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
script:
- curl -L -o mage8.tgz https://forge.inrae.fr/river-hydraulics/mage/-/releases/$MAGE_8_VERSION/downloads/packages/mage_windows.tgz
- mkdir -p mage8-windows
- cd mage8-windows
- tar xvf ../mage8.tgz
artifacts:
paths:
- mage8-windows/mage.exe
dl-adists-linux:
stage: downloads
tags:
- linux
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
script:
- mkdir -p adists-linux
- cd adists-linux
- curl -L -o adists https://forge.inrae.fr/river-hydraulics/adists/-/releases/$ADISTS_VERSION/downloads/executables/adists
artifacts:
paths:
- adists-linux/adists
dl-adists-windows:
stage: downloads
tags:
- linux
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
script:
- mkdir -p adists-windows
- cd adists-windows
- curl -L -o adists.exe https://forge.inrae.fr/river-hydraulics/adists/-/releases/$ADISTS_VERSION/downloads/executables/adists_win64.exe
artifacts:
paths:
- adists-windows/adists.exe
dl-rubar-linux:
stage: downloads
tags:
- linux
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
script:
- mkdir -p rubar-linux
- cd rubar-linux
- curl -L -o rubar.tgz https://forge.inrae.fr/river-hydraulics/rubarbe/-/releases/$RUBAR_VERSION/downloads/packages/rubar_linux.tgz
- tar xf rubar.tgz
artifacts:
paths:
- rubar-linux/rubarbe
dl-rubar-windows:
stage: downloads
tags:
- linux
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
script:
- mkdir -p rubar-windows
- cd rubar-windows
- curl -L -o rubar.tgz https://forge.inrae.fr/river-hydraulics/rubarbe/-/releases/$RUBAR_VERSION/downloads/packages/rubar_windows.tgz
- tar xf rubar.tgz
artifacts:
paths:
- rubar-windows/rubarbe.exe
- mage-windows/mage.exe
- mage-windows/mage_extraire.exe
- mage-windows/mailleurPF.exe
#############
# CONFIGURE #
@@ -205,24 +129,7 @@ test-pep8:
# BUILD #
#########
# build-users-doc:
# stage: build
# tags:
# - linux
# needs:
# - job: set-version
# artifacts: true
# script:
# - cd ./doc/users/
# - ./build.sh
# artifacts:
# paths:
# - doc/users/documentation.pdf
# - doc/users/documentation.html
# - doc/users/images/
# allow_failure: true
build-td:
build-users-doc:
stage: build
tags:
- linux
@@ -230,32 +137,13 @@ build-td:
- job: set-version
artifacts: true
script:
- cd ./doc/users/TP_Hydraulique_Hogneau/
- cd ./doc/users/
- ./build.sh
artifacts:
paths:
- doc/users/TP_Hydraulique_Hogneau/step-by-step.pdf
- doc/users/TP_Hydraulique_Hogneau/pas-a-pas.pdf
- doc/users/TP_Hydraulique_Hogneau/Tuto-2-fr.pdf
- doc/users/TP_Hydraulique_Hogneau/data/
allow_failure: true
build-td-2:
stage: build
tags:
- linux
needs:
- job: set-version
artifacts: true
script:
- cd ./doc/users/TP_AdisTS_Vieux_Rhone/
- ./build.sh
artifacts:
paths:
- doc/users/TP_AdisTS_Vieux_Rhone/pas-a-pas.pdf
- doc/users/TP_AdisTS_Vieux_Rhone/data/
- doc/users/TP_AdisTS_Vieux_Rhone/Sujet.pdf
- doc/users/TP_AdisTS_Vieux_Rhone/Vieux_Rhone_TP_AdisTS.pamhyr
- doc/users/documentation.pdf
- doc/users/documentation.html
- doc/users/images/
allow_failure: true
build-developers-doc:
@@ -296,13 +184,7 @@ build-linux:
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
needs:
- job: dl-adists-linux
artifacts: true
- job: dl-rubar-linux
artifacts: true
- job: dl-mage8-linux
artifacts: true
- job: dl-mage8-doc
- job: dl-mage-linux
artifacts: true
- job: set-version
artifacts: true
@@ -310,11 +192,7 @@ build-linux:
artifacts: true
- job: build-developers-doc
artifacts: true
# - job: build-users-doc
# artifacts: true
- job: build-td
artifacts: true
- job: build-td-2
- job: build-users-doc
artifacts: true
script:
- mkdir -p linux
@@ -329,38 +207,28 @@ build-linux:
- pyinstaller -y --paths linux-venv/lib/python3.8/site-packages ../src/pamhyr.py
# Create directory
- mkdir -p pamhyr
- mkdir -p pamhyr/_internal
- mkdir -p pamhyr/pamhyr
- mkdir -p pamhyr/pamhyr/_internal
# Copy Pamhyr info
- cp -v ../VERSION pamhyr/_internal/
- cp -v ../AUTHORS pamhyr/_internal/
- cp -v ../LICENSE pamhyr/_internal/
- cp -v ../src/motd.txt pamhyr/_internal/
- cp -v ../VERSION pamhyr/pamhyr/_internal/
- cp -v ../AUTHORS pamhyr/pamhyr/_internal/
- cp -v ../LICENSE pamhyr/pamhyr/_internal/
- cp -v ../src/motd.txt pamhyr/pamhyr/_internal/
# Copy mage
- mkdir -p pamhyr/mage8
- cp -v ../mage8-linux/* pamhyr/mage8/
# Copy adists
- mkdir -p pamhyr/adists
- cp -v ../adists-linux/* pamhyr/adists/
# Copy rubar
- mkdir -p pamhyr/rubar
- cp -v ../rubar-linux/* pamhyr/rubar/
- mkdir -p pamhyr/mage
- cp -v ../mage-linux/* pamhyr/mage/
# Copy Pamhyr
- cp -r dist/pamhyr/* pamhyr/
# Pamhyr script to force x11
- echo '#!/usr/bin/env bash' > pamhyr/pamhyr-x11
- echo "" >> pamhyr/pamhyr-x11
- echo "GDK_BACKEND=x11 ./pamhyr $@" >> pamhyr/pamhyr-x11
- chmod +x pamhyr/pamhyr-x11
- cp -r dist/pamhyr pamhyr/
# Copy Pamhyr resources
- mkdir -p pamhyr/_internal/View
- mkdir -p pamhyr/_internal/View/ui
- mkdir -p pamhyr/_internal/View/ui/Widgets
- cp -r ../src/View/ui/*.ui pamhyr/_internal/View/ui/
- cp -r ../src/View/ui/ressources/ pamhyr/_internal/View/ui
- cp -r ../src/View/ui/Widgets/*.ui pamhyr/_internal/View/ui/Widgets
- mkdir -p pamhyr/pamhyr/_internal/View
- mkdir -p pamhyr/pamhyr/_internal/View/ui
- mkdir -p pamhyr/pamhyr/_internal/View/ui/Widgets
- cp -r ../src/View/ui/*.ui pamhyr/pamhyr/_internal/View/ui/
- cp -r ../src/View/ui/ressources/ pamhyr/pamhyr/_internal/View/ui
- cp -r ../src/View/ui/Widgets/*.ui pamhyr/pamhyr/_internal/View/ui/Widgets
# Copy lang
- mkdir -p pamhyr/_internal/lang
- cp -r ../src/lang/*.qm pamhyr/_internal/lang
- mkdir -p pamhyr/pamhyr/_internal/lang
- cp -r ../src/lang/*.qm pamhyr/pamhyr/_internal/lang
# Copy tests cases
- mkdir -p pamhyr/tests_cases/
- mkdir -p pamhyr/tests_cases/Saar
@@ -369,31 +237,17 @@ build-linux:
- mkdir -p pamhyr/doc/
- mkdir -p pamhyr/doc/images/
- mkdir -p pamhyr/doc/html/
# - cp ../doc/users/documentation.pdf pamhyr/doc/Pamhyr2-users.pdf
# - cp ../doc/users/documentation.html pamhyr/doc/Pamhyr2-users.html
- cp ../doc/mage8.pdf pamhyr/doc/mage8.pdf
- cp ../doc/users/documentation.pdf pamhyr/doc/Pamhyr2-users.pdf
- cp ../doc/users/documentation.html pamhyr/doc/Pamhyr2-users.html
- cp ../doc/dev/documentation.pdf pamhyr/doc/Pamhyr2-dev.pdf
- cp ../doc/dev/documentation.html pamhyr/doc/Pamhyr2-dev.html
#- cp ../doc/users/images/* pamhyr/doc/images
- cp -r ../doc/dev/images/* pamhyr/doc/images
- cp -r ../doc/images/* pamhyr/doc/images
# Copy Tuto
- mkdir -p pamhyr/doc/TP_Hydraulique_Hogneau/
- mkdir -p pamhyr/doc/TP_Hydraulique_Hogneau/data
- cp ../doc/users/TP_Hydraulique_Hogneau/Hogneau_Engees2022.pdf pamhyr/doc/TP_Hydraulique_Hogneau/Hogneau_Engees2022.pdf
- cp ../doc/users/TP_Hydraulique_Hogneau/step-by-step.pdf pamhyr/doc/TP_Hydraulique_Hogneau/Tuto1-en.pdf
- cp ../doc/users/TP_Hydraulique_Hogneau/pas-a-pas.pdf pamhyr/doc/TP_Hydraulique_Hogneau/Tuto1-fr.pdf
- cp ../doc/users/TP_Hydraulique_Hogneau/Tuto-2-fr.pdf pamhyr/doc/TP_Hydraulique_Hogneau/Tuto2-fr.pdf
- cp ../doc/users/TP_Hydraulique_Hogneau/*.pamhyr pamhyr/doc/TP_Hydraulique_Hogneau/
- cp ../doc/users/TP_Hydraulique_Hogneau/data/* pamhyr/doc/TP_Hydraulique_Hogneau/data/
- mkdir -p pamhyr/doc/TP_AdisTS_Vieux_Rhone/
- mkdir -p pamhyr/doc/TP_AdisTS_Vieux_Rhone/data
- cp ../doc/users/TP_AdisTS_Vieux_Rhone/*.pdf pamhyr/doc/TP_AdisTS_Vieux_Rhone/
- cp ../doc/users/TP_AdisTS_Vieux_Rhone/data/* pamhyr/doc/TP_AdisTS_Vieux_Rhone/data/
- cp ../doc/users/TP_AdisTS_Vieux_Rhone/Vieux_Rhone_TP_AdisTS.pamhyr pamhyr/doc/TP_AdisTS_Vieux_Rhone/Vieux_Rhone_TP_AdisTS.pamhyr
# Copy TP charriage
- mkdir -p pamhyr/doc/TP_charriage/
- cp -r ../doc/users/TP_charriage/* pamhyr/doc/TP_charriage
- cp ../doc/dev/images/* pamhyr/doc/images
- cp ../doc/images/* pamhyr/doc/images
# Create running script
- echo "#!/bin/sh" > pamhyr/Pamhyr2
- echo "./pamhyr/pamhyr $@" >> pamhyr/Pamhyr2
- chmod u+x pamhyr/Pamhyr2
artifacts:
paths:
- linux/pamhyr
@@ -405,13 +259,7 @@ build-windows:
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
needs:
- job: dl-mage8-windows
artifacts: true
- job: dl-adists-windows
artifacts: true
- job: dl-rubar-windows
artifacts: true
- job: dl-mage8-doc
- job: dl-mage-windows
artifacts: true
- job: set-version
artifacts: true
@@ -419,22 +267,16 @@ build-windows:
artifacts: true
- job: build-developers-doc
artifacts: true
# - job: build-users-doc
# artifacts: true
- job: build-td
artifacts: true
- job: build-td-2
- job: build-users-doc
artifacts: true
script:
- mkdir windows
- cd windows
# Setup env
- python -m pip install -U pip
- python -m pip install -r ..\requirements.txt
- python -m pip install -U -r ..\requirements.txt
# Run Pyinstaller
# - pyinstaller --noconsole -y ..\src\pamhyr.py
- pyinstaller -i ../src/View/ui/ressources/icon.ico --hide-console hide-early -y ..\src\pamhyr.py
- pyinstaller -y ..\src\pamhyr.py
# Create directory
- mkdir pamhyr
- dir
@@ -504,111 +346,6 @@ windows-package-exe:
- copy ..\packages\pamhyr.nsi pamhyr.nsi
- .\make-windows-exe.bat
########
# HASH #
########
linux-build-hash:
stage: hash
tags:
- release
- linux
needs:
- job: build-linux
artifacts: true
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
script:
- cd linux
- sha256sum -b pamhyr/pamhyr > pamhyr/pamhyr.sha256
artifacts:
paths:
- linux/pamhyr/pamhyr.sha256
windows-build-hash:
stage: hash
tags:
- release
- linux
needs:
- job: build-windows
artifacts: true
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
script:
- cd windows
- sha256sum -b pamhyr/pamhyr.exe > pamhyr/pamhyr.exe.sha256
artifacts:
paths:
- windows/pamhyr/pamhyr.exe.sha256
pkg-hash:
stage: hash
tags:
- release
- linux
needs:
- job: linux-package-tar
artifacts: true
- job: windows-package-zip
artifacts: true
- job: windows-package-exe
artifacts: true
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_TAG
script:
- cd windows
- sha256sum -b pamhyr-windows.exe > pamhyr-windows.exe.sha256
- sha256sum -b pamhyr-windows.zip > pamhyr-windows.zip.sha256
- cd ..
- cd linux
- sha256sum -b pamhyr-gnulinux.tar.xz > pamhyr-gnulinux.tar.xz.sha256
artifacts:
paths:
- windows/pamhyr-windows.exe.sha256
- windows/pamhyr-windows.zip.sha256
- linux/pamhyr-gnulinux.tar.xz.sha256
#############
# ANTIVIRUS #
#############
build-check-clamav:
stage: antivirus
tags:
- release
- linux
needs:
- job: build-linux
artifacts: true
- job: build-windows
artifacts: true
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_BRANCH == 'master' || $CI_COMMIT_TAG
script:
- cd packages
- ./clamav-scan.sh builds
allow_failure: true
pkg-check-clamav:
stage: antivirus
tags:
- release
- linux
needs:
- job: linux-package-tar
artifacts: true
- job: windows-package-zip
artifacts: true
- job: windows-package-exe
artifacts: true
rules:
- if: $CI_COMMIT_BRANCH == 'ci-test' || $CI_COMMIT_TAG
script:
- cd packages
- ./clamav-scan.sh packages
allow_failure: true
###########
# RELEASE #
###########
@@ -625,11 +362,9 @@ tag-release:
artifacts: true
- job: windows-package-exe
artifacts: true
# - job: build-users-doc
# artifacts: true
- job: build-developers-doc
- job: build-users-doc
artifacts: true
- job: pkg-hash
- job: build-developers-doc
artifacts: true
rules:
- if: $CI_COMMIT_TAG
@@ -638,44 +373,33 @@ tag-release:
- linux/pamhyr-gnulinux.tar.xz
- windows/pamhyr-windows.zip
- windows/pamhyr-windows.exe
- linux/pamhyr-gnulinux.tar.xz.sha256
- windows/pamhyr-windows.zip.sha256
- windows/pamhyr-windows.exe.sha256
- doc/dev/documentation.pdf
# - doc/users/documentation.pdf
- doc/users/documentation.pdf
script:
- cd packages
release:
name: '$CI_COMMIT_TAG'
description: '$CI_COMMIT_TAG_MESSAGE'
description: 'Automatic release from tag $CI_COMMIT_TAG'
tag_name: '$CI_COMMIT_TAG'
ref: '$CI_COMMIT_SHA'
assets:
links:
- name: 'GNU/Linux CHECKSUM SHA256 (tar.xz)'
url: '${CI_PROJECT_URL}/-/jobs/${CI_JOB_ID}/artifacts/raw/linux/pamhyr-gnulinux.tar.xz.sha256'
filepath: '/linux/pamhyr-gnulinux.tar.xz.sha256'
link_type: 'package'
- name: 'GNU/Linux (tar.xz)'
url: '${CI_PROJECT_URL}/-/jobs/${CI_JOB_ID}/artifacts/raw/linux/pamhyr-gnulinux.tar.xz'
filepath: '/linux/pamhyr-gnulinux.tar.xz'
link_type: 'package'
- name: 'Windows CHECKSUM SHA256 (exe)'
url: '${CI_PROJECT_URL}/-/jobs/${CI_JOB_ID}/artifacts/raw/windows/pamhyr-windows.exe.sha256'
filepath: '/windows/pamhyr-windows.exe.sha256'
link_type: 'package'
- name: 'Windows (exe)'
url: '${CI_PROJECT_URL}/-/jobs/${CI_JOB_ID}/artifacts/raw/windows/pamhyr-windows.exe'
filepath: '/windows/pamhyr-windows.exe'
link_type: 'package'
- name: 'Windows CHECKSUM SHA256 (zip)'
url: '${CI_PROJECT_URL}/-/jobs/${CI_JOB_ID}/artifacts/raw/windows/pamhyr-windows.zip.sha256'
filepath: '/windows/pamhyr-windows.zip.sha256'
link_type: 'package'
- name: 'Windows (zip)'
url: '${CI_PROJECT_URL}/-/jobs/${CI_JOB_ID}/artifacts/raw/windows/pamhyr-windows.zip'
filepath: '/windows/pamhyr-windows.zip'
link_type: 'package'
- name: 'User documentations (pdf)'
url: '${CI_PROJECT_URL}/-/jobs/${CI_JOB_ID}/artifacts/raw/doc/users/documentation.pdf'
filepath: '/doc/users/documentation.pdf'
link_type: 'other'
- name: 'Dev documentations (pdf)'
url: '${CI_PROJECT_URL}/-/jobs/${CI_JOB_ID}/artifacts/raw/doc/dev/documentation.pdf'
filepath: '/doc/dev/documentation.pdf'
-3
View File
@@ -1,3 +0,0 @@
# Default ignored files
/shelf/
/workspace.xml
-6
View File
@@ -1,6 +0,0 @@
<component name="InspectionProjectProfileManager">
<settings>
<option name="USE_PROJECT_PROFILE" value="false" />
<version value="1.0" />
</settings>
</component>
-7
View File
@@ -1,7 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="Black">
<option name="sdkName" value="Python 3.10 (pamhyr)" />
</component>
<component name="ProjectRootManager" version="2" project-jdk-name="Python 3.10 (pamhyr)" project-jdk-type="Python SDK" />
</project>
-8
View File
@@ -1,8 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="ProjectModuleManager">
<modules>
<module fileurl="file://$PROJECT_DIR$/.idea/pamhyr.iml" filepath="$PROJECT_DIR$/.idea/pamhyr.iml" />
</modules>
</component>
</project>
-14
View File
@@ -1,14 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<module type="PYTHON_MODULE" version="4">
<component name="NewModuleRootManager">
<content url="file://$MODULE_DIR$">
<excludeFolder url="file://$MODULE_DIR$/venv" />
</content>
<orderEntry type="jdk" jdkName="Python 3.10 (pamhyr)" jdkType="Python SDK" />
<orderEntry type="sourceFolder" forTests="false" />
</component>
<component name="PyDocumentationSettings">
<option name="format" value="PLAIN" />
<option name="myDocStringFormat" value="Plain" />
</component>
</module>
Generated
-6
View File
@@ -1,6 +0,0 @@
<?xml version="1.0" encoding="UTF-8"?>
<project version="4">
<component name="VcsDirectoryMappings">
<mapping directory="" vcs="Git" />
</component>
</project>
+2 -2
View File
@@ -1,3 +1,3 @@
Sylvain COULIBALY, INRAE, 2020 - 2022
Théophile TERRAZ, INRAE, 2022 - 2024
Pierre-Antoine ROUBY, INRAE, 2023 - 2024
Théophile TERRAZ, INRAE, 2022 - 2023
Pierre-Antoine ROUBY, INRAE, 2023
+30 -20
View File
@@ -3,38 +3,48 @@
Pamhyr is a free and open source graphical user interface for 1D hydro-sedimentary
modelling of rivers.
![logo](https://gitlab.com/pamhyr/pamhyr2/-/raw/master/src/View/ui/ressources/Pamhyr2_logo.png)
## Features
+ Define a complex river hydraulics network
+ Edit a complex river hydraulics network
+ Define the river geometry
+ Define boundary conditions
+ Define lateral contribution
+ Define river friction
+ Define reservoirs
+ Define hydraulic structures
+ Define or generate initial conditions
+ Define river sedimentary layers
+ Edit river friction
+ Generate initial conditions
+ Edit river sedimentary layers
+ Save the study in a unique file
+ Run Mage 8 on a study and visualize results
Let see the
[documentation](https://gitlab.com/pamhyr/pamhyr2/-/wikis/home)
([:fr:](https://gitlab.com/pamhyr/pamhyr2/-/wikis/home-fr),
[:gb:](https://gitlab.com/pamhyr/pamhyr2/-/wikis/home-en))
for more details.
## Install
### GNU/Linux
See documentation:
- [French :fr:](https://gitlab.com/pamhyr/pamhyr2/-/wikis/home/fr/Install%20on%20GNULinux)
- [English :gb:](https://gitlab.com/pamhyr/pamhyr2/-/wikis/home/en/Install%20on%20GNULinux)
Downloads [last
realease](https://gitlab.irstea.fr/theophile.terraz/pamhyr/-/releases/permalink/latest)
GNU/Linux binary archive.
```shell
tar xf pamhyr-gnulinux-amd64.tar.xz
cd pamhyr
./pamhyr
```
### Windows
See documentation:
- [French :fr:](https://gitlab.com/pamhyr/pamhyr2/-/wikis/home/fr/Install%20on%20Windows)
- [English :gb:](https://gitlab.com/pamhyr/pamhyr2/-/wikis/home/en/Install%20on%20Windows)
Downloads [last
realease](https://gitlab.irstea.fr/theophile.terraz/pamhyr/-/releases/permalink/latest)
Windows installer.
### From source code
```shell
# Get source code
git clone https://gitlab.irstea.fr/theophile.terraz/pamhyr/
cd pamhyr
# Install dependencies
pip3 install -r requirements.txt
# Run pamhyr
./src/pamhyr.py
```
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
BIN
View File
Binary file not shown.
+91 -177
View File
@@ -1,5 +1,5 @@
# documentation.org -- Pamhyr developers documentation
# Copyright (C) 2023-2024 INRAE
# Copyright (C) 2023 INRAE
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
@@ -28,6 +28,20 @@
#+OPTIONS: toc:t
#+LANGUAGE: UKenglish
#+NAME: attr_wrap
#+HEADER: :var width="\\textwidth"
#+HEADER: :var caption=""
#+HEADER: :var smallcaption=""
#+HEADER: :var name=""
#+HEADER: :var data=""
#+HEADER: :var float="nil"
#+BEGIN_SRC sh :results output :exports none
echo "#+CAPTION[$smallcaption]: $caption"
echo "#+NAME: $name"
echo "#+ATTR_LATEX: :width $width :float $float"
echo "$data"
#+END_SRC
#+BEGIN_abstract
This document is for the use of developers. It describes the project
architecture, the tools available to assist development and
@@ -40,13 +54,13 @@ documentation, translations or code.
* Introduction
{{{pamhyr2}}} is free and open source software (FOSS) graphical user
Pamhyr2 is free and open source software (FOSS) graphical user
interface (GUI) for 1D hydro-sedimentary modelling of rivers developed
in Python (with version 3.8). It use PyQt at version 5 and matplotlib
in version 3.4.1 or later for the user insterface (see
{{{file(/requirements.txt)}}} for details). The architecture of
project code follow the Qt Model/View architecture [fn:qt-arch] (see
details in section [[Architecture]]). {{{pamhyr2}}} packages can be build
details in section [[Architecture]]). Pamhyr2 packages can be build
manually (see section [[Building packages]]), but there are automatically
build with the gitlab-ci (see the section [[Setup the CI
environment]]). Documentation files are written with org-mode[fn:org],
@@ -61,7 +75,7 @@ https://doc.qt.io/qt-5/model-view-programming.html (last access
* Architecture
{{{pamhyr2}}}'s architecture is based on Qt Model/View, see Figure
Pamhyr2's architecture is based on Qt Model/View, see Figure
[[graph-architecture]]. It is made up of several different components: the
model (in blue), the graphical components (in red), the
actions/delegates (in green), the commands (in purple), the solvers
@@ -164,7 +178,7 @@ https://doc.qt.io/qt-5/model-view-programming.html
** Model
The model is a set of Python classes. In {{{pamhyr2}}}, this classes must
The model is a set of Python classes. In Pamhyr2, this classes must
respect some constraint. Each model class must inherits
=Model.Tools.SQLSubModel= abstract class, except the =Model.Study=
class who inherits =Model.Tools.SQLModel= (see [[SQL]]).
@@ -355,7 +369,6 @@ of Bar (Listing [[sql-bar]] and [[sql-foo]]).
CREATE TABLE bar (
id INTEGER NOT NULL PRIMARY KEY,
x INTEGER NOT NULL,
y INTEGER NOT NULL,
foo_id INTEGER NOT NULL,
FOREIGN KEY(foo_id) REFERENCES foo(id),
)""")
@@ -442,15 +455,6 @@ of Bar (Listing [[sql-bar]] and [[sql-foo]]).
bar._sql_save(execute, data=data)
#+end_src
Let see the results database scheme for {{{pamhyr2}}} at version v0.0.7 in
Figure [[sql_schema]].
#+NAME: sql_schema
#+ATTR_LATEX: :width 16cm
#+CAPTION: SQLite database scheme at {{{pamhyr2}}} version v0.0.7 (generate with [[https://gitlab.com/Screwtapello/sqlite-schema-diagram]])
[[./images/schema_v0.0.7.png]]
[fn:sqlite] The SQLite web site: https://www.sqlite.org/index.html
(last access 2023-09-20)
@@ -472,7 +476,7 @@ PamhyrModelList but use a dictionary instead of list.
** View
{{{pamhyr2}}} use Qt as graphical user interface library with the
Pamhyr2 use Qt as graphical user interface library with the
application "Qt designer" for windows or widget creation (see [[UI file]])
and "Qt linguist" for interface translate (see [[Translate]]). In
addition, we use matplotlib as ploting library (see [[Plot]]).
@@ -487,11 +491,11 @@ componant translate, and possible other files or sub-directories.
*** UI file
We define as possible all {{{pamhyr2}}} windows and custom widgets
with "Qt designer". This application generate UI file who describes
interface organisation with table, layout, button, etc. This method is
faster than hand made windows and widget creation, and saves us some
purely descriptive code. The UI files are saved into =src/View/ui= for
We define as possible all Pamhyr2 windows and custom widgets with "Qt
designer". This application generate UI file who describes interface
organisation with table, layout, button, etc. This method is faster
than hand made windows and widget creation, and saves us some purely
descriptive code. The UI files are saved into =src/View/ui= for
window, and =/src/View/ui/Widgets= for custom widget.
*** Translate
@@ -519,11 +523,10 @@ window, and =/src/View/ui/Widgets= for custom widget.
*** Window
The abstract class =PamhyrWindow= and =PamhyrDialog= are used for most
of {{{pamhyr2}}} window. These class allow to create an window for
{{{pamhyr2}}} GUI and implemente some useful methods. The super class
method difine some generic value from optional parameters, for
examples:
The abstract class PamhyrWindow and PamhyrDialog are used for most of
Pamhyr2 window. These class allow to create an window for Pamhyr2 GUI
and implemente some useful methods. The super class method difine some
generic value from optional parameters, for examples:
- =self._study=: The study giving in constructor parameters =study=
(typically a =Model.Study= class object)
- =self._config=: The configuration giving in constructor parameters
@@ -533,7 +536,7 @@ examples:
object)
#+NAME: window
#+CAPTION: Example of {{{pamhyr2}}} window
#+CAPTION: Example of Pamhyr2 window
#+begin_src python :python python3 :results output :noweb yes
from View.Tools.PamhyrWindow import PamhyrWindow
from View.My.Translate import MyTranslate
@@ -543,8 +546,8 @@ examples:
_pamhyr_ui = "MyUI"
_pamhyr_name = "My window"
def __init__(self, study=None, config=None,
my_data=None,
def __init__(self, my_data=None,
study=None, config=None,
parent=None):
self._my_data = my_data
@@ -580,7 +583,7 @@ window componants or connections.
*** Table
An abstract class =PamhyrTableModel= is available to define a simple
An abstract class PamhyrTableModel is available to define a simple
QAbstractTableModel shortly. In simple cases, there are only =data=
and =setData= methode to implement, but the constructor needs more
information than a classic QAbstractTableModel class.
@@ -633,7 +636,7 @@ class AddNodeCommand(QUndoCommand):
self._node = node
def undo(self):
self._graph.remove_node(self._node)
self._graph.remove_node(self._node.name)
def redo(self):
self._graph.insert_node(self._node)
@@ -641,7 +644,7 @@ class AddNodeCommand(QUndoCommand):
All undo command must be push into a =QUndoStack= (see Listing
[[undo-cmd-push]]) to perform the action and allow user undo and redo this
action. In =PamhyrWindow= (and =PamhyrDialog=) the undo stack is
action. In PamhyrWindow (and PamhyrDialog) the undo stack is
automatically create if the option ="undo"= is activate at window
creation, this stack is accessible at =self._undo_stack=.
@@ -658,13 +661,11 @@ creation, this stack is accessible at =self._undo_stack=.
*** Plot
To define a new plot you can create a class who inherit to
=PamhyrPlot=. The creator need at leaste five argument:
To define a new plot you can create a class who inherit to APlot. The
creator need threee argument:
- A =canvas= of type =MplCanvas=
- A (optional) =trad= of type =PamhyrTranslate=
- A =data= used in =draw= and =update= to create and update the plot
- A optional =toolbar= of type =PamhyrToolbar=
- A =parent= window
This class must implement two method =draw= and =update=, the first
method to draw the plot from scratch, the second to update the plot if
data has changed.
@@ -672,42 +673,25 @@ data has changed.
#+begin_src python :python python3 :results output :noweb yes
from View.Tools.PamhyrPlot import PamhyrPlot
class MyPlot(PamhyrPlot):
def __init__(self, canvas=None, trad=None, toolbar=None
data=None, parent=None):
class MyPlot(APlot):
def __init__(self, canvas=None, data=None, toolbar=None):
super(MyPlot, self).__init__(
canvas=canvas,
trad=trad,
data=data,
toolbar=toolbar,
parent=parent
toolbar=toolbar
)
self.label_x = self._trad["x"]
self.label_y = self._trad["y"]
# Optional configuration
self._isometric_axis = False
self._auto_relim_update = True
self._autoscale_update = True
def draw(self):
# Draw function code...
def update(self):
def update(self, ind = None):
# Update function code...
def clear(self):
# Clear plot values...
# ...
#+end_src
** Solver
The {{{pamhyr2}}} architecture allow to define multiple solver. A
solver is define by a:
The Pamhyr2 architecture allow to define multiple solver. A solver is
define by a:
- type
- name
- description,
@@ -723,11 +707,11 @@ different solver type, this solver type implement the code for export
study to solver input format, and read the solver output to study
results. There exists a generic solver with a generic input and output
format, the type could be use to use a solver not implemented in
{{{pamhyr2}}}, but this solver must can read/write input and output
generic format or use external script. There is possible to define
different solver with the same type, for example two differents
version of the same solver. Finaly, with input and output formater is
possible to execute a code on distant computer, for example, over ssh.
Pamhyr2, but this solver must can read/write input and output generic
format or use external script. There is possible to define different
solver with the same type, for example two differents version of the
same solver. Finaly, with input and output formater is possible to
execute a code on distant computer, for example, over ssh.
#+name: graph-multi-solver
#+header: :results drawer
@@ -761,7 +745,7 @@ possible to execute a code on distant computer, for example, over ssh.
style=dashed;
subgraph cluster021 {
label="Solver Classes";
//classSolverM7[label="Mage7", fillcolor=6];
classSolverM7[label="Mage7", fillcolor=6];
classSolverM8[label="Mage8", fillcolor=6];
classSolverR[label="RubarBE", fillcolor=6];
}
@@ -844,8 +828,8 @@ solver and get results:
- (2.1) The solver read the input file(s)
- (2.2) The solver compute results and write it to solver output
file(s)
- (3) {{{pamhyr2}}} create a =Results= object
- (3.1) The {{{pamhyr2}}} solver class read solver output file(s) and
- (3) Pamhyr2 create a Reuslts
- (3.1) The Pamhyr2 solver class read solver output file(s) and
complete Results with readed data
#+name: graph-pipeline
@@ -963,7 +947,7 @@ the temporal order of action is prensented in Figure
}
#+end_src
To implement a Solver in {{{pamhyr2}}}, there exists a abstract class
To implement a Solver in Pamhyr2, there exists a abstract class
=Solver.AbstractSolver=. A class who herits this class, must implement
different methods:
- =export=: Export the study to solver input file(s)
@@ -974,35 +958,27 @@ different methods:
** Unit tests
A very small part of {{{pamhyr2}}} has unit test. This part is limited to the Model.
#+begin_src shell
python3 -m venv test
. test test/bin/activate
pip3 install -U -r ./full-requirements.txt
cd src/
python3 -Walways -m unittest discovert -v -t .
#+end_src
The unit tests is actually not implemented in Pamhyr2, it is a *work
in progress*.
** The debug mode
To activate an deactivate the {{{pamhyr2}}} debug mode you can open
the configuration window and type "Ctrl+G" or run {{{pamhyr2}}} with
command line:
To activate an deactivate the Pamhyr2 debug mode you can open the
configuration window and type "Ctrl+G" or run Pamhyr2 with command
line:
#+begin_src shell
./Pamhyr2 debug
#+end_src
This mode add some log and add two action in main window menu: "About
> Debug" open a window with Python Repl in current Python
environement, and "About > Debug SQLite" who open the application
This mode add some log and add two action in main window menu:
"About/Debug" open a window with Python Repl in current Python
environement, and "About/Debug SQLite" who open the application
SQLiteBrowser (if installed) on current Study to explore the study
data base file.
#+NAME: debug-repl
#+ATTR_LATEX: :width 14cm
#+CAPTION: {{{pamhyr2}}} debug Python REPL
#+ATTR_LATEX: :width 12cm
#+CAPTION: Pamhyr2 debug Python REPL
[[./images/python-debug-repl.png]]
* Build the project
@@ -1015,7 +991,7 @@ to build packages manually.
If you need an hand made package, you can script available in
{{{file(packages)}}} directory.
*** GNU/Linux {{{linux}}}
*** GNU/Linux
On GNU/Linux building GNU/Linux packages is easy, you just need python
in version 3.8 must be installed with venv and pyinstaller packages
@@ -1037,7 +1013,7 @@ cd packages
./linux.sh
#+end_src
*** Windows {{{windows}}}
*** Windows
To make the Windows packages you have two choice: If you use Windows
you can use the script {{{file(packages/windows.bat)}}}, other else
@@ -1052,10 +1028,10 @@ winetricks installed.
** Setup the CI environment
{{{pamhyr2}}} need a Linux ci-runner and a Windows ci-runner for building
Pamhyr2 need a Linux ci-runner and a Windows ci-runner for building
package. The windows ci-runner could run on a Wine environement.
*** Linux {{{linux}}}
*** Linux
The Linux ci-runner need some software and dependencies in addtion of
gitlab-ci.
@@ -1065,11 +1041,10 @@ gitlab-ci.
emacs emacs-goodies-el \
texlive-full \
python3.8 python3.8-venv
sudo python3 -m pip install pyinstaller
#+end_src
*** Windows (Wine) {{{windows}}}
*** Windows (Wine)
The ci-runner environment for Wine need at least wine version 8, let
[[https://www.numetopia.fr/comment-installer-wine-sur-ubuntu-ou-linux-mint/][see who to add wine official depot to your linux distribution]].
@@ -1078,77 +1053,18 @@ The ci-runner environment for Wine need at least wine version 8, let
sudo apt install wine-stable winetricks
#+end_src
**** Setup environment
Export Wine environment variable to set wine as 64 bits architecture
and set the correct path for wine environment.
#+begin_src shell
export WINARCH=win64
export WINEPREFIX=$PWD/my-wine-runner-prefix
#+end_src
Setup Wine environment to Windows 10 and install the minimal fonts
with =winetricks=.
#+begin_src shell
winetricks corefonts win10
#+end_src
**** Install dependencies
First install 7zip with help of =winetricks=.
#+begin_src shell
winetricks 7zip
#+end_src
In addition, install in the environment the Windows version of:
- [[https://www.python.org/ftp/python/3.8.10/python-3.8.10-amd64.exe][Python 3.8.10]] (ensure the python path is set and Pip is enable)
- [[https://git-scm.com/downloads][Git]]
- [[https://github.com/PowerShell/PowerShell/releases/download/v7.0.1/PowerShell-7.0.1-win-x64.msi][PowerShell]]
In addition, the environment need windows version of:
- [[https://www.python.org/ftp/python/3.8.10/python-3.8.10-amd64.exe][Python 3.8.10]]
- Git
- PowerShell
- Gitlab-ci
- [[https://freefr.dl.sourceforge.net/project/nsis/NSIS%203/3.08/nsis-3.08-setup.exe][Nsis]]
To run a Windows executable into wine environement, use =wine64= command:
#+begin_src shell
wine64 <the-exe-file>
#+end_src
Now, we can install =pyinstaller= on this windows environment:
#+begin_src shell
wine python -m pip install pyinstaller
#+end_src
Now, we can download [[https://docs.gitlab.com/runner/install/windows.html][Gitlab-ci]] runner for Windows an put it in the
current path.
**** Setup runner
You can configure the runner with command:
#+begin_src shell
wine64 gitlab-runner-windows-amd64.exe register
#+end_src
**** Run the runner
Create a new executable shell script =runner.sh= with following lines:
#+begin_src shell
#! /bin/sh
export WINARCH=win64
export WINEPREFIX=$PWD/my-wine-runner-prefix
wine64 gitlab-runner-windows-amd64.exe run
#+end_src
Now you can run the runner with command =./runner.sh=.
{{{bulb}}} You can run this command into a =screen= terminal, detach
the terminal and disconnect from runner machine to keep runner alive.
* Documentation files
This document and the user documentation are org files. This text file
@@ -1331,23 +1247,23 @@ Some org-mode configuration used in documentations files are define in
* How to contribute?
{{{pamhyr2}}} is free software: you can redistribute it and/or modify
it under the terms of the GNU General Public License[fn:license],
either version 3 of the License, or any later version.
Pamhyr2 is free software: you can redistribute it and/or modify it
under the terms of the GNU General Public License[fn:license], either
version 3 of the License, or any later version.
[fn:license] The GPLv3 web page:
https://www.gnu.org/licenses/gpl-3.0.en.html
** Guidelines
To contribute to {{{pamhyr2}}}, we expect a minimum of respect between
To contribute to Pamhyr2, we expect a minimum of respect between
contributors. We therefore ask you to respect the following rules
regarding communication and contribution content:
+ No gender, racial, religious or social discrimination
+ No insults, personal attacks or potentially offensive remarks
+ {{{pamhyr2}}} is free software, and intended to remain so, so take
care with the licensing of libraries and external content you want
to add to the project
+ Pamhyr2 is free software, and intended to remain so, so take care
with the licensing of libraries and external content you want to add
to the project
+ Humour or hidden easter eggs are welcome if they respect the
previous rules
@@ -1358,12 +1274,11 @@ an issue on the project's gitlab page[fn:p2-gitlab], or you can create
a merge request on the same page with the changes you have made to the
code, translation or documentation.
The {{{pamhyr2}}} copyright is owned by INRAE[fn:inrae], but we keep a
record of each contributors. If you made a modification to
{{{pamhyr2}}} software, please add your name at the end of
{{{file(AUTHORS)}}} file and respect the Listing [[auth-format]]
format. You can update this file information for following
contribution.
The Pamhyr2 copyright is owned by INRAE[fn:inrae], but we keep a
record of each contributors. If you made a modification to pamhyr2
software, please add your name at the end of {{{file(AUTHORS)}}} file
and respect the Listing [[auth-format]] format. You can update this file
information for following contribution.
#+NAME: auth-format
#+CAPTION: =AUTHORS= file format
@@ -1374,17 +1289,16 @@ contribution.
#+CAPTION: Current =AUTHORS= file
#+INCLUDE: "../../AUTHORS" src text
[fn:p2-gitlab] The {{{pamhyr2}}} Gitlab project page:
https://gitlab.com/pamhyr/pamhyr2
[fn:p2-gitlab] The Pamhyr2 Gitlab project page:
https://gitlab.irstea.fr/theophile.terraz/pamhyr
[fn:inrae] The INRAE web site: https://www.inrae.fr/
** Translate
You can improve or add translation for the project. To contribute to
{{{pamhyr2}}} translate, you need to use Qt
Linguist[fn:qt-linguist]. Open Qt-linguist and edit the translation
({{{file(.ts)}}}) file, finally, commit the new version of file and
make a merge request.
Pamhyr2 translate, you need to use Qt Linguist[fn:qt-linguist]. Open
Qt-linguist and edite the translation ({{{file(.ts)}}}) file, finally,
commit the new version of file and make a merge request.
If you want add a new language, edit the script
{{{file(src/lang/create_ts.sh)}}} like Listing [[ts-it]]. Run the script
@@ -1393,7 +1307,7 @@ and open the new file with Qt-linguist, setup target language (Figure
file and make a merge request.
#+NAME: ts-it
#+CAPTION: Example of modified {{{file(src/lang/create_ts.sh)}}} to add italian (it) translate for {{{pamhyr2}}}
#+CAPTION: Example of modified {{{file(src/lang/create_ts.sh)}}} to add italian (it) translate for Pamhyr2
#+begin_src shell
...
LANG="fr it"
@@ -1411,7 +1325,7 @@ https://doc.qt.io/qt-5/qtlinguist-index.html (last access 2023-09-18)
** Code contribution
If you are developper you can improve and/or add features to
{{{pamhyr2}}}. Please, follow the architecture described in section
Pamhyr2. Please, follow the architecture described in section
[[Architecture]] as closely as possible. Keep the code simple, clear and
efficient as possible. The master branch is reserved for the project
maintainer; you can create a new branch or fork the project before the
Binary file not shown.

Before

Width:  |  Height:  |  Size: 51 KiB

After

Width:  |  Height:  |  Size: 74 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 224 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 52 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 25 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 43 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 87 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 21 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 23 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 74 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 29 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 22 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 25 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 110 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 18 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 60 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 114 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 196 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 26 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 38 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 44 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 69 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 49 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 134 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 131 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 42 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 40 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 39 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 107 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 4.6 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 45 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 17 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 20 KiB

Binary file not shown.
@@ -1,487 +0,0 @@
# presentation.org -- Pamhyr
# Copyright (C) 2023 INRAE
#
# This program is free software: you can redistribute it and/or modify
# it under the terms of the GNU General Public License as published by
# the Free Software Foundation, either version 3 of the License, or
# (at your option) any later version.
#
# This program is distributed in the hope that it will be useful,
# but WITHOUT ANY WARRANTY; without even the implied warranty of
# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the
# GNU General Public License for more details.
#
# You should have received a copy of the GNU General Public License
# along with this program. If not, see <https://www.gnu.org/licenses/>.
# -*- coding: utf-8 -*-
#+STARTUP: indent hideblocks content beamer
#+TITLE: SimHydro 2023
#+SUBTITLE: \textbf{Pamhyr2}: a graphical user interface for 1D hydro-sedimentary modelling of rivers
# #+AUTHOR: Pierre-Antoine Rouby
#+LATEX_HEADER: \author[Pierre-Antoine Rouby]{\textbf{Pierre-Antoine Rouby$^{*}$}, Benoît Camenen, Lionel Pénard, Léa Kieffer, Théophile Terraz\\\texttt{<pierre-antoine.rouby@inrae.fr>}^{*}}
#+EMAIL: pierre-antoine.rouby@inrae.fr
#+INSTITUTE: INRAE Lyon-Villerbanne, teams River Hydraulics
#+LATEX_HEADER: \institute{INRAE Lyon-Villerbanne, River Hydraulics team}
#+DATE: 9th November
#+KEYWORDS: g ui, hydraulics, sedimentary, hydro-sedimentary, 1D modelling, freesoftware, foss
#+OPTIONS: H:2 toc:t num:t author:nil
#+LATEX_CLASS: beamer
#+LATEX_CLASS_OPTIONS: [slideopt,A4,showboxes,svgnames,aspectratio=169]
# #+LATEX_CLASS_OPTIONS: [presentation]
#+BEAMER_THEME: default
#+COLUMNS: %45ITEM %10BEAMER_ENV(Env) %10BEAMER_ACT(Act) %4BEAMER_COL(Col)
#+LANGUAGE: fr
#+LATEX_HEADER: \usepackage[frenchb]{babel}
#+BEGIN_SRC emacs-lisp :results silent :exports none
(setq org-latex-pdf-process (list
"latexmk -pdflatex='lualatex -shell-escape -interaction nonstopmode' -pdf -f %f"))
(add-to-list 'org-latex-packages-alist '("" "minted"))
(setq org-latex-listings 'minted)
(setq org-src-fontify-natively t)
(org-add-link-type
"cite" 'ebib
(lambda (path desc format)
(cond
((eq format 'html)
(format "(<cite>%s</cite>)" path))
((eq format 'text)
(format "[%s]" path))
((eq format 'latex)
(if (or (not desc) (equal 0 (search "cite:" desc)))
(format "\\cite{%s}" path)
(format "\\cite[%s][%s]{%s}"
(cadr (split-string desc ";"))
(car (split-string desc ";")) path))))))
#+END_SRC
#+LATEX_HEADER: \setbeamertemplate{footline}[frame number]
#+LATEX_HEADER: \setbeamertemplate{headline}{}
#+LATEX_HEADER: \usepackage{multirow}
#+LATEX_HEADER: \usepackage{fontawesome5}
#+LATEX_HEADER: \usepackage{tcolorbox}
#+LATEX_HEADER: \usepackage{tikz}
#+LATEX_HEADER: \logo{\includegraphics[width=.1\textwidth]{../../../../../src/View/ui/ressources/Logo-INRAE.png}}
#+LATEX_HEADER: \newcommand{\R}[1]{\rotatebox[origin=c]{90}{#1}}
# Beamer colors
#+LATEX_HEADER: \setbeamersize{text margin left=0.5cm,text margin right=0.5cm}
#+LATEX_HEADER: \setbeamerfont{alerted text}{series=\bfseries}
#+LATEX_HEADER: \setbeamerfont{example text}{series=\bfseries}
#+LATEX_HEADER: \definecolor{inrae_1}{RGB}{102,193,191}
#+LATEX_HEADER: \definecolor{inrae_2}{RGB}{0,150,152}
#+LATEX_HEADER: \definecolor{inrae_3}{RGB}{39,86,98}
#+LATEX_HEADER: \setbeamercolor{alerted text}{fg=inrae_1}
#+LATEX_HEADER: \setbeamercolor{structure}{fg=inrae_2}
#+LATEX_HEADER: \setbeamercolor{normal text}{fg=inrae_3}
#+LATEX_HEADER: \setbeamercolor*{author}{fg=inrae_3}
#+LATEX_HEADER: \usepackage[absolute,showboxes,overlay]{textpos}
#+LATEX_HEADER: \TPshowboxesfalse
#+LATEX_HEADER: \textblockorigin{5mm}{0mm}
# Biblio
#+LATEX_HEADER: \usepackage{natbib}
# #+LATEX_HEADER: \bibliographystyle{apalike}
#+LATEX_HEADER: \setbeamertemplate{bibliography item}{}
#+LATEX_HEADER: \renewcommand\bibfont{\scriptsize}
#+LATEX_HEADER: \setbeamertemplate{frametitle continuation}[from second]
#+LATEX_HEADER: \setbeamercolor*{bibliography entry title}{fg=inrae_3}
#+LATEX_HEADER: \setbeamercolor*{bibliography entry author}{fg=inrae_3}
#+LATEX_HEADER: \setbeamercolor*{bibliography entry location}{fg=inrae_3}
#+LATEX_HEADER: \usepackage{bbding}
#+LATEX_HEADER: \usepackage{pdfpages}
# Renew title page
#+LATEX_HEADER: \defbeamertemplate*{title page}{customized}[1][]
#+LATEX_HEADER: {
# #+LATEX_HEADER: {
# #+LATEX_HEADER: \usebeamerfont{date}\usebeamercolor[fg]{date}
# #+LATEX_HEADER: \tikz[overlay,remember picture]
# #+LATEX_HEADER: \node[xshift=-1cm,yshift=-1cm,text width=10cm] at (current page.north east) {
# #+LATEX_HEADER: 7$^{th}$ International Conference\\
# #+LATEX_HEADER: 8TH-10TH November\\
# #+LATEX_HEADER: EDF Lab - CHATOU, FRANCE
# #+LATEX_HEADER: }
# #+LATEX_HEADER: }
#+LATEX_HEADER: {
#+LATEX_HEADER: \usebeamerfont{title}\inserttitle\par
#+LATEX_HEADER: \usebeamerfont{title}\usebeamercolor[fg]{title}
#+LATEX_HEADER: \large New modeling paradigms for water issues?\par
#+LATEX_HEADER: }
#+LATEX_HEADER: \bigskip
#+LATEX_HEADER: \begin{center}
#+LATEX_HEADER: \usebeamerfont{subtitle}\usebeamercolor[fg]{subtitle}
#+LATEX_HEADER: {
#+LATEX_HEADER: \LARGE\insertsubtitle\par
#+LATEX_HEADER: }
#+LATEX_HEADER: \bigskip
#+LATEX_HEADER: \usebeamerfont{author}\usebeamercolor[fg]{author}\insertauthor\par
#+LATEX_HEADER: \bigskip
#+LATEX_HEADER: \usebeamerfont{institute}\usebeamercolor[fg]{institute}\insertinstitute\par
#+LATEX_HEADER: \bigskip
#+LATEX_HEADER: \usebeamerfont{date}\usebeamercolor[fg]{date}\insertdate\par
#+LATEX_HEADER: \usebeamercolor[fg]{titlegraphic}\inserttitlegraphic
#+LATEX_HEADER: \end{center}
#+LATEX_HEADER: }
# #+LATEX_HEADER: \newcommand{\tred}[1]{\textcolor{rouge_inrae}{#1}}
#+TODO: TODO WIP TOREVIEW | DONE
#+MACRO: pamhyr \textsc{PAMHyR}
#+MACRO: pamhyr2 \textsc{Pamhyr2}
#+MACRO: pause \pause
#+MACRO: framebreak \framebreak
#+MACRO: no
# #+MACRO: OK \checkmark
#+MACRO: OK \faIcon{check}
#+MACRO: bf \textbf{$1}
# #+latex: \frame{\tocpage}
* 1D hydro-sedimentary simulation at INRAE
** COMMENT 1D river flow simulation
*** INRAE (Lyon-Villerbanne)
- Mage [fn:: Mage: https://gitlab.irstea.fr/jean-baptiste.faure/mage]
- RubarBE [fn:: RubarBE:
https://gitlab.irstea.fr/theophile.terraz/rubarbe]
*** Other project
- Mascaret [fn:: OpenTeleMac: http://www.opentelemac.org]
- HEC-RAS [fn:: HEC-RAS:
https://www.hec.usace.army.mil/software/hec-ras]
- Mike 11 [fn:: Mike11:
https://www.mikepoweredbydhi.com/products/mike-11]
** {{{pamhyr}}}
#+BEGIN_EXPORT latex
\tikz[overlay,remember picture]
\node[xshift=-4cm,yshift=4cm] at (current page.south east) {
\includegraphics[width=7cm]{../images/PAMHyR.png}
};
#+END_EXPORT
{{{pamhyr}}} developed at INRAE in Java since the end of 90s
*** Features
- Graphical user interface
- Define and edit complexe 1D river models
- Run a solver
- Visualize simulation results
*** Compatibility
- 2 solvers *Mage and RubarBE*
# - Multi-reaches (Only for Mage)
- Multi-platform (Linux / Windows)
** {{{pamhyr}}}
#+BEGIN_EXPORT latex
\tikz[overlay,remember picture]
\node[xshift=-4cm,yshift=4cm] at (current page.south east) {
\includegraphics[width=7cm]{../images/PAMHyR.png}
};
#+END_EXPORT
*** Conception issues
- Monolingual French
- Interface too different for each solver
- Impossible to undo an action
*** Huge technical debts
- Out dated technologies (UML $\to$ Java)
- Unmaintained library
- Unstable development process
Hard to maintain or add features to the interface
(No modification since 2016)
* Presentation of {{{pamhyr2}}}
** {{{Pamhyr2}}} - Needs - General constraints
Create a new version of {{{pamhyr}}} called {{{pamhyr2}}}
{{{pause}}}
*** Constraints for users experience
:PROPERTIES:
:BEAMER_COL: 0.5
:BEAMER_ENV: block
:END:
+ *User friendly*
+ *Multi platform* (at least Linux and Windows)
+ *Multi language* (at least English and French)
+ *Multi solver* (as much as possible, at least Mage and
RubarBE)
+ *Single save file* per study
{{{pause}}}
*** Constraints for developers experience
:PROPERTIES:
:BEAMER_COL: 0.5
:BEAMER_ENV: block
:END:
- *Common used* code library and tools
# - *Modular* and *flexible* code
- *Clear* architecture
- *Free and open sources software* (FOSS)
** {{{Pamhyr2}}} - Needs - Features
# #+BEGIN_EXPORT latex
# \tikz[overlay,remember picture]
# \node[xshift=-5cm,yshift=-2cm] at (current page.north east) {
# \includegraphics[width=6cm]{../images/geometry_saar.png}
# };
# #+END_EXPORT
**** {{{no}}}
:PROPERTIES:
:BEAMER_COL: 0.30
:BEAMER_ENV: block
:END:
- Define and edit data
+ River network
+ Geometry
+ Boundary conditions
+ Friction
+ Initial conditions
+ *Sedimentary layers*
- User meshed geometry
- Run a solver
- Display results
+ Default visualisation
+ *Customized visualisation*
**** {{{no}}}
:PROPERTIES:
:BEAMER_COL: 0.70
:BEAMER_ENV: block
:END:
[[../images/geometry_saar.png]]
** {{{pamhyr2}}} - Technical choices
#+BEGIN_EXPORT latex
\tikz[overlay,remember picture]
\node[xshift=-9.3cm,yshift=-4cm] at (current page.north east) {
\includegraphics[width=6.3cm]{../images/BC.png}
};
#+END_EXPORT
*** Technologies
:PROPERTIES:
:BEAMER_COL: 0.60
:BEAMER_ENV: block
:END:
- *Python*
- *PyQt*
- Qt Designer
- Qt Linguist
- *Matplotlib*
- SQLite (as =*.pamhyr=)
- *GPLv3* license (strong copyleft)
*** Architecture
:PROPERTIES:
:BEAMER_COL: 0.35
:BEAMER_ENV: block
:END:
- Qt Model/View
- Multiple solvers configuration
- *Unified interface*, as much as possible
** {{{pamhyr2}}} - State of the project
#+BEGIN_EXPORT latex
\tikz[overlay,remember picture]
\node[xshift=-4.5cm,yshift=-2.5cm] at (current page.north east) {
\includegraphics[width=8cm]{../images/apply_sedi.png}
};
#+END_EXPORT
*** {{{no}}}
:PROPERTIES:
:BEAMER_COL: 0.40
:BEAMER_ENV: block
:END:
\vspace{-1.5cm}
\begin{center}
\emph{Last version:} \texttt{v0.0.3}
\end{center}
{{{pause}}}
#+latex: \begin{center}
#+latex: \resizebox{0.9\columnwidth}{!}{
# #+caption: Tools by methods
#+name: tab:current-state
#+attr_latex: :align |l|c|
|---------------------------------+-----------------|
| {{{bf(Features)}}} | {{{bf(State)}}} |
|---------------------------------+-----------------|
| Create save and load study | {{{OK}}} |
| *Undo/Redo actions* | {{{OK}}} |
| Edit river network | {{{OK}}} |
| Edit geometry | {{{OK}}} |
| Edit boundary conditions | {{{OK}}} |
| Edit lateral contributions | {{{OK}}} |
| Edit frictions (Stricklers) | {{{OK}}} |
| Edit initial conditions | {{{OK}}} |
| *Edit sedimentary layers* | {{{OK}}} |
| Edit hydraulics structures | |
| Edit suspended sediment | |
| Edit polluant | |
| Use meshing tool | WIP |
| Run a solver | {{{OK}}} |
| Read and display results | {{{OK}}} |
| Customize results visualisation | WIP |
| Generic solver input/output | |
|---------------------------------+-----------------|
#+latex: }
#+latex: \end{center}
{{{pause}}}
*** {{{no}}}
:PROPERTIES:
:BEAMER_COL: 0.60
:BEAMER_ENV: block
:END:
\vspace{2.5cm}
#+latex: \begin{center}
#+latex: \resizebox{0.8\columnwidth}{!}{
# #+caption: Tools by methods
#+name: tab:current-state-solver
#+attr_latex: :align |l|c|c|c|
|----------------------------+----------------+-------------------+--------------------|
| {{{bf(Usage)}}} | {{{bf(Mage)}}} | {{{bf(RubarBE)}}} | {{{bf(Mascaret)}}} |
|----------------------------+----------------+-------------------+--------------------|
| *Hydraulics* (mono reach) | {{{OK}}} | | {{{OK}}} |
| *Hydraulics* (multi reach) | {{{OK}}} | | |
| *Bed load evolution* | {{{OK}}} | | |
|----------------------------+----------------+-------------------+--------------------|
#+latex: }
#+latex: \end{center}
# #+LaTeX: \vspace{0.3cm}
#+latex: \begin{center}
#+latex: \resizebox{0.6\columnwidth}{!}{
# #+caption: Tools by methods
#+name: tab:current-state-package
#+attr_latex: :align |l|c|c|
|--------------------+---------------------+-------------------|
| {{{bf(Packages)}}} | {{{bf(GNU/Linux)}}} | {{{bf(Windows)}}} |
|--------------------+---------------------+-------------------|
| Archive (tar/zip) | {{{OK}}} | {{{OK}}} |
| Installer | | {{{OK}}} |
|--------------------+---------------------+-------------------|
#+latex: }
#+latex: \end{center}
* Future work and perspective
** Future work
#+BEGIN_EXPORT latex
\tikz[overlay,remember picture]
\node[xshift=-4.8cm,yshift=-3.8cm] at (current page.north east) {
\includegraphics[width=8.7cm]{../images/results_hydro.png}
};
#+END_EXPORT
*** Next step
- *Meshing tools integration*
- *Custom results visualisation*
+ Python + matplotlib script
- RubarBE integration
- Hydraulics structures
- Unified graphics theme
*** Open questions
- Generic solver input/output (HDF5? CGNS? SQLite?)
- GNU/Linux packages (Pip? Conda? Guix? Deb?)
** Contribution
#+LaTeX: \begin{center}
\faIcon{gitlab} https://gitlab.com/pamhyr/pamhyr2/
#+LaTeX: \end{center}
*** For users
:PROPERTIES:
:BEAMER_COL: 0.45
:BEAMER_ENV: block
:END:
- Try {{{pamhyr2}}}
- Report bug
- Propose improvement
- Improve translation
- Improve user documentation
- Improve tests cases examples
- /Find better project name/
*** For developers
:PROPERTIES:
:BEAMER_COL: 0.45
:BEAMER_ENV: block
:END:
- Add new solver / features
- Improve sources code
- Improve developers documentation
- Improve unit tests
# * Conclusion
** Thanks for listening
# #+BEGIN_EXPORT latex
# \tikz[overlay,remember picture]
# \node[xshift=-6cm,yshift=-1.5cm,text width=10cm] at (current page.north east) {
# {\small\emph{\alert{Journées de la modélisation 1D hydro-sédimentaire} (in french) -}
# \emph{30 \& 31 janvier 2024, INRAE Villeurbanne - }
# \emph{Information and inscription: }\texttt{<benoit.camenen@inrae.fr>}}
# };
# #+END_EXPORT
#+LaTeX: \begin{center}
\faIcon{gitlab} https://gitlab.com/pamhyr/pamhyr2/
#+LaTeX: \end{center}
#+LaTeX: \begin{center}
/*Journées de la modélisation 1D hydro-sédimentaire*/ (in French)
#+LaTeX: \\
/30 & 31 janvier 2024/, INRAE Villeurbanne
#+LaTeX: \\
Information and registration: =<benoit.camenen@inrae.fr>=
#+LaTeX: \end{center}
- {{{pamhyr2}}} developers:
+ =<pierre-antoine.rouby@inrae.fr>=,
+ =<theophile.terraz@inrae.fr>=
- Mage/RubarBE developer:
+ =<theophile.terraz@inrae.fr>=
# #+LaTeX: \vspace{0.5cm}
# #+LaTeX: \begin{center}
# #+LaTeX: {\Large
# *Thanks for listening*
# #+LaTeX: }
# #+LaTeX: \end{center}
+2 -8
View File
@@ -11,8 +11,7 @@
\usepackage[absolute]{textpos}
\usepackage{titlesec}
\usepackage{amssymb}
\usepackage[minted,xparse,breakable]{tcolorbox}
\usepackage{pmboxdraw}
\usepackage{tcolorbox}
\usepackage{enumitem}
\setlist[enumerate]{itemsep=-0.5em}
@@ -134,7 +133,6 @@
\setminted[c]{fontsize=\footnotesize,encoding=utf8,linenos}
\setminted[c++]{breaklines,fontsize=\footnotesize,encoding=utf8,linenos}
\setminted[python]{breaklines,fontsize=\footnotesize,encoding=utf8,linenos}
\setminted[sql]{breaklines,fontsize=\footnotesize,encoding=utf8,linenos}
\setminted[shell]{breaklines,fontsize=\footnotesize,encoding=utf8}
\setminted[scheme]{breaklines,fontsize=\footnotesize,encoding=utf8}
\setminted[commun-lisp]{breaklines,fontsize=\footnotesize,encoding=utf8}
@@ -142,7 +140,7 @@
\setminted[llvm]{breaklines,fontsize=\footnotesize,encoding=utf8}
%% Add box arrond of minted
\BeforeBeginEnvironment{minted}{\begin{tcolorbox}[breakable, boxsep=0pt, left=0.1cm, right=0.1cm, arc=0pt, boxrule=0.5pt, colback=white]}%
\BeforeBeginEnvironment{minted}{\begin{tcolorbox}[boxsep=0pt, left=0.1cm, right=0.1cm, arc=0pt, boxrule=0.5pt, colback=white]}%
\AfterEndEnvironment{minted}{\end{tcolorbox}}%
\makeatletter
@@ -163,7 +161,3 @@
\SetWatermarkScale{3}
\SetWatermarkFontSize{1cm}
\SetWatermarkText{Work in progress}
%% Icons
\usepackage{fontawesome5}
+5 -19
View File
@@ -17,15 +17,11 @@
# -*- coding: utf-8 -*-
# Constant name
#+MACRO: pamhyr \textsc{PAMHyR}
#+MACRO: pamhyr2 \textsc{Pamhyr2}
#+MACRO: mage \textsc{Mage}
#+MACRO: mage7 \textsc{Mage7}
#+MACRO: mage8 \textsc{Mage8}
#+MACRO: rubarbe \textsc{RubarBE}
#+MACRO: adists \textsc{AdisTS}
#+MACRO: mascaret \textsc{Mascaret}
#+MACRO: inrae INRAE
#+MACRO: oldPamhyr PAMHyR
#+MACRO: Pamhyr Pamhyr2
#+MACRO: Mage Mage
#+MACRO: Rubarbe RubarBE
#+MACRO: Inrae INRAE
#+MACRO: latex \LaTeX
# Information
@@ -39,16 +35,6 @@
#+MACRO: cite [cite:$1]
#+MACRO: biblio \bibliography{documentation}
# Icons
#+MACRO: bulb \faIcon{lightbulb}
#+MACRO: OK \faIcon{check}
#+MACRO: linux \faIcon{linux}
#+MACRO: windows \faIcon{windows}
#+MACRO: python \faIcon{python}
#+MACRO: java \faIcon{java}
# Wrapper
#+NAME: attr_wrap
#+HEADER: :var width="\\textwidth"
@@ -1,68 +0,0 @@
@article{camenen_simple_2007,
title = {Simple and {General} {Formula} for the {Settling} {Velocity} of {Particles}},
volume = {133},
language = {en},
number = {2},
urldate = {2025-01-23},
journal = {Journal of Hydraulic Engineering},
author = {Camenen, Benoit},
month = feb,
year = {2007},
pages = {229-233},
}
@article{meyer-peter_formulas_1948,
address = {Stockholm, Sweden},
title = {Formulas for bed-load transport.},
journal = {Report on Second Meeting of IAHR},
author = {Meyer-Peter, E and Mueller, R},
year = {1948},
pages = {39-64},
}
@article{elder_dispersion_1959,
title = {The dispersion of marked fluid in turbulent shear flow},
volume = {5},
issn = {0022-1120, 1469-7645},
language = {en},
number = {04},
urldate = {2025-01-23},
journal = {Journal of Fluid Mechanics},
author = {Elder, J. W.},
month = may,
year = {1959},
pages = {544},
}
@article{fischer_discussion_1975,
title = {Discussion of Simple Method for Predicting Dispersion in Streams},
volume = {101},
issn = {0090-3914, 2690-2435},
language = {en},
number = {3},
urldate = {2025-01-23},
journal = {Journal of the Environmental Engineering Division},
author = {Fischer, Hugo B},
month = mar,
year = {1975},
pages = {453-455},
}
@article{iwasa_predicting_1991,
address = {Hong Kong},
title = {Predicting longitudinal dispersion coefficient in open channel flows},
journal = {roc. Int. Symp. of Environmental Hydraulics},
author = {Iwasa, Y and Aya, S},
year = {1991},
pages = {505-510},
}
@book{soulsby_dynamics_1997,
address = {London},
edition = {Thomas Telford},
title = {Dynamics of {Marine} {Sands}: {A} {Manual} for {Practical} {Applications}},
urldate = {2025-01-23},
author = {Soulsby, Richard},
year = {1997},
}
-175
View File
@@ -1,175 +0,0 @@
%% LyX 2.0.2 created this file. For more info, see http://www.lyx.org/.
%% Do not edit unless you really know what you are doing.
\documentclass[12pt,french]{article}
\usepackage[T1]{fontenc}
\usepackage[latin9]{inputenc}
\usepackage{geometry}
\geometry{verbose,tmargin=2cm,bmargin=2cm,lmargin=2cm,rmargin=2cm,headheight=2cm,headsep=2cm,footskip=2cm}
\usepackage{textcomp}
\usepackage{graphicx}
\usepackage{hyperref}
\usepackage[frenchb]{babel}
\makeatletter
%%%%%%%%%%%%%%%%%%%%%%%%%%%%%% LyX specific LaTeX commands.
\newcommand{\noun}[1]{\textsc{#1}}
%% Because html converters don't know tabularnewline
\providecommand{\tabularnewline}{\\}
\makeatother
\usepackage{babel}
\addto\extrasfrench{%
\providecommand{\og}{\leavevmode\flqq~}%
\providecommand{\fg}{\ifdim\lastskip>\z@\unskip\fi~\frqq}%
}
\begin{document}
\includegraphics[width=5cm]{img/Logo-INRAE_Transparent.png}
~
~
~
\begin{center}
TP AdisTS - Pamhyr2\\
Version : Janvier 2025
\par\end{center}
~
~
\begin{center}
\textbf{\LARGE Modélisation 1D du transport sédimentaire : } \\
\textbf{\LARGE Cas du Vieux-Rhône de Miribel-Jonage}\\
\textbf{\LARGE (Lyon, France)}
\par\end{center}{\LARGE \par}
~
\begin{center}
\includegraphics[width=17cm]{img/Garde.jpeg}
\par\end{center}
~
\begin{center}
{\large INRAE Lyon-Grenoble Auvergne-Rhône-Alpes}
\par\end{center}{\large \par}
\begin{center}
RiverLy, Hydraulique des rivières
\par\end{center}
~
\begin{center}
\begin{tabular}{lll}
Auteur : & Dorian Hernandez & dorian.hernandez@inrae.fr\tabularnewline
& Théophile Terraz & theophile.terraz@inrae.fr\tabularnewline
\end{tabular}
\par\end{center}
~
\pagebreak{}
\begin{center}
\tableofcontents{}
\par\end{center}
~
\pagebreak{}
% \section{Introduction}
%
% TODO
%
% \pagebreak{}
\section{Contexte de l'étude - le colmatage du Vieux-Rhône}
Le champ de captage de Crépieux-Charmy est un site de pompage d'eau potable alimentant 97 \% de la ville de Lyon. Situé au nord-est de la ville, il est en contact hydraulique avec trois chenaux du Rhône. Le canal de Miribel au Nord, dont les débits varient entre 89 (débit réservé) et 2400 ~$m³/s$ (Crue extrême), le canal de Jonage au sud, imposant un débit quasi constant de 600 ~$m³/s$ pour alimenter la centrale de Cusset, et un Vieux-Rhône qui traverse le site. Les fortes variations hydrauliques le long de Miribel, ainsi que le débit constant le long de Jonage mènent à un dépôt général des sédiments fins et grossiers le long du Vieux-Rhône, avec la création d'un remous important causé par Jonage.
\begin{center}
\includegraphics[width=15cm]{img/Intro.jpeg}
\par\end{center}
Eau du grand Lyon, le gérant du champ de captage, souhaite identifier les zones de dépôts de sédiments fin le long du Vieux-Rhône, cause principale de colmatage, impactant les performances de pompage de l'eau dans les nappes.
\begin{center}
\includegraphics[width=15cm]{img/Champ_captant.jpeg}
\par\end{center}
Pour cela, une campagne expérimentale visant à identifier les zones colmatés du Vieux-Rhône a été réalisée et a mis en avant une hétérogénéité du site. Notamment, une forte zone de dépôts de grossier est présente en amont. Tandis qu'une présence plus importante de fines et sables dans la zone aval (zone de remous de Jonage) a été observée, ainsi qu'un colmatage plus important.
\begin{center}
\includegraphics[width=15cm]{img/Grossier_sable.jpeg}
\par\end{center}
En parallèle, un modèle numérique hydraulique 1D a été élaboré sous Pamhyr2 afin d'analyser l'écoulement sur le site. Les résultats numériques mettent alors bien en avant le remous généré par Jonage, ainsi qu'une diminution de la vitesse de l'écoulement à partir du point kilométrique (PK) 1000, fin de la zone amont.
\begin{center}
\includegraphics[width=15cm]{img/Simu.jpeg}
\par\end{center}
\section{Objectifs de l'étude}
Le modèle numérique 1D représente actuellement la partie hydraulique du système. L'objectif du TP est alors de mettre en donnée la partie sédimentaire (fines) du modèle, afin d'effectuer des calculs à l'aide de AdisTS , et in-fine, identifier les zones de dépôt et d'érosion des sédiments fins le long du Vieux-Rhône selon différents scénarios hydraulique. Les différentes étapes seront alors :
\begin{itemize}
\item Mettre en données le modèle Pamhyr2 du Vieux-Rhône pour le solveur AdisTS.
\item Lancer des calculs Mage - AdisTS pour différents scénarios hydrauliques.
\item Interpréter et discuter les résultats obtenus (comportement hydro-sédimentaire du site, impacts des débits, impact d'une crue, limites du modèle, etc..)
\end{itemize}
\section{Données fournies}
\textbf{Le modèle numérique du Vieux-Rhône}
Fichier \textit{Vieux\_Rhone\_TP\_AdisTS.pamhyr}.\\
\textbf{Les scénarios hydrauliques}
Quatre scénarios hydrauliques sont à analyser (voir les conditions initiales hydraulique) :
\begin{itemize}
\item Le premier correspond à un débit constant de 25~$m³/s$
\item Le deuxième consiste en une faible montée en débit puis à une redescente (25 - 50 - 25~$m³/s)$.
\item Le troisième correspondant à une plus forte montée en débit (25 - 100 - 25~$m³/s)$.
\item Le dernier correspond à une crue (25 - 600 - 25~$m3/s)$.\\
\end{itemize}
\textbf{Propriétés des sédiments}
Nous considérerons 2 classes de sédiments de types sable naturel, correspondant à une classe de Fines (limon) de diamètre moyen 63 microns et une classe de Sable de 500 microns. Les deux classes auront une masse volumique de 2650~$kg/m³$, et une porosité de 0,45 pourra être choisie. Leurs concentrations constantes en amont (conditions aux limites amont) seront de 60 $mg/l$ pour les fines et 30 $mg/l$ pour les sables. Nous considérerons dans un premier temps qu'il n'y a aucun dépôt initial de ces deux classes de sédiments et que la concentration initiale en sédiments dans le bief est nulle.\\
\textbf{Documentation}
\begin{itemize}
\item Un tutoriel guidé de mise en données : Pas-a-pas.pdf.
\item Un guide utilisateur de AdisTS : adis-TS\_usage.pdf
\item Un guide de conception de AdisTS : adis-TS\_conception.pdf
\end{itemize}
\section{Bonus}
Ajouter une épaisseur initiale de sédiments \textit{Sables} au fond de 1 $cm$ et relancer un calcul avec le scénario 1.
\pagebreak{}
\end{document}
-8
View File
@@ -1,8 +0,0 @@
#! /bin/sh
pdflatex -no-shell-escape pas-a-pas.tex
bibtex pas-a-pas.aux
pdflatex -no-shell-escape pas-a-pas.tex
pdflatex -no-shell-escape pas-a-pas.tex
pdflatex -no-shell-escape Sujet.tex
pdflatex -no-shell-escape Sujet.tex
File diff suppressed because it is too large. Load diff
Binary file not shown.

Before

Width:  |  Height:  |  Size: 32 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 30 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 37 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 91 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 27 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 33 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 119 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 114 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 83 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 684 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 109 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 74 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 111 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 109 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 19 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 24 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 160 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 46 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 15 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 108 KiB

Binary file not shown.

Before

Width:  |  Height:  |  Size: 79 KiB

Loaded 100 of 692 files, more files were not shown because too many files have changed in this diff. Show more