Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
69 commits
Select commit Hold shift + click to select a range
2a254ce
Replace abstract fields with specific types
sou-cheng-choi Jun 2, 2026
2d4ba82
Replace abstract fields with specific types
sou-cheng-choi Jun 2, 2026
1ee36dc
Measure notebook run time
sou-cheng-choi Jun 2, 2026
8d49e53
Add benchmarking
sou-cheng-choi Jun 2, 2026
8990e48
Update Julia version to 1.12 and enhance benchmark script documentation
sou-cheng-choi Jun 2, 2026
7ce5a8a
Update References
sou-cheng-choi Jun 2, 2026
26dcfa9
measure execution time for each test,
sou-cheng-choi Jun 2, 2026
8df624f
Removed print statements
sou-cheng-choi Jun 2, 2026
f21de9e
Add benchmarking scripts for QMCPy and Julia
sou-cheng-choi Jun 2, 2026
7dccf01
minor changes
sou-cheng-choi Jun 2, 2026
f1541d6
+benchmarking scripts and results for QMC.jl vs QMCPy
sou-cheng-choi Jun 2, 2026
b8dd7ab
Fix CI: revert julia compat to 1.10 (CI matrix tests 1.10 and 1.11)
sou-cheng-choi Jun 2, 2026
795b48e
Speed up CubQMCNetG EuropeanOption
sou-cheng-choi Jun 2, 2026
7599f28
Speed up CubQMCNetG EuropeanOption
sou-cheng-choi Jun 3, 2026
d2d9d20
Improve benchmarking output and standardize ratio conventions
sou-cheng-choi Jun 3, 2026
9d24574
Aggregate summary metrics
sou-cheng-choi Jun 3, 2026
93b76ad
remove metadata and add single-run summary function
sou-cheng-choi Jun 3, 2026
642c423
Support custom output file labels
sou-cheng-choi Jun 3, 2026
5db56bf
Fix error
sou-cheng-choi Jun 3, 2026
f0c1324
Support labeled Julia-vs-QMCPy comparison
sou-cheng-choi Jun 3, 2026
852c121
Add README for benchmarking QMC.jl
sou-cheng-choi Jun 3, 2026
aad1791
Add large-d cases for Gaussian transform benchmarks
sou-cheng-choi Jun 3, 2026
79b3830
Add bench-all-label target
sou-cheng-choi Jun 3, 2026
10ac89a
Add bench-compare-labels target and update README
sou-cheng-choi Jun 3, 2026
0804b89
Reduce memory and run time
sou-cheng-choi Jun 3, 2026
e9ddfb6
Add allocation-audit benchmarks for Gaussian transforms and large-d c…
sou-cheng-choi Jun 3, 2026
a78fa5e
Disable formatting test
sou-cheng-choi Jun 3, 2026
ed9c57e
Add QMCPy benchmark for Python memory
sou-cheng-choi Jun 3, 2026
cbe3eb8
Add memory tracking
sou-cheng-choi Jun 3, 2026
3ebdcf5
Update memory measurement
sou-cheng-choi Jun 3, 2026
4645b6c
improve benchmarking output
sou-cheng-choi Jun 3, 2026
3fd0281
Add accuracy checks for Julia vs Python solutions
sou-cheng-choi Jun 3, 2026
4709fb3
Refactor benchmark integration cases
sou-cheng-choi Jun 3, 2026
d4553a1
Fix typo
sou-cheng-choi Jun 3, 2026
5785bbc
Update benchmarks.jl
sou-cheng-choi Jun 3, 2026
ae34022
Update keister.jl
sou-cheng-choi Jun 3, 2026
ea66887
Add exact value checks and accuracy summary for integration benchmarks
sou-cheng-choi Jun 3, 2026
a2a73aa
Add benchmarking cases and update documentation
sou-cheng-choi Jun 3, 2026
851ba29
Refactor stopping criteria calculations and enhance tests with exact …
sou-cheng-choi Jun 3, 2026
b77cfd7
Enhance Keister integral computation and tests
sou-cheng-choi Jun 3, 2026
6c6a190
Refactor benchmark integrand initialization
sou-cheng-choi Jun 3, 2026
9ce6deb
Add function to run benchmarks in a controlled environment with proje…
sou-cheng-choi Jun 3, 2026
ecc9567
Enhance stopping criteria and add tests
sou-cheng-choi Jun 4, 2026
293426c
Normalize order aliases in Lattice and update tests
sou-cheng-choi Jun 4, 2026
026f528
Add Rational Quadratic kernel implementation and tests
sou-cheng-choi Jun 4, 2026
d38af78
Add set_tolerance! function and corresponding tests for stopping crit…
sou-cheng-choi Jun 4, 2026
d018b7f
format
sou-cheng-choi Jun 4, 2026
c6d4616
Add KernelSquaredExponential implementation and update set_tolerance!…
sou-cheng-choi Jun 4, 2026
e5f6d18
fix format
sou-cheng-choi Jun 4, 2026
2cc77d9
Update Makefile to include benchmark directory in formatting and chec…
sou-cheng-choi Jun 4, 2026
c7aaa6f
Add AcceptanceRejectionReal
sou-cheng-choi Jun 4, 2026
f118226
Update JuliaFormatter settings and improve benchmark test assertions
sou-cheng-choi Jun 4, 2026
564c5d2
Better format
sou-cheng-choi Jun 4, 2026
d934070
Add support for digital options and corresponding tests
sou-cheng-choi Jun 4, 2026
e3f91d4
Improve output formatting
sou-cheng-choi Jun 4, 2026
d812831
Add exact value calculation for geometric Asian options and tests
sou-cheng-choi Jun 4, 2026
e4df345
Add deterministic value checks
sou-cheng-choi Jun 4, 2026
c74507f
Add closed-form reference values and sensitivity indices for Ishigami…
sou-cheng-choi Jun 4, 2026
524a763
Add new tests for integration and utility
sou-cheng-choi Jun 4, 2026
bb2ec97
formatting
sou-cheng-choi Jun 4, 2026
8442b48
Disable CompatHelper and nightly workflows; add disabled versions for…
sou-cheng-choi Jun 4, 2026
0db5b53
Merge origin/develop into choi and resolve conflicts
Copilot Jun 4, 2026
2cb7d24
Enhance digital net and lattice generators with custom generating vec…
sou-cheng-choi Jun 4, 2026
bbb2e8d
Better format and make coverage report
sou-cheng-choi Jun 4, 2026
31bd78f
Add support for custom random odd generating vectors in Lattice and e…
sou-cheng-choi Jun 4, 2026
b989469
Update documentation
sou-cheng-choi Jun 4, 2026
70e8624
Clean up documentation build directory before generating new document…
sou-cheng-choi Jun 4, 2026
266e9c1
Merge branch 'choi' of https://github.com/QMCSoftware/QMC.jl into choi
sou-cheng-choi Jun 4, 2026
6944da5
Enhance DigitalNetB2 with custom generating matrices support and impr…
sou-cheng-choi Jun 4, 2026
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
8 changes: 4 additions & 4 deletions .JuliaFormatter.toml
Original file line number Diff line number Diff line change
@@ -1,19 +1,19 @@
style = "default"
indent = 4
margin = 92
margin = 96
always_for_in = true
whitespace_typedefs = true
whitespace_ops_in_indices = true
remove_extra_newlines = true
short_to_long_function_def = false
long_to_short_function_def = false
long_to_short_function_def = true
always_use_return = false
whitespace_in_kwargs = true
whitespace_in_kwargs = false
annotate_untyped_fields_with_any = false
format_docstrings = false
align_assignment = false
align_struct_field = false
align_conditional = false
align_pair_arrow = false
trailing_comma = true
join_lines_based_on_source = true
join_lines_based_on_source = false
12 changes: 12 additions & 0 deletions .github/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
# GitHub Configuration

