Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
79 commits
Select commit Hold shift + click to select a range
86f8dc6
Add graphify knowledge-graph query guidance
HadenSmith Sep 25, 2026
4880297
Preserve probability order and strictness in EmpiricalDistribution Cl…
HadenSmith Oct 18, 2026
78dcdb6
Add the rmc-numerics Python wheel: Numerics.dll, the CoreCLR loader a…
HadenSmith Oct 18, 2026
138ef70
Build and test the rmc-numerics wheel on Linux and Windows in CI
HadenSmith Oct 18, 2026
582569b
rmc-numerics: the wrappers Stochastics needs to drop its Numerics twins
HadenSmith Oct 18, 2026
5e67bae
rmc-numerics: net_errors, bootstrap member arrays and LnNormal log-pa…
HadenSmith Oct 18, 2026
9538a46
rmc-numerics: deep copies own their .NET objects
HadenSmith Oct 18, 2026
a03a153
rmc-numerics: bind the Marshal.Copy overloads once per process
HadenSmith Oct 18, 2026
7a35f32
Add UnivariateDistributionBase.ParameterSetQuantiles: quantiles and v…
HadenSmith Oct 18, 2026
62a4624
rmc-numerics: wrap Autocorrelation.Function (statistics.autocorrelati…
HadenSmith Oct 19, 2026
93d012c
rmc-numerics: wrap ParameterSetQuantiles (parameter_set_quantile_tabl…
HadenSmith Oct 21, 2026
279a5a4
Draft the RMC.Numerics 2.3.0 release notes (not published)
HadenSmith Oct 21, 2026
6c5ca66
rmc-numerics: pin the interim locally built Numerics.dll (2.3.0-dev.1…
HadenSmith Oct 21, 2026
8991fc1
rmc-numerics: record the local build command (NUMERICS_BUILD_COMMAND)…
HadenSmith Oct 21, 2026
91382a6
rmc-numerics: wrap Numerics.Distributions.Dirichlet (alpha and symmet…
HadenSmith Oct 22, 2026
4941959
rmc-numerics: Int64, SByte and Boolean bulk copies in marshal (to_net…
HadenSmith Oct 23, 2026
5762b71
rmc-numerics: bind the IList<double> overload of array members once (…
HadenSmith Oct 23, 2026
0a1272f
Add a weighted UncertaintyAnalysisResults.ProcessMeanCurve overload (…
HadenSmith Oct 23, 2026
a1e6208
Add Statistics.ColumnPercentiles: Type 7 percentiles per column over …
HadenSmith Oct 23, 2026
320bf88
Add GeneralizedPareto.MLE(sample, location): maximum likelihood with …
HadenSmith Oct 23, 2026
c9cf8f2
Make ParameterSetQuantiles virtual and override it for GeneralizedExt…
HadenSmith Oct 23, 2026
f93d13d
Add weighted PlottingPositions.Function(weights, alpha); unit weights…
HadenSmith Oct 23, 2026
71a004c
Add Statistics.WilsonScoreInterval (rmc-numerics statistics.wilson_sc…
HadenSmith Oct 23, 2026
4657aee
Add plotting-position Statistics.Percentile overloads (Weibull = Hynd…
HadenSmith Oct 23, 2026
03142cc
rmc-numerics: weights in UncertaintyAnalysisResults.process_mean_curv…
HadenSmith Oct 23, 2026
5a72481
rmc-numerics: parameter_set_quantile_table reads the validity flags w…
HadenSmith Oct 23, 2026
676d9f7
Weighted ProcessMeanCurve: refuse an overflowing total weight; cover …
HadenSmith Oct 23, 2026
64fe1cb
ColumnPercentiles coverage: a single row, a fully finite column, para…
HadenSmith Oct 23, 2026
38bfe41
GeneralizedPareto.MLE(sample, location): refuse a constant sample; co…
HadenSmith Oct 23, 2026
90fc5b1
GEV ParameterSetQuantiles override coverage: empty inputs, the callin…
HadenSmith Oct 23, 2026
9af5795
Weighted PlottingPositions.Function: limit alpha to [0, 0.5] so every…
HadenSmith Oct 23, 2026
c160e9b
WilsonScoreInterval coverage: mirror symmetry, containment of the pro…
HadenSmith Oct 23, 2026
cfd4e16
Plotting-position Percentile coverage: Gringorten and median hand val…
HadenSmith Oct 23, 2026
62fcdd3
rmc-numerics: refusal coverage for the added wrappers (ValueError thr…
HadenSmith Oct 23, 2026
2660f1a
Release notes: the known-location GPD fit refuses a constant sample
HadenSmith Oct 23, 2026
c8042f1
rmc-numerics: pin the second interim locally built Numerics.dll (2.3.…
HadenSmith Oct 23, 2026
252c224
UnivariateDistributionBase: list forms of CCDF, LogPDF, LogCDF and Lo…
HadenSmith Oct 23, 2026
a3e9c3a
Tools: list forms of Expm1 and Log1p, each value bitwise the scalar m…
HadenSmith Oct 23, 2026
767e557
BivariateCopula: paired-list forms of PDF, CDF, ConditionalCDF and In…
HadenSmith Oct 23, 2026
9e4155c
Statistics: plotting-position ColumnPercentiles sharing the column lo…
HadenSmith Oct 23, 2026
2b0921d
Release notes: the list forms, the plotting-position column percentil…
HadenSmith Oct 23, 2026
1692343
rmc-numerics: resolve enum names once, bind overloaded members once, …
HadenSmith Oct 23, 2026
ad463fd
rmc-numerics: the packaged runtime configuration compiles methods wit…
HadenSmith Oct 23, 2026
f503161
PlottingPositions.Alpha: one table of the alpha coefficients read by …
HadenSmith Oct 24, 2026
2635e96
Statistics.WilsonScoreInterval returns double[] like the other interv…
HadenSmith Oct 24, 2026
8de658c
IFixedParameterEstimation: estimation with parameters held at known v…
HadenSmith Oct 24, 2026
48cd268
Statistics.ColumnMeans: per-column sequential means over the finite e…
HadenSmith Oct 24, 2026
f665005
Tools.Log1p: the compensated form at every finite argument above -1 (…
HadenSmith Oct 24, 2026
1e46b31
Statistics.WilsonScoreInterval keeps its (Lower, Upper) value-tuple s…
HadenSmith Oct 24, 2026
ab0983a
Tools.Log1p documentation states the accuracy as within one unit in t…
HadenSmith Oct 24, 2026
4923271
rmc-numerics 2.3.0.dev3: pin the interim Numerics.dll 2.3.0-dev.3 bui…
HadenSmith Oct 24, 2026
1e74cf2
Build: target net10.0 and net481, add package validation against 2.2.0
HadenSmith Nov 10, 2026
49031e5
Tools: compensated sums, LogSumExp by axis, accurate Log1p and Expm1
HadenSmith Nov 10, 2026
c036332
Special functions: corrected incomplete beta and inverse incomplete g…
HadenSmith Nov 10, 2026
027d94b
Linear algebra: QL eigensolver, blocked Cholesky and TryCholesky
HadenSmith Nov 10, 2026
89c0ff0
Data: column statistics, corrected dispersion and USGS Water Data API
HadenSmith Nov 10, 2026
139bb4c
Integration and calculus: opt-in QAGS, linear Fourier methods, RungeK…
HadenSmith Nov 10, 2026
84c1b01
Optimization and root finding: L-BFGS-B, CMA-ES, DDS and SciPy Brent …
HadenSmith Nov 10, 2026
796bbf2
Functions: list overloads and faster composite and ensemble functions
HadenSmith Nov 10, 2026
d91ca2d
Sampling: NUTS value-and-gradient delegate, reproducible MCMC and boo…
HadenSmith Nov 10, 2026
babbf2c
Univariate distributions: accuracy fixes, array members and global modes
HadenSmith Nov 10, 2026
f4894bd
Copulas and multivariate: log-space densities and Genz-Bretz Student-…
HadenSmith Nov 10, 2026
5f9bdd5
Regional frequency analysis: the Hosking-Wallis method
HadenSmith Nov 10, 2026
10b701d
Machine learning: Gaussian process regression, kriging, elastic net a…
HadenSmith Nov 10, 2026
4f8b465
Benchmarks: BenchmarkDotNet project for performance-critical methods
HadenSmith Nov 10, 2026
8aaffd3
pynumerics: Python package over Numerics.dll
HadenSmith Nov 10, 2026
688e0d0
Docs: guides and references for the 2.3.0 additions
HadenSmith Nov 10, 2026
a27d070
CI: workflows for the new targets and the Python package
HadenSmith Nov 10, 2026
72370d2
Release 2.3.0: package version, release notes and citation metadata
HadenSmith Nov 10, 2026
bfd6264
Linux test image: .NET 10 SDK and Python 3.12 running the Test_Numeri…
HadenSmith Nov 10, 2026
7b93ad3
pynumerics: build_wheel.py writes the Numerics version, assembly vers…
HadenSmith Nov 10, 2026
2090f77
Workflows: PythonPublish runs after a successful NuGet publish and bu…
HadenSmith Nov 10, 2026
608f0dd
Test_Numerics: bitwise references recorded on Windows stay exact ther…
HadenSmith Nov 10, 2026
fb17fe0
pynumerics: the RWMH parallel and k-means wall-clock comparisons are …
HadenSmith Nov 10, 2026
52885c4
Release workflow: release/X.Y.Z branches cut from main and merged wit…
HadenSmith Nov 10, 2026
8f0da2e
Release 2.3.0: release date 2026-11-10, final package release notes, …
HadenSmith Nov 10, 2026
9cac1da
pynumerics: Development Status 4 - Beta
HadenSmith Nov 10, 2026
d4745df
Linux test image: copy the tree without the source owner and mark the…
HadenSmith Nov 10, 2026
dca29e9
pynumerics: the near-zero LogSumExp comparison with SciPy allows 3 sc…
HadenSmith Nov 10, 2026
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
The table of contents is too big for display.
Diff view
Diff view
  •  
  •  
  •  
2 changes: 2 additions & 0 deletions .gitattributes
Original file line number Diff line number Diff line change
@@ -0,0 +1,2 @@
# Shell scripts run on Linux (CI and the linux-test Docker image) and must keep LF endings on every checkout.
*.sh text eol=lf
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/01-bug-report.yml
Original file line number Diff line number Diff line change
Expand Up @@ -61,7 +61,7 @@ body:
attributes:
label: Operating system and .NET details
description: Add any OS, target framework, SDK, runtime, or IDE version details you know.
placeholder: "Example: Windows 11, net8.0, .NET 10 SDK, Visual Studio 2026"
placeholder: "Example: Windows 11, net10.0, .NET 10 SDK, Visual Studio 2026"
validations:
required: false

Expand Down
2 changes: 1 addition & 1 deletion .github/ISSUE_TEMPLATE/04-question.yml
Original file line number Diff line number Diff line change
Expand Up @@ -49,7 +49,7 @@ body:
attributes:
label: Operating system and .NET details
description: Add any OS, target framework, SDK, runtime, or IDE version details that may matter.
placeholder: "Example: Windows 11, net8.0, .NET 10 SDK, Rider or Visual Studio"
placeholder: "Example: Windows 11, net10.0, .NET 10 SDK, Rider or Visual Studio"
validations:
required: false

Expand Down
27 changes: 27 additions & 0 deletions .github/docker/linux-test/Dockerfile
Original file line number Diff line number Diff line change
@@ -0,0 +1,27 @@
# Linux test image for RMC.Numerics and pynumerics: the .NET 10 SDK on Ubuntu 24.04 with Python 3.12.
#
# Build from the repository root:
# docker build -t numerics-linux-test .github/docker/linux-test
# Run every check against a read-only mount of the working tree (see run-checks.sh):
# docker run --rm -v "$PWD:/src:ro" numerics-linux-test
#
# The image holds only the toolchains. The checks copy the tree into the container, so build
# output never lands in the mounted checkout, and each Python environment is created fresh.

FROM mcr.microsoft.com/dotnet/sdk:10.0-noble

ENV DEBIAN_FRONTEND=noninteractive \
DOTNET_CLI_TELEMETRY_OPTOUT=1 \
DOTNET_NOLOGO=1 \
PIP_DISABLE_PIP_VERSION_CHECK=1 \
PYTHONDONTWRITEBYTECODE=1

RUN apt-get update \
&& apt-get install -y --no-install-recommends python3.12 python3.12-venv \
&& rm -rf /var/lib/apt/lists/*

COPY run-checks.sh identity-check.sh /usr/local/bin/
RUN chmod +x /usr/local/bin/run-checks.sh /usr/local/bin/identity-check.sh

WORKDIR /work
CMD ["run-checks.sh"]
36 changes: 36 additions & 0 deletions .github/docker/linux-test/identity-check.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,36 @@
#!/usr/bin/env bash
# Installs a pynumerics wheel into a clean environment and checks the identity of the loaded Numerics.dll.
#
# Usage (a fresh container, the wheel's directory mounted read-only):
# docker run --rm -v "$PWD/dist:/dist:ro" numerics-linux-test identity-check.sh /dist
#
# The installed package must load its own packaged Numerics.dll on CoreCLR, and that file must match the
# identity the wheel build wrote into _version.py (assembly version, informational version, SHA-256).

set -euo pipefail

DIST=${1:-/dist}
python3.12 -m venv /tmp/identity-venv
/tmp/identity-venv/bin/python -m pip install -q "$DIST"/pynumerics-*-py3-none-any.whl
cd /tmp
/tmp/identity-venv/bin/python -I - <<'EOF'
import pynumerics
from pynumerics import runtime

identity = pynumerics.assert_numerics_identity()
info = pynumerics.get_runtime_info()
assert str(info.kind) == "CoreCLR", info
assert identity.location.parent.resolve() == runtime._PACKAGED_BIN.resolve(), identity.location
assert identity.informational_version.split("+")[0] == pynumerics.NUMERICS_VERSION, identity
assert identity.is_packaged
print("pynumerics", pynumerics.__version__)
print("runtime", info.kind)
print("NUMERICS_VERSION", pynumerics.NUMERICS_VERSION)
print("NUMERICS_ASSEMBLY_VERSION", pynumerics.NUMERICS_ASSEMBLY_VERSION, "loaded", identity.version)
print("NUMERICS_SHA256", pynumerics.NUMERICS_SHA256)
print("loaded sha256 ", identity.sha256)
print("informational", identity.informational_version)
print("NUMERICS_SOURCE_COMMIT", repr(pynumerics.NUMERICS_SOURCE_COMMIT))
print("location", identity.location)
print("identity check passed")
EOF
96 changes: 96 additions & 0 deletions .github/docker/linux-test/run-checks.sh
Original file line number Diff line number Diff line change
@@ -0,0 +1,96 @@
#!/usr/bin/env bash
# Linux checks of RMC.Numerics and pynumerics, run inside the linux-test image.
#
# Inputs (environment):
# SRC the repository tree, mounted read-only (default /src)
# CHECKS the steps to run, any of: dotnet wheel pytest (default: all three)
# NUMERICS_NUPKG build the wheel from this RMC.Numerics package instead of the local net10.0 build
# OUT if this directory exists, the wheel is copied into it (default /out)
# WHEEL_DIR test the wheel in this directory instead of the one the wheel step builds
#
# The tree is copied to /work and its tracked files are checked out again with LF line endings, so the
# run sees what a Linux clone sees even when SRC is a Windows working tree with CRLF files.

set -euo pipefail

SRC=${SRC:-/src}
CHECKS=${CHECKS:-dotnet wheel pytest}
OUT=${OUT:-/out}
WORK=/work/numerics
PYTHON=python3.12
LOGS=/work/logs

has() { [[ " $CHECKS " == *" $1 "* ]]; }
step() { printf '\n==== %s ====\n' "$*"; }

step "Copy the tree from $SRC"
rm -rf "$WORK" "$LOGS"
mkdir -p "$WORK" "$LOGS"
tar -C "$SRC" \
--exclude=./.git --exclude=bin --exclude=obj --exclude=TestResults --exclude=dist --exclude=build \
--exclude=_build --exclude=generated --exclude=.venv --exclude=__pycache__ --exclude='*.egg-info' \
--exclude=.pytest_cache --exclude=.ruff_cache --exclude=graphify-out --exclude='_bin/*.dll' \
-cf - . | tar -C "$WORK" --no-same-owner -xf -
cd "$WORK"
# A CI checkout is owned by the runner's user, not root; keep git's ownership check from rejecting the copy.
git config --global --add safe.directory "$WORK"
# A repository with the GitHub remote, so SourceLink stamps the commit into the informational version.
git init -q
git config core.autocrlf input
git config core.safecrlf false
git remote add origin https://github.com/USACE-RMC/Numerics.git
git add -A
git -c user.name=linux-test -c user.email=linux-test@localhost commit -q -m "Linux check snapshot"
git ls-files -z | xargs -0 rm -f
git checkout -q -- .
echo "snapshot commit $(git rev-parse HEAD)"

if has dotnet; then
step "dotnet build Test_Numerics (net10.0, Release)"
dotnet build Test_Numerics/Test_Numerics.csproj -c Release -f net10.0 2>&1 | tee "$LOGS/dotnet-build.log"
grep -Eq '^ +0 Warning\(s\)' "$LOGS/dotnet-build.log" || { echo "the build reported warnings"; exit 1; }

step "dotnet test Test_Numerics (net10.0, Release)"
dotnet test Test_Numerics/Test_Numerics.csproj -c Release -f net10.0 --no-build \
--filter "TestCategory!=LiveServiceIntegration" 2>&1 | tee "$LOGS/dotnet-test.log"
fi

if has wheel; then
cd "$WORK/python/pynumerics"
$PYTHON -m venv /work/venv-build
/work/venv-build/bin/python -m pip install -q build
if [[ -n "${NUMERICS_NUPKG:-}" ]]; then
step "Build the wheel from $NUMERICS_NUPKG"
/work/venv-build/bin/python scripts/build_wheel.py --nupkg "$NUMERICS_NUPKG" --download --out /work/dist
else
step "Build the wheel from the local net10.0 Numerics.dll"
dll="$WORK/Numerics/bin/Release/net10.0/Numerics.dll"
if [[ ! -f "$dll" ]]; then
dotnet build "$WORK/Numerics/Numerics.csproj" -c Release -f net10.0 2>&1 | tee "$LOGS/numerics-build.log"
fi
/work/venv-build/bin/python scripts/build_wheel.py --dll "$dll" --download --out /work/dist
fi
if [[ -d "$OUT" ]]; then
cp /work/dist/pynumerics-*-py3-none-any.whl "$OUT"/
fi
fi

if has pytest; then
wheel_dir=${WHEEL_DIR:-/work/dist}
step "Install the wheel from $wheel_dir into a clean environment"
$PYTHON -m venv /work/venv-test
/work/venv-test/bin/python -m pip install -q "$wheel_dir"/pynumerics-*-py3-none-any.whl pytest numpydoc ruff scipy \
statsmodels scikit-learn shapely "arviz>=0.17,<1" "dataretrieval>=1.4" "wetterdienst>=0.184" "kiwis-pie>=0.10.5"

step "ruff"
(cd "$WORK/python/pynumerics" && /work/venv-test/bin/python -m ruff check src tests scripts)

step "pytest against the installed wheel"
rm -rf /work/pytest
mkdir -p /work/pytest
cp -r "$WORK/python/pynumerics/tests" "$WORK/python/pynumerics/docs" "$WORK/python/pynumerics/scripts" \
"$WORK/python/pynumerics/pyproject.toml" /work/pytest/
(cd /work/pytest && /work/venv-test/bin/python -m pytest -q -p no:cacheprovider -m "not benchmark" tests 2>&1 | tee "$LOGS/pytest.log")
fi

step "Done: $CHECKS"
6 changes: 4 additions & 2 deletions .github/workflows/Integration.yml
Original file line number Diff line number Diff line change
Expand Up @@ -21,8 +21,6 @@ jobs:
uses: actions/setup-dotnet@v4
with:
dotnet-version: |
8.0.x
9.0.x
10.0.x

- name: Build
Expand All @@ -34,3 +32,7 @@ jobs:
# Live provider outages and full-record download timeouts must not block PRs.
# Keep deterministic download, parsing, validation, and numerical tests in the gate.
run: dotnet test -c Release --no-build --filter "TestCategory!=LiveServiceIntegration"

- name: Pack and validate against the baseline release
# Package validation compares the public API with PackageValidationBaselineVersion on nuget.org.
run: dotnet pack Numerics/Numerics.csproj -c Release --no-build -o ./packages
2 changes: 0 additions & 2 deletions .github/workflows/NuGetPublish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -16,8 +16,6 @@ jobs:
- uses: actions/setup-dotnet@v4
with:
dotnet-version: |
8.0.x
9.0.x
10.0.x

- name: Extract version from tag
Expand Down
Loading
Loading