Skip to content
Merged
Show file tree
Hide file tree
Changes from 4 commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion docs/source/installing.rst
Original file line number Diff line number Diff line change
Expand Up @@ -26,7 +26,8 @@ you can simply load the latest NICE module:

.. code-block:: bash

module load NICE

module load NICE/3.0.0-intel-2025b-DD-4.1.1
Comment thread
SBlokhuizen marked this conversation as resolved.
Comment thread
SBlokhuizen marked this conversation as resolved.

If the NICE module is not available, you must compile NICE manually.
See the following page for further details on how to set this up:
Expand Down
13 changes: 7 additions & 6 deletions docs/source/shape_editor_install.rst
Original file line number Diff line number Diff line change
Expand Up @@ -22,7 +22,7 @@ Installing dependencies

.. code-block:: bash

module load IMAS-Python IMAS-AL-Cpp/5.4.0-intel-2023b-DD-4.0.0 \
Comment thread
SBlokhuizen marked this conversation as resolved.
module load IMAS-Python IMAS-AL-Cpp/5.4.0-intel-2023b-DD-4.1.1 \
SuiteSparse/7.7.0-intel-2023b MUSCLE3

.. md-tab-item:: Ubuntu 24.04
Expand All @@ -46,23 +46,23 @@ Installing dependencies

# Install imas_core and muscle3 with pip
pip install 'imas_core @ git+ssh://git@git.iter.org/imas/al-core.git'
pip install 'muscle3==0.8.0'
pip install 'muscle3==0.10.0'
Comment thread
SBlokhuizen marked this conversation as resolved.

# Install AL-CPP in ~/.local
git clone ssh://git@git.iter.org/imas/al-cpp.git
cd al-cpp
cmake -B build -D AL_EXAMPLES=OFF -D AL_HLI_DOCS=OFF -D AL_PLUGINS=OFF \
-D AL_TESTS=OFF -D CMAKE_INSTALL_PREFIX=~/.local \
-D DD_GIT_REPOSITORY=https://github.com/iterorganization/IMAS-Data-Dictionary.git \
-D DD_VERSION=4.0.0
-D DD_VERSION=4.1.1
make -C build -j
make -C build install
cd ..

# Install C++ libs of MUSCLE3 in ~/.local
wget https://github.com/multiscale/muscle3/archive/0.8.0/muscle3-0.8.0.tar.gz
tar xf muscle3-0.8.0.tar.gz
cd muscle3-0.8.0
wget https://github.com/multiscale/muscle3/archive/0.10.0/muscle3-0.10.0.tar.gz
tar xf muscle3-0.10.0.tar.gz
cd muscle3-0.10.0
make
PREFIX=~/.local make install
cd ..
Expand All @@ -85,6 +85,7 @@ https://blfauger.gitlabpages.inria.fr/nice/install.html.

git clone https://gitlab.inria.fr/blfauger/nice.git
cd nice
git checkout v3.0.0
git submodule init
git submodule update
cd src
Expand Down
2 changes: 1 addition & 1 deletion pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -28,7 +28,7 @@ dependencies = [
"ruamel.yaml",
"kaleido", # required for exporting PNG to disk
"asteval",
"muscle3",
"muscle3>=0.10",
]
dynamic = ["version"]

Expand Down
76 changes: 45 additions & 31 deletions waveform_editor/shape_editor/nice_integration.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,51 +20,65 @@

# YMMSL configuration for NICE inverse mode
_muscle3_inv_configuration = """
ymmsl_version: v0.1
Comment thread
SBlokhuizen marked this conversation as resolved.
model:
name: shape_editor
ymmsl_version: v0.2

models:
shape_editor:
components:
shape_editor:
implementation: shape_editor
nice_inv:
implementation: nice_inv
shape_editor:
description: Shape editor
ports:
o_i: [equilibrium_out, pf_active_out, pf_passive_out, wall_out, iron_core_out]
s: [equilibrium_in, pf_active_in]
nice_inv:
description: NICE, inverse mode
ports:
f_init: [equilibrium_in, pf_active_in, pf_passive_in, wall_in, iron_core_in]
o_f: [equilibrium_out, pf_active_out]

conduits:
shape_editor.equilibrium_out: nice_inv.equilibrium_in
shape_editor.pf_passive_out: nice_inv.pf_passive_in
shape_editor.pf_active_out: nice_inv.pf_active_in
shape_editor.iron_core_out: nice_inv.iron_core_in
shape_editor.wall_out: nice_inv.wall_in
nice_inv.equilibrium_out: shape_editor.equilibrium_in
nice_inv.pf_active_out: shape_editor.pf_active_in
shape_editor.equilibrium_out: nice_inv.equilibrium_in
shape_editor.pf_passive_out: nice_inv.pf_passive_in
shape_editor.pf_active_out: nice_inv.pf_active_in
shape_editor.iron_core_out: nice_inv.iron_core_in
shape_editor.wall_out: nice_inv.wall_in
nice_inv.equilibrium_out: shape_editor.equilibrium_in
nice_inv.pf_active_out: shape_editor.pf_active_in

settings:
muscle_profile_level: none # Disable profiling
nice_inv.xml_path: {xml_path}
muscle_profile_level: none # Disable profiling
nice_inv.xml_path: {xml_path}
"""

# YMMSL configuration for NICE direct mode
_muscle3_dir_configuration = """
ymmsl_version: v0.1
model:
name: shape_editor
ymmsl_version: v0.2

models:
shape_editor:
components:
shape_editor:
implementation: shape_editor
nice_dir:
implementation: nice_dir
shape_editor:
description: Shape editor
ports:
o_i: [equilibrium_out, pf_active_out, pf_passive_out, wall_out, iron_core_out]
s: [equilibrium_in]
nice_dir:
description: NICE, direct mode
ports:
f_init: [equilibrium_in, pf_active_in, pf_passive_in, wall_in, iron_core_in]
o_f: [equilibrium_out]

conduits:
shape_editor.equilibrium_out: nice_dir.equilibrium_in
shape_editor.pf_passive_out: nice_dir.pf_passive_in
shape_editor.pf_active_out: nice_dir.pf_active_in
shape_editor.iron_core_out: nice_dir.iron_core_in
shape_editor.wall_out: nice_dir.wall_in
nice_dir.equilibrium_out: shape_editor.equilibrium_in
shape_editor.equilibrium_out: nice_dir.equilibrium_in
shape_editor.pf_passive_out: nice_dir.pf_passive_in
shape_editor.pf_active_out: nice_dir.pf_active_in
shape_editor.iron_core_out: nice_dir.iron_core_in
shape_editor.wall_out: nice_dir.wall_in
nice_dir.equilibrium_out: shape_editor.equilibrium_in

settings:
muscle_profile_level: none # Disable profiling
nice_dir.xml_path: {xml_path}
muscle_profile_level: none # Disable profiling
nice_dir.xml_path: {xml_path}
"""


Expand Down
Loading