This directory holds GitHub-specific repository automation and metadata.

## Contents

- `workflows/`: GitHub Actions CI, docs, release, and maintenance workflows.

## Notes

- Workflow behavior is documented in [`../docs/src/ci-testing.md`](../docs/src/ci-testing.md).
- Generated macOS metadata files such as `.DS_Store` are not meaningful project content.
18 changes: 18 additions & 0 deletions .github/workflows/README.md
Original file line number Diff line number Diff line change
@@ -0,0 +1,18 @@
# GitHub Actions Workflows

This folder contains the repository's GitHub Actions workflows.

## Files

- `ci.yml`: fast Linux CI for unit tests, notebooks, and coverage upload.
- `ci-full.yml`: broader matrix CI for pull requests to `develop` and `master`.
- `docs.yml`: Documenter build and deployment workflow.
- `TagBot.yml`: release-tag automation.

### Disabled

- `format.yml.disabled`: disabled formatter workflow kept for reference.
- `CompatHelper.yml.disabled`: dependency update automation.
- `nightly.yml.disabled`: scheduled regression sweep on non-Linux platforms.

See [`../../docs/src/ci-testing.md`](../../docs/src/ci-testing.md) for the user-facing workflow overview.
13 changes: 9 additions & 4 deletions .github/workflows/ci.yml
Original file line number Diff line number Diff line change
Expand Up @@ -38,17 +38,22 @@ jobs:
- name: Install dependencies
run: julia --project=. -e 'using Pkg; Pkg.instantiate()'

- name: Run unit tests
run: julia --project=. -e 'using Pkg; Pkg.test()'
- name: Run unit tests with coverage
run: julia --project=. -e 'using Pkg; Pkg.test(coverage=true)'

