Skip to content
Merged
Show file tree
Hide file tree
Changes from all 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
6 changes: 3 additions & 3 deletions .github/workflows/mcstas-basictest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -81,7 +81,7 @@ jobs:
choco install winflexbison3
choco install wget
if [ "$CC" == "gcc.exe" ]; then choco install mingw; fi
pip install mslex PyYAML ply ncrystal mcpl mcpl-extra
pip install mslex PyYAML ply ncrystal mcpl mcpl-extra psutil

- name: Setup (Windows Intel)
id: setup-Windows-intel
Expand Down Expand Up @@ -240,11 +240,11 @@ jobs:
set -x
if [ "$RUNNER_OS" == "macOS" ];
then
python3 -mpip install PyYAML pyaml ply McStasScript ncrystal mcpl mcpl-extra jinja2 --break-system-packages
python3 -mpip install PyYAML pyaml ply McStasScript ncrystal mcpl mcpl-extra jinja2 psutil --break-system-packages
fi
if [ "$RUNNER_OS" == "Linux" ];
then
python3 -mpip install PyYAML ply McStasscript ncrystal mcpl mcpl-extra jinja2
python3 -mpip install PyYAML ply McStasscript ncrystal mcpl mcpl-extra jinja2 psutil
fi

# Start of Unix tests
Expand Down
6 changes: 3 additions & 3 deletions .github/workflows/mcxtrace-basictest.yml
Original file line number Diff line number Diff line change
Expand Up @@ -89,7 +89,7 @@ jobs:
choco install winflexbison3
choco install wget
if [ "$CC" == "gcc.exe" ]; then choco install mingw; fi
pip install mslex PyYAML ply mcpl mcpl-extra
pip install mslex PyYAML ply mcpl mcpl-extra psutil

- name: Setup (Windows Intel)
id: setup-Windows-intel
Expand Down Expand Up @@ -248,11 +248,11 @@ jobs:
set -x
if [ "$RUNNER_OS" == "macOS" ];
then
python3 -mpip install PyYAML pyaml ply McStasScript mcpl mcpl-extra jinja2 --break-system-packages
python3 -mpip install PyYAML pyaml ply McStasScript mcpl mcpl-extra jinja2 psutil --break-system-packages
fi
if [ "$RUNNER_OS" == "Linux" ];
then
python3 -mpip install PyYAML ply McStasscript mcpl mcpl-extra jinja2
python3 -mpip install PyYAML ply McStasscript mcpl mcpl-extra jinja2 psutil
fi

# Start of Unix tests
Expand Down
2 changes: 1 addition & 1 deletion devel/bin/mccode-create-conda-yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,7 +21,7 @@ def create_deplist( cfg ):
return deps

#The rest are run-time deps:
deps += ['python','c-compiler','pyaml','numpy']
deps += ['python','c-compiler','pyaml','numpy','psutil']
if cfg.is_unix:
deps += ['bash']
if cfg.is_win:
Expand Down
1 change: 1 addition & 0 deletions environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ dependencies:
- compilers
- gsl
- pyaml
- psutil
- ply
- matplotlib-base
- numpy
Expand Down
1 change: 1 addition & 0 deletions mcstas-environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ dependencies:
- compilers
- gsl
- pyaml
- psutil
- ply
- matplotlib-base
- numpy
Expand Down
1 change: 1 addition & 0 deletions mcxtrace-environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ dependencies:
- compilers
- gsl
- pyaml
- psutil
- ply
- matplotlib-base
- numpy
Expand Down
1 change: 1 addition & 0 deletions meta-pkgs/windows/environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -15,6 +15,7 @@ dependencies:
- m2w64-gsl
- msmpi
- pyaml
- psutil
- ply
- numpy
- tornado
Expand Down
1 change: 1 addition & 0 deletions meta-pkgs/windows/mcstas-environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ dependencies:
- gsl
- msmpi
- pyaml
- psutil
- ply
- numpy
- tornado
Expand Down
1 change: 1 addition & 0 deletions meta-pkgs/windows/mcxtrace-environment.yml
Original file line number Diff line number Diff line change
Expand Up @@ -14,6 +14,7 @@ dependencies:
- gsl
- msmpi
- pyaml
- psutil
- ply
- numpy
- tornado
Expand Down
2 changes: 1 addition & 1 deletion tools/Python/mcrun/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@ set(CPACK_NSIS_DISPLAY_NAME "${NSIS_NAME}")
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "${NSIS_NAME}")

# Debian
set(CPACK_DEBIAN_PACKAGE_DEPENDS "${FLAVOR}, python3-yaml, python3-numpy")
set(CPACK_DEBIAN_PACKAGE_DEPENDS "${FLAVOR}, python3-yaml, python3-numpy, python3-psutil")
set(CPACK_DEBIAN_PACKAGE_REPLACES "${FLAVOR}-tools-python-${P}run-3.5.1")

# RPM
Expand Down
2 changes: 2 additions & 0 deletions tools/Python/mcrun/mccode.py
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,7 @@
import sys
import re
import shutil
import psutil

if not os.name == 'nt':
import shlex as lexer
Expand Down Expand Up @@ -441,6 +442,7 @@ def runMPI(self, args, pipe=False, override_mpi=None):
LOG.info('Using system default number of mpirun -np processes')
if os.name == 'nt':
mpi_flags = [''] # msmpi mpiexec.exe does not accept --
mpi_flags = ['-np', str(psutil.cpu_count(logical=False))] # probe number of available (non-logical) CPU's
else:
mpi_flags = ['--'] # ... whereas openmpi mpirun does.
elif int(self.options.mpi) >= 1:
Expand Down
2 changes: 1 addition & 1 deletion tools/Python/mctest/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -52,7 +52,7 @@ set(CPACK_NSIS_DISPLAY_NAME "${NSIS_NAME}")
set(CPACK_PACKAGE_DESCRIPTION_SUMMARY "${NSIS_NAME}")

# Debian
set(CPACK_DEBIAN_PACKAGE_DEPENDS "${FLAVOR}, ${FLAVOR}-comps, python3-jinja2")
set(CPACK_DEBIAN_PACKAGE_DEPENDS "${FLAVOR}, ${FLAVOR}-comps, python3-jinja2, python3-psutil")
set(CPACK_DEBIAN_PACKAGE_REPLACES "${FLAVOR}-tools-python-${P}test-3.5.1")

# RPM
Expand Down
Loading