Skip to content
Open
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
65 commits
Select commit Hold shift + click to select a range
16265f6
add github action for linux
wangcj05 Sep 26, 2024
996a49c
fix syntax issue
wangcj05 Sep 26, 2024
6f2b6d2
add github action test machie macos and windows
wangcj05 Sep 27, 2024
0327122
fix a couple of errors, and add numba which is required by statsforec…
wangcj05 Sep 27, 2024
3fe912e
fix one more error
wangcj05 Sep 27, 2024
d844acd
pin the version for numba and remove always in github action since it…
wangcj05 Sep 27, 2024
def121d
downgrade ubuntu to 22 and revert numba
wangcj05 Sep 27, 2024
1657f79
swith statsforecast from conda to pip
wangcj05 Sep 30, 2024
8f68265
update tests for SyntheticHistory
wangcj05 Oct 2, 2024
7a3531e
pin statsforecast to 1.7
wangcj05 Oct 3, 2024
c45e1da
unpin scipy
wangcj05 Oct 3, 2024
0540f5d
pin scipy to 1.9.1
wangcj05 Oct 3, 2024
12dd82e
update mac
wangcj05 Oct 3, 2024
6d6867e
revert changes for gold file in Basic TSA test
wangcj05 Oct 24, 2024
555982b
revert changes for scipy
wangcj05 Oct 25, 2024
0f5dca2
Merge branch 'devel' into wangc/github_actions
wangcj05 Nov 4, 2024
8bd2dd6
Merge branch 'devel' into wangc/github_actions
wangcj05 Nov 12, 2024
6c4395c
Merge branch 'wangc/github_actions' of github.com:idaholab/raven into…
wangcj05 Nov 12, 2024
c2bcdf9
testing conda to install statsforecast
wangcj05 Nov 26, 2024
36d8a53
Merge branch 'devel' into wangc/github_actions
wangcj05 Jan 17, 2025
bb4fdbb
Merge branch 'devel' into wangc/github_actions
wangcj05 Apr 22, 2025
76b5454
use pip to install statsforecast instead of conda
wangcj05 Apr 22, 2025
a8187f7
update gitattribute
wangcj05 Apr 22, 2025
6533e6f
ignore hpp for github language detection
wangcj05 Apr 22, 2025
ade13f6
Merge branch 'devel' into wangc/github_actions
wangcj05 Jun 17, 2025
ad0472e
update dependencies
wangcj05 Jun 17, 2025
5e06217
Merge branch 'devel' into wangc/github_actions
wangcj05 Jul 28, 2025
a1d6026
update scipy
wangcj05 Aug 1, 2025
0046247
update conda check
wangcj05 Aug 1, 2025
41da381
add conda path in Git Action machine
wangcj05 Aug 1, 2025
c209ee3
fix syntax error
wangcj05 Aug 1, 2025
97b47d3
add print for python path
wangcj05 Aug 1, 2025
4a100a6
for some reason, read_ravenrc is not workingx
wangcj05 Aug 1, 2025
64ee0c9
fix syntax error
wangcj05 Aug 1, 2025
c38cf6f
add python command
wangcj05 Aug 1, 2025
75bb366
Merge branch 'devel' into wangc/github_actions
wangcj05 Oct 25, 2025
76ae0fd
revert change in establish_conda_env.sh
wangcj05 Oct 25, 2025
a70f1bb
resolve type error in Linux
wangcj05 Oct 25, 2025
e1c41f5
update conda path in github action Windows machine
wangcj05 Oct 25, 2025
d7f3ff2
update github action
wangcj05 Oct 26, 2025
8634abc
force python to 3.11 for linux
wangcj05 Oct 27, 2025
9b2a717
disable plugins for linux test
wangcj05 Oct 27, 2025
01a02e3
test python 3.11 for linux
wangcj05 Oct 27, 2025
a8c3c06
flex python in Linux
wangcj05 Oct 27, 2025
91d10b6
switch to pip
wangcj05 Oct 28, 2025
f7f11f2
pin numba to 0.61 to avoid coverage issue
wangcj05 Oct 28, 2025
65f2b0d
update test max time and rel err
wangcj05 Oct 28, 2025
988e873
pin typing-extension to 4.14 for ray issue
wangcj05 Oct 28, 2025
43b12ee
typo
wangcj05 Oct 28, 2025
751e74e
disable grpcio
wangcj05 Oct 29, 2025
c674dc4
include max_time for ray external test
wangcj05 Oct 29, 2025
1594bb6
regold DiffARMA
wangcj05 Oct 29, 2025
42e7045
enable plugins testing
wangcj05 Oct 29, 2025
67464ef
update tests rel err
wangcj05 Oct 29, 2025
2652434
diable FARM due to issue of quadprog lib, and change batch from 4 to …
wangcj05 Oct 29, 2025
8acf6ae
remove HERON LOGOS and DOVE from testing due to pyomo conflicts
wangcj05 Oct 29, 2025
63960cb
pin python to 3.11 for mac
wangcj05 Oct 29, 2025
9b3fc4f
pin grpcio due to the issue with ray, ray has issue with grpcio >1.71
wangcj05 Oct 30, 2025
f446f3f
unpin ray 2.38
wangcj05 Oct 30, 2025
abf51b3
pin ray to 2.49 and remove typing-extension
wangcj05 Oct 30, 2025
4fb3581
add notes for dependencies
wangcj05 Oct 30, 2025
f38d3a0
pin typing-extension and skip ExternalModelRay test
wangcj05 Oct 30, 2025
9fc2520
add a couple of github machines
wangcj05 Oct 30, 2025
cb8a09a
enable to test all the plugins except FARM
wangcj05 Oct 31, 2025
cad921d
disable HERON and DOVE due to pyomo conflicts
wangcj05 Oct 31, 2025
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
454 changes: 454 additions & 0 deletions .github/workflows/github-actions.yml