- name: Process coverage
if: matrix.julia-version == '1.11'
uses: julia-actions/julia-processcoverage@v1
with:
directories: src

- name: Upload LCOV artifact
uses: actions/upload-artifact@v4
with:
name: coverage-julia-${{ matrix.julia-version }}-linux
path: lcov.info
if-no-files-found: warn

- name: Upload coverage to Codecov
if: matrix.julia-version == '1.11'
uses: codecov/codecov-action@v4
with:
files: lcov.info
Expand Down
File renamed without changes.
1 change: 1 addition & 0 deletions .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -41,3 +41,4 @@ benchmark/results/

# Developer-specific files
sc_*
lcov.info
23 changes: 16 additions & 7 deletions Makefile
Original file line number Diff line number Diff line change
@@ -1,6 +1,7 @@
.PHONY: test doc format format-check lint clean bench bench-compare bench-compare-py bench-compare-py-label bench-all-label bench-compare-labels check-qmcpy-python
.PHONY: test coverage doc format format-check lint clean bench bench-compare bench-compare-py bench-compare-py-label bench-all-label bench-compare-labels check-qmcpy-python

FORMATTER_PROJECT=devtools/formatter
DOC_DEPOT ?= $(if $(TMPDIR),$(TMPDIR),/tmp/)qmcju-doc-depot
QMCPY_PYTHON_AUTO := $(shell \
for py in python python3 "$(HOME)/miniconda3/bin/python" "$(HOME)/miniconda3/envs/qmcpy/bin/python" "$(HOME)/miniconda3/envs/qmcpy-leadership/bin/python"; do \
if { [ -x "$$py" ] || command -v "$$py" >/dev/null 2>&1; } && "$$py" -c "import qmcpy" >/dev/null 2>&1; then \
Expand Down Expand Up @@ -45,27 +46,35 @@ update:
test:
julia --project=. -e 'using Pkg; Pkg.instantiate(); Pkg.test()'

# Run tests with Julia coverage instrumentation
coverage:
find src test -name '*.cov' -delete
rm -f lcov.info
julia --project=. -e 'using Pkg; Pkg.instantiate(); Pkg.test(coverage=true)'
julia --project=. devtools/process_coverage.jl

# Run specific test file
test-%:
julia --project=. -e 'include("test/$*.jl")'

# Build documentation
doc:
julia --project=docs -e 'using Pkg; Pkg.instantiate(); Pkg.resolve()'
julia --project=docs docs/make.jl
rm -rf docs/build
JULIA_DEPOT_PATH="$(DOC_DEPOT):$(HOME)/.julia" julia --project=docs -e 'using Pkg; Pkg.instantiate(); Pkg.resolve()'
JULIA_DEPOT_PATH="$(DOC_DEPOT):$(HOME)/.julia" julia --project=docs docs/make.jl

# Format code with JuliaFormatter
# Format code with JuliaFormatter (uses the repo .JuliaFormatter.toml for all paths)
format:
julia --project=$(FORMATTER_PROJECT) -e 'using Pkg; Pkg.instantiate(); using JuliaFormatter; format("src/"); format("test/")'
julia --project=$(FORMATTER_PROJECT) -e 'using Pkg; Pkg.instantiate(); using JuliaFormatter; format(["src/", "test/", "benchmark/"])'

# Check formatting (CI-friendly, fails if changes needed)
format-check:
julia --project=$(FORMATTER_PROJECT) -e 'using Pkg; Pkg.instantiate(); using JuliaFormatter; @assert format("src/", overwrite=false); @assert format("test/", overwrite=false)'
julia --project=$(FORMATTER_PROJECT) -e 'using Pkg; Pkg.instantiate(); using JuliaFormatter; @assert format(["src/", "test/", "benchmark/"], overwrite=false)'

# Clean build artifacts
clean:
rm -rf docs/build
rm -rf *.jl.cov *.jl.*.cov *.jl.mem
rm -rf *.jl.cov *.jl.*.cov *.jl.mem lcov.info

# Instantiate project dependencies (includes Plots and all other deps). Download what Manifest.toml says.
setup:
Expand Down
26 changes: 23 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -96,10 +96,23 @@ julia -e 'using IJulia; notebook(dir="demos")'
Run the benchmark suite:

```bash
julia --project=. benchmark/benchmarks.jl
make bench
# or
julia benchmark/runbenchmarks.jl
```

This benchmarks sampling, transforms, integrand evaluation, and end-to-end integration across all DD types. Results are saved to `benchmark/results/latest.json`.
This benchmarks sampling, transforms, integrand evaluation, and end-to-end integration across all DD types. Results are saved under `benchmark/results/`. See [`benchmark/README.md`](benchmark/README.md) for the full workflow, comparison scripts, and the Julia-vs-QMCPy accuracy sidecars.

## Repository Layout

Most top-level and source subdirectories now include a local `README.md` describing
their purpose and the files they contain. Useful starting points:

- [`benchmark/README.md`](benchmark/README.md) — standalone benchmarking and comparison tooling
- [`demos/README.md`](demos/README.md) — notebook demos and how to run them
- [`docs/README.md`](docs/README.md) — Documenter build/deploy layout
- [`src/README.md`](src/README.md) — package source tree and component folders
- [`test/README.md`](test/README.md) — unit tests, notebook tests, and coverage commands

## Documentation

Expand All @@ -119,14 +132,21 @@ using QMC
# Unit tests
julia --project=. -e 'using Pkg; Pkg.test()'

# Unit tests with coverage instrumentation
julia --project=. -e 'using Pkg; Pkg.test(coverage=true)'
# or
make coverage

# Demo notebooks
julia --project=. test/run_notebooks.jl

# Build documentation locally
julia --project=docs docs/make.jl
```

See [CI/CD Testing](https://qmcsoftware.github.io/QMC.jl/ci-testing/) for workflow details.
CI uploads LCOV coverage reports to Codecov and stores the generated `lcov.info`
as a workflow artifact. See [`test/README.md`](test/README.md) and
[CI/CD Testing](https://qmcsoftware.github.io/QMC.jl/ci-testing/) for details.

## Citation

Expand Down
34 changes: 21 additions & 13 deletions benchmark/benchmarks.jl
Original file line number Diff line number Diff line change
Expand Up @@ -53,16 +53,14 @@ const SUITE = BenchmarkGroup()
# and Kronecker are pure Julia.
SUITE["gen_samples"] = BenchmarkGroup()
for dim in DIMS, n in SAMPLES
SUITE["gen_samples"]["IIDStdUniform d=$dim n=$n"] =
bench_gen_samples(IIDStdUniform, dim, n)
SUITE["gen_samples"]["IIDStdUniform d=$dim n=$n"] = bench_gen_samples(IIDStdUniform, dim, n)
SUITE["gen_samples"]["Lattice d=$dim n=$n"] =
bench_gen_samples(Lattice, dim, n; randomize=true)
SUITE["gen_samples"]["DigitalNetB2 d=$dim n=$n"] =
bench_gen_samples(DigitalNetB2, dim, n; randomize="LMS_DS")
SUITE["gen_samples"]["Halton d=$dim n=$n"] =
bench_gen_samples(Halton, dim, n; randomize=true)
SUITE["gen_samples"]["Kronecker d=$dim n=$n"] =
bench_gen_samples(Kronecker, dim, n)
SUITE["gen_samples"]["Kronecker d=$dim n=$n"] = bench_gen_samples(Kronecker, dim, n)
end

# 2. Transform (pure Julia: inverse-CDF + covariance factor)
Expand Down Expand Up @@ -200,25 +198,35 @@ end

function _int_cubmcclt_asian()
dd = IIDStdUniform(50; seed=42)
tm = GeometricBrownianMotion(dd; volatility=0.2, start_price=100.0,
interest_rate=0.05, t_final=1.0)
tm = GeometricBrownianMotion(
dd;
volatility=0.2,
start_price=100.0,
interest_rate=0.05,
t_final=1.0,
)
f = FinancialOption(tm; option_type=:asian, strike_price=100.0)
CubMCCLT(f; abs_tol=0.5)
end

function _int_cubqmcnetg_european()
dd = DigitalNetB2(50; seed=42, randomize="LMS_DS")
tm = GeometricBrownianMotion(dd; volatility=0.2, start_price=100.0,
interest_rate=0.05, t_final=1.0)
tm = GeometricBrownianMotion(
dd;
volatility=0.2,
start_price=100.0,
interest_rate=0.05,
t_final=1.0,
)
f = FinancialOption(tm; option_type=:european, strike_price=100.0)
CubQMCNetG(f; abs_tol=0.5)
end

const INTEGRATE_CASES = Pair{String,Function}[
"CubMCCLT Keister" => _int_cubmcclt_keister,
"CubQMCLatticeG Keister" => _int_cubqmclatticeg_keister,
"CubQMCNetG Keister" => _int_cubqmcnetg_keister,
"CubMCCLT AsianOption" => _int_cubmcclt_asian,
const INTEGRATE_CASES = Pair{String, Function}[
"CubMCCLT Keister" => _int_cubmcclt_keister,
"CubQMCLatticeG Keister" => _int_cubqmclatticeg_keister,
"CubQMCNetG Keister" => _int_cubqmcnetg_keister,
"CubMCCLT AsianOption" => _int_cubmcclt_asian,
"CubQMCNetG EuropeanOption" => _int_cubqmcnetg_european,
]

Expand Down
Loading
Loading