Large diffs are not rendered by default.

46 changes: 31 additions & 15 deletions dependencies.xml
Original file line number Diff line number Diff line change
Expand Up @@ -35,30 +35,43 @@ Note all install methods after "main" take

end reading flow
-->

<!--
1. ray can be updated to 2.51, however for mac test machine, only 2.49 is installed. In addition,
ray have conflicts with grpcio, which sometime we need to pin the version of grpcio
2. ray may also have issue with typing-extensions, which sometime we need to pin the version
3. few libraries need to be updated in the near future, such as numpy, scikit-learn, scipy
4. some libraries in plugins can cause library conflicts, such as FARM quadprog which can really
limit our library choices.
-->

<dependencies>
<main>
<h5py/>
<numpy>1.26</numpy>
<h5py source="pip"/>
<numpy source="pip">1.26</numpy>
<!-- pip installs were overwritting the scipy version, so using pip -->
<scipy source="pip">1.12</scipy>
<scikit-learn>1.1</scikit-learn>
<pandas/>
<scikit-learn source="pip">1.1</scikit-learn>
<!-- Pin numba to 0.61 to avoid coverage issue: https://github.com/numba/numba/issues/10239 -->
<numba source="pip">0.61</numba>
<pandas source="pip"/>
<!-- Note most versions of xarray work, but some (such as 0.20) don't -->
<xarray/>
<xarray source="pip"/>
<netcdf4 source="pip">1.6</netcdf4>
<matplotlib>3.6</matplotlib>
<statsmodels>0.13</statsmodels>
<cloudpickle/>
<matplotlib source="pip">3.6</matplotlib>
<statsmodels source="pip">0.13</statsmodels>
<cloudpickle source="pip"/>
<tensorflow source="pip">2.14</tensorflow>
<grpcio source="pip" />
<!-- <grpcio source="pip">1.69</grpcio> -->
<!-- conda is really slow on windows if the version is not specified.-->
<python skip_check='True' os='windows'>3.11</python>
<python skip_check='True' os='mac,linux'>3</python>
<python skip_check='True' os='linux'>3</python>
<python skip_check='True' os='mac'>3.11</python>
<hdf5 skip_check='True'/>
<swig skip_check='True'/>
<pylint/>
<coverage/>
<lxml/>
<lxml source="pip"/>
<psutil/>
<pip/>
<pyDOE3 source="pip"/>
Expand All @@ -67,14 +80,17 @@ Note all install methods after "main" take
<nomkl os='linux' skip_check='True'/>
<cmake skip_check='True' optional='True'/>
<dask source="pip" pip_extra="[complete]"/>
<ray source="pip" pip_extra="[default]">2.38</ray>
<!-- Pin typing-extensions to resolve some import issue in ray -->
<typing-extensions source="pip">4.14</typing-extensions>
<ray source="pip" pip_extra="[default]">2.49</ray>
<!-- redis is needed by ray, but on windows, this seems to need to be explicitly stated -->
<redis source="pip" os='windows'/>
<imageio source="pip">2.22</imageio>
<line_profiler optional='True'/>
<!-- <ete3 optional='True'/> -->
<statsforecast/>
<pywavelets>1.4</pywavelets>
<!-- <statsforecast source='pip'/> -->
<statsforecast source="pip"/>
<pywavelets source="pip">1.4</pywavelets>
<python-sensors source="pip"/>
<numdifftools source="pip">0.9</numdifftools>
<fmpy optional='True'/>
Expand All @@ -84,7 +100,7 @@ Note all install methods after "main" take
<ipopt skip_check='True' optional='True'/>
<cyipopt optional='True'/>
<pyomo-extensions source="pyomo" skip_check='True' optional='True'/>
<setuptools />
<setuptools source="pip"/>
<!-- source="mamba" are the ones installed when mamba is installed -->
<mamba source='mamba' skip_check='True'/>
<pydmd source="pip"/>
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@

_AVAILABLE_FILE_TYPES = ['functionObjectProperties', 'volScalarField', 'volVectorField','surfaceScalarField', 'surfaceVectorField']

def checkAccessAndWaitIfStillAccessed(filename: str | pathlib.Path, gracePeriod: float = 1., timeout: float =100.):
def checkAccessAndWaitIfStillAccessed(filename: Union[str, pathlib.Path], gracePeriod: float = 1., timeout: float =100.):
"""
This utility method is aimed to check the timestamp of last access of the file
and wait (up to timeout+gracePeriod) if it is within the gracePeriod
Expand Down Expand Up @@ -66,8 +66,8 @@ class openfoamOutputParser(object):
Class to parse different openFOAM output files
"""
def __init__(self,
caseDirectory: str | pathlib.Path,
caseFileName: str | pathlib.Path,
caseDirectory: Union[str,pathlib.Path],
caseFileName: Union[str,pathlib.Path],
variables: List[str] = None, writeCentroids: bool = False,
checkAccessAndWait: bool = False):
"""
Expand Down Expand Up @@ -218,7 +218,7 @@ def _expandVariablesFromVectorToScalar(data):
newData[var] = data[var]
return newData

def _readCumulativeContErr(self, path: str | pathlib.Path) -> Tuple[List[int], Union[float, list]]:
def _readCumulativeContErr(self, path: Union[str,pathlib.Path]) -> Tuple[List[int], Union[float, list]]:
"""
Method to read the cumulativeContErr file
@ In, path, str | Path, Path to the OpenFOAM file (e.g. '0.1/uniform/cumulativeContErr').
Expand Down Expand Up @@ -282,7 +282,7 @@ def _functionObjectPropertiesParseDict(self, path: pathlib.Path) -> Dict[str, ob
out[key] = vec
return out

def uniformFolderAggregate(self, caseDir: str | pathlib.Path) -> Tuple[np.ndarray, Dict[str, np.ndarray]]:
def uniformFolderAggregate(self, caseDir: Union[str,pathlib.Path]) -> Tuple[np.ndarray, Dict[str, np.ndarray]]:
"""
Method to walk the case, read every time directory's functionObjectProperties and cumulativeContErr (if present)
and collect the values into time-sorted NumPy arrays.
Expand Down Expand Up @@ -376,7 +376,7 @@ def _collect(self, foamfile: pathlib.Path,
return times, np.stack(values), centroids

def aggregateFieldNumpy(self, field: str = "U",
foamCasefile: str | None = None
foamCasefile: Union[str, None] = None
) -> Tuple[np.ndarray, np.ndarray, np.ndarray]:
"""
Aggregate 'field' over every available time step.
Expand Down
8 changes: 8 additions & 0 deletions run_tests
Original file line number Diff line number Diff line change
Expand Up @@ -50,6 +50,12 @@ for A in "$@"; do
esac
done
echo 'Loading libraries ...'

if [[ "$INSTALLATION_MANAGER" != "PIP" ]]
then
INSTALLATION_MANAGER=CONDA
fi

if [[ $SKIP_LOAD_ENV == 1 ]];
then
echo Using currently active python environment, with command $(command -v python)
Expand All @@ -58,6 +64,7 @@ elif [[ "$INSTALLATION_MANAGER" == "CONDA" ]];
then
source $SCRIPT_DIR/scripts/establish_conda_env.sh --load
echo Loaded conda environment, with command $(command -v python)
PYTHON_COMMAND=$(command -v python)
elif [[ "$INSTALLATION_MANAGER" == "PIP" ]];
then
source $SCRIPT_DIR/scripts/establish_conda_env.sh --load --installation-manager PIP
Expand All @@ -68,6 +75,7 @@ else
then
# check the RC file
PYTHON_COMMAND=$(read_ravenrc "PYTHON_COMMAND")
echo Python Command Debug: $PYTHON_COMMAND
fi
fi

Expand Down
23 changes: 12 additions & 11 deletions scripts/establish_conda_env.sh
Original file line number Diff line number Diff line change
Expand Up @@ -59,17 +59,18 @@ function find_conda_defs ()
# default location of conda definitions, windows is unsurprisingly an exception
if [[ "$OSOPTION" = "--os windows" ]];
then
if test -e "/c/ProgramData/Miniconda3/etc/profile.d/conda.sh"
then
CONDA_DEFS="/c/ProgramData/Miniconda3/etc/profile.d/conda.sh";
elif test -e "$HOME/AppData/Local/miniconda3/etc/profile.d/conda.sh"
then
CONDA_DEFS="$HOME/AppData/Local/miniconda3/etc/profile.d/conda.sh
"
else
echo Failed to find Conda at /c/ProgramData/Miniconda3/etc/profile.d/conda.sh and $HOME/AppData/Local/miniconda3/etc/profile.d/conda.sh

fi
if test -e "/c/ProgramData/Miniconda3/etc/profile.d/conda.sh"
then
CONDA_DEFS="/c/ProgramData/Miniconda3/etc/profile.d/conda.sh";
elif test -e "$HOME/AppData/Local/miniconda3/etc/profile.d/conda.sh"
then
CONDA_DEFS="$HOME/AppData/Local/miniconda3/etc/profile.d/conda.sh"
elif test -e "/c/Users/runneradmin/miniconda3/etc/profile.d/conda.sh"
then
CONDA_DEFS="/c/Users/runneradmin/miniconda3/etc/profile.d/conda.sh"
else
echo Failed to find Conda at /c/ProgramData/Miniconda3/etc/profile.d/conda.sh and $HOME/AppData/Local/miniconda3/etc/profile.d/conda.sh
fi
elif test -e "$HOME/miniconda3/etc/profile.d/conda.sh";
then
CONDA_DEFS="$HOME/miniconda3/etc/profile.d/conda.sh";
Expand Down
Original file line number Diff line number Diff line change
Expand Up @@ -23,7 +23,7 @@
<RunInfo>
<WorkingDir>InternalParallelExtModelRay</WorkingDir>
<Sequence>ParalleMonteCarlo</Sequence>
<batchSize>4</batchSize>
<batchSize>3</batchSize>
<parallelMethod>ray</parallelMethod>
</RunInfo>

Expand Down
4 changes: 3 additions & 1 deletion tests/framework/InternalParallelTests/tests
Original file line number Diff line number Diff line change
Expand Up @@ -13,7 +13,9 @@
type = 'RavenFramework'
input = 'test_internal_parallel_extModelRay.xml'
UnorderedCsv = 'InternalParallelExtModelRay/testPointSet_dump.csv'
skip_if_OS = windows
# skip_if_OS = windows
skip = "random failure, ray issue with typing-extension and grpcio library"
max_time = 500
[../]
[./PostProcessor]
type = 'RavenFramework'
Expand Down
6 changes: 3 additions & 3 deletions tests/framework/PostProcessors/LimitSurface/tests
Original file line number Diff line number Diff line change
Expand Up @@ -14,7 +14,7 @@
input = 'test_LimitSurface_and_integral.xml'
output = 'limitSurface_integral/LimitSurfaceUnWeightedPb_dump.xml limitSurface_integral/LimitSurfaceWeightedPb_dump.xml'
csv = 'limitSurface_integral/LimitSurfaceWeightedPb_dump.csv limitSurface_integral/LimitSurfaceUnWeightedPb_dump.csv'
max_time = 300
max_time = 500
rel_err = 0.001
#skip = 'need to be fixed'
[../]
Expand All @@ -32,14 +32,14 @@
input = 'test_LimitSurface_with_err_bounds.xml'
output = 'limitSurfaceBoundingError/LimitSurfaceWeightedPb_dump.xml'
max_time = 300
rel_err = 0.001
rel_err = 0.005
# replace skip_if_OS = windows with Windows specific gold file
[./csv]
type = OrderedCSV
output = 'limitSurfaceBoundingError/LimitSurfaceWeightedPb_dump.csv'
windows_gold = 'limitSurfaceBoundingError/WindowsLimitSurfaceWeightedPb_dump.csv'
mac_gold = 'limitSurfaceBoundingError/MacLimitSurfaceWeightedPb_dump.csv'
rel_err = 0.003
rel_err = 0.005
[../]
[../]

Expand Down
Original file line number Diff line number Diff line change
@@ -0,0 +1,3 @@
Fourier__signal_fa__period2.0__amplitude,ARMA__signal_fa__variance,ARMA__signal_fa__MA__2,ARMA__signal_fa__MA__1,ARMA__signal_a__AR__1,Fourier__signal_fa__period2.0__phase,ARMA__signal_a__variance,Fourier__signal_f__period10.0__amplitude,Fourier__signal_f__period2.0__phase,ARMA__signal_a__MA__2,ARMA__signal_fa__constant,ARMA__signal_fa__AR__1,ARMA__signal_a__MA__0,Fourier__signal_fa__fit_intercept,Fourier__signal_f__fit_intercept,Fourier__signal_f__period10.0__phase,Fourier__signal_fa__period5.0__phase,Fourier__signal_fa__period10.0__amplitude,Fourier__signal_f__period5.0__amplitude,Fourier__signal_fa__period5.0__amplitude,Fourier__signal_f__period5.0__phase,ARMA__signal_fa__AR__0,ARMA__signal_a__MA__1,ARMA__signal_fa__MA__0,Fourier__signal_fa__period10.0__phase,ARMA__signal_a__AR__0,Fourier__signal_f__period2.0__amplitude,ARMA__signal_a__constant
2.27119924552,0.545082802149,-0.0784346169836,0.177036376895,-0.758871353908,-0.165113659694,0.531122354771,4.0,3.50800062309e-15,-0.0764776204887,0.0118581486643,-0.439315188798,-1.14427853933,41.8908824287,42.0,-3.14159265359,0.763083169957,3.6485771704,3.0,3.00629571435,0.785398163397,1.35284007491,0.226235051829,-0.758810272971,-3.08854058527,1.75724084413,2.0,0.00810343993023
2.77834476114,0.277925478839,-0.240259217322,0.418073457847,-0.772077636204,0.00410650639164,0.274702280402,2.0,3.2786106481e-15,-0.239683052249,0.0197562630156,-0.780706487772,-1.09280663591,20.0760911024,20.0,3.14159265359,0.587758626516,2.27417407299,1.0,0.678339437727,0.785398163397,1.77447163616,0.403928679353,-1.11569378557,-3.13023980907,1.76475177792,3.0,0.0180760678735
1 change: 1 addition & 0 deletions tests/framework/PostProcessors/TSACharacterizer/tests
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@
output = 'Basic/chz.csv'
windows_gold = 'Basic/windowsChz.csv'
mac_gold = 'Basic/windowsChz.csv'
# mac_gold = 'Basic/macChz.csv'
rel_err = 1.5e-1 # limited by ARMA__signal_fa__constant
zero_threshold = 1e-12
[../]
Expand Down
Loading
Loading