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/documentation.yml
Original file line number Diff line number Diff line change
Expand Up @@ -26,12 +26,12 @@ jobs:
pip install --find-links dist esat
sphinx-apidoc -o docs esat
sphinx-apidoc -o docs eval
sphinx-build . _build
sphinx-build -b html . docs/_build/html
- name: Deploy to GitHub Pages
uses: peaceiris/actions-gh-pages@v3
uses: peaceiris/actions-gh-pages@v4
if: ${{ github.event_name == 'push' && github.ref == 'refs/heads/main' }}
with:
publish_branch: gh-pages
github_token: ${{ secrets.GITHUB_TOKEN }}
publish_dir: _build
publish_dir: docs/_build/html
force_orphan: true
72 changes: 27 additions & 45 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -10,40 +10,11 @@ env:
CIBW_BUILD: "cp310-* cp311-* cp312-*"

jobs:
# build_wheels:
# name: Build wheels on ${{ matrix.os }}
# runs-on: ${{ matrix.os }}
# strategy:
# matrix:
# os: [ ubuntu-latest, windows-latest, macos-13, macos-latest ]
# steps:
# - uses: actions/checkout@v4
# - uses: actions/setup-python@v5
# with:
# python-version: "3.12"
# - name: Install cibuildwheel
# run: python -m pip install cibuildwheel==2.23.3
# - name: Install setuptools
# shell: bash
# run: |
# python -m pip install --upgrade pip
# curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain=stable
# echo "PATH=${PATH}:${HOME}/.cargo/bin" >> $GITHUB_ENV
# rustc --version
# python -m pip install build setuptools setuptools-rust
# - name: Build wheels
# run: python -m cibuildwheel --output-dir wheelhouse
# - uses: actions/upload-artifact@v4
# with:
# name: esat-wheels-${{ matrix.os }}-py${{matrix.python_version}}
# path: ./wheelhouse/*.whl

build_wheels:
name: Build wheels on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
# macos-13 is an intel runner, macos-14 is apple silicon
os: [ubuntu-latest, macos-13, macos-14]
python_version: ["3.10", "3.11", "3.12"]
steps:
Expand All @@ -52,23 +23,28 @@ jobs:
with:
python-version: ${{ matrix.python_version }}
- name: Install setuptools
run: |
python -m pip install --upgrade pip
curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain=stable
echo "PATH=${PATH}:${HOME}/.cargo/bin" >> "$GITHUB_ENV"
rustc --version
python -m pip install build setuptools setuptools-rust
- name: Build wheels with cibuildwheel
run: |
python -m pip install --upgrade pip
curl https://sh.rustup.rs -sSf | sh -s -- -y --default-toolchain=stable
echo "PATH=${PATH}:${HOME}/.cargo/bin" >> "$GITHUB_ENV"
rustc --version
python -m pip install build setuptools setuptools-rust
- name: Build CPU wheels with cibuildwheel
run: |
python -m pip install cibuildwheel==2.22.0
python -m cibuildwheel --output-dir wheelhouse
# - name: Build wheels
# run:
# python -m build --outdir wheelhouse
- uses: actions/upload-artifact@v4
with:
name: esat-wheels-${{ matrix.os }}-py${{matrix.python_version}}
name: esat-wheels-cpu-${{ matrix.os }}-py${{ matrix.python_version }}
path: ./wheelhouse/*.whl
- name: Build GPU wheels with cibuildwheel
run: |
rm -rf wheelhouse
python -m pip install cibuildwheel==2.22.0
python -m cibuildwheel --output-dir wheelhouse
- uses: actions/upload-artifact@v4
with:
name: esat-wheels-gpu-${{ matrix.os }}-py${{ matrix.python_version }}
path: ./wheelhouse/*.whl

build_windows_wheel:
Expand All @@ -89,14 +65,20 @@ jobs:
rustup target add aarch64-pc-windows-msvc i686-pc-windows-msvc x86_64-pc-windows-msvc
echo "${HOME}/.cargo/bin" | Out-File -FilePath $env:GITHUB_PATH -Encoding utf8 -Append
python -m pip install build setuptools setuptools-rust
- name: Build wheels with cibuildwheel
- name: Build CPU wheels with cibuildwheel
run: |
python -m pip install --upgrade pip
python -m pip install cibuildwheel==2.22.0
python -m cibuildwheel --output-dir wheelhouse
# - name: Build wheels
# run: python -m build --outdir wheelhouse
- uses: actions/upload-artifact@v4
with:
name: esat-wheels-windows-py${{matrix.python_version}}
name: esat-wheels-cpu-windows-py${{ matrix.python_version }}
path: ./wheelhouse/*.whl
- name: Build GPU wheels with cibuildwheel
run: |
Remove-Item -Recurse -Force wheelhouse
python -m pip install cibuildwheel==2.22.0
python -m cibuildwheel --output-dir wheelhouse
- uses: actions/upload-artifact@v4
with:
name: esat-wheels-gpu-windows-py${{ matrix.python_version }}
path: ./wheelhouse/*.whl
3 changes: 2 additions & 1 deletion .gitignore
Original file line number Diff line number Diff line change
Expand Up @@ -30,6 +30,7 @@ docs/_downloads/
docs/_sources/
docs/_static/
docs/html/
build/

notebooks/.ipynb_checkpoints/
notebooks/old/.ipynb_checkpoints/
Expand All @@ -38,4 +39,4 @@ notebooks/old/.ipynb_checkpoints/
*.dat
profile.html
profile.json
data/test_output/
data/test_output/
18 changes: 11 additions & 7 deletions Cargo.toml
Original file line number Diff line number Diff line change
Expand Up @@ -14,13 +14,15 @@ path = "rust/lib.rs"
crate-type = ["cdylib"]

[dependencies]
numpy = "0.20.0"
nalgebra = {version="0.32.4", features = ["rayon"]}
ndarray = "0.15.6"
rayon = "1.9.0"
pyo3 = "0.20.3"
indicatif = "0.17"
console = "0.15.8"
numpy = "0.25.0"
nalgebra = "0.33.2"
ndarray = "0.16.1"
pyo3 = { version = "0.25.1", features = ["extension-module"] }
indicatif = "0.18.0"
console = "0.16.0"
# GPU support
candle-core = "0.9.1"
#candle-core = { version = "0.9.1", features = ["cuda"] }

[features]
extension-module = ["pyo3/extension-module", "pyo3/generate-import-lib"]
Expand All @@ -33,3 +35,5 @@ debug = false
[profile.release]
opt-level = 3
debug = false


1 change: 1 addition & 0 deletions doc-requirements.txt
Original file line number Diff line number Diff line change
Expand Up @@ -7,6 +7,7 @@ plotly==6.0.1
psutil==7.0.0
scipy==1.15.2
sphinx==8.2.3
sphinx-book-theme==1.1.4
sphinx-click==6.0.0
sphinx-rtd-theme==3.0.2
tabulate==0.9.0
Expand Down
Binary file modified docs/doctrees/README.doctree
Binary file not shown.
Binary file modified docs/doctrees/docs/cli.doctree
Binary file not shown.
Binary file modified docs/doctrees/docs/esat.cli.doctree
Binary file not shown.
Binary file modified docs/doctrees/docs/esat.data.doctree
Binary file not shown.
Binary file modified docs/doctrees/docs/esat.doctree
Binary file not shown.
Binary file modified docs/doctrees/docs/esat.error.doctree
Binary file not shown.
Binary file modified docs/doctrees/docs/esat.model.doctree
Binary file not shown.
Binary file modified docs/doctrees/docs/esat.rotational.doctree
Binary file not shown.
Binary file modified docs/doctrees/docs/eval.doctree
Binary file not shown.
Binary file modified docs/doctrees/docs/modules.doctree
Binary file not shown.
Binary file modified docs/doctrees/environment.pickle
Binary file not shown.
Binary file modified docs/doctrees/index.doctree
Binary file not shown.
4 changes: 2 additions & 2 deletions docs/html/.buildinfo
Original file line number Diff line number Diff line change
@@ -1,4 +1,4 @@
# Sphinx build info version 1
# This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
config: 08826985b7a8d85c7fec8fc3270a1630
# This file records the configuration used when building these files. When it is not found, a full rebuild will be done.
config: f688b6899233aa9a295b9d35a66d85ad
tags: 645f666f9bcd5a90fca523b33c5a78b7
34 changes: 20 additions & 14 deletions docs/html/README.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="viewport" content="width=device-width, initial-scale=1" />

<title>Environmental Source Apportionment Toolkit (ESAT) &#8212; Environmental Source Apportionment Toolkit (ESAT) 2024.0.2 documentation</title>
<title>Environmental Source Apportionment Toolkit (ESAT) &#8212; Environmental Source Apportionment Toolkit (ESAT) 2025.0.2 documentation</title>



Expand All @@ -28,16 +28,16 @@
<link rel="preload" as="font" type="font/woff2" crossorigin href="_static/vendor/fontawesome/6.5.2/webfonts/fa-brands-400.woff2" />
<link rel="preload" as="font" type="font/woff2" crossorigin href="_static/vendor/fontawesome/6.5.2/webfonts/fa-regular-400.woff2" />

<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=a746c00c" />
<link rel="stylesheet" type="text/css" href="_static/styles/sphinx-book-theme.css?v=a3416100" />
<link rel="stylesheet" type="text/css" href="_static/pygments.css?v=8f2a1f02" />
<link rel="stylesheet" type="text/css" href="_static/styles/sphinx-book-theme.css?v=eba8b062" />

<!-- Pre-loaded scripts that we'll load fully later -->
<link rel="preload" as="script" href="_static/scripts/bootstrap.js?digest=dfe6caa3a7d634c4db9b" />
<link rel="preload" as="script" href="_static/scripts/pydata-sphinx-theme.js?digest=dfe6caa3a7d634c4db9b" />
<script src="_static/vendor/fontawesome/6.5.2/js/all.min.js?digest=dfe6caa3a7d634c4db9b"></script>

<script src="_static/documentation_options.js?v=1300d73e"></script>
<script src="_static/doctools.js?v=9a2dae69"></script>
<script src="_static/documentation_options.js?v=b7785327"></script>
<script src="_static/doctools.js?v=9bcbadda"></script>
<script src="_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="_static/scripts/sphinx-book-theme.js?v=887ef09a"></script>
<script>DOCUMENTATION_OPTIONS.pagename = 'README';</script>
Expand Down Expand Up @@ -324,7 +324,7 @@ <h2> Contents </h2>

<section id="environmental-source-apportionment-toolkit-esat">
<h1>Environmental Source Apportionment Toolkit (ESAT)<a class="headerlink" href="#environmental-source-apportionment-toolkit-esat" title="Link to this heading">#</a></h1>
<p>Last Update: 08-15-2024</p>
<p>Last Update: 04-16-2025</p>
<section id="table-of-contents">
<h2>Table of Contents<a class="headerlink" href="#table-of-contents" title="Link to this heading">#</a></h2>
<ul class="simple">
Expand Down Expand Up @@ -367,26 +367,32 @@ <h2>Description<a class="headerlink" href="#description" title="Link to this hea
factorization (NMF), both of which have been written in Rust and contained within the python package. A collection of
data processing and visualization features are included for data and model analytics. The ESAT package includes a
synthetic data generator and comparison tools to evaluate ESAT model outputs.</p>
<p>The ESAT python package has been published with the Journal of Open Source Software (JOSS):</p>
<p><a class="reference external" href="https://doi.org/10.21105/joss.07316"><img alt="DOI" src="https://joss.theoj.org/papers/10.21105/joss.07316/status.svg" /></a></p>
</section>
<section id="quick-start">
<h2>Quick Start<a class="headerlink" href="#quick-start" title="Link to this heading">#</a></h2>
<p>ESAT supports python version 3.10, 3.11, and 3.12. As the python package contains compiled code there are OS and python
specific versions, supporting Mac Intel, Mac M1+, Linux, and Windows.</p>
<section id="documentation">
<h3>Documentation<a class="headerlink" href="#documentation" title="Link to this heading">#</a></h3>
<p>The Python API and CLI documentation can be found at the Github ESAT IO site: <a class="reference external" href="https://quanted.github.io/esat/">https://quanted.github.io/esat/</a></p>
<p>The Python API and CLI documentation can be found at the GitHub ESAT IO site: <a class="reference external" href="https://quanted.github.io/esat/">https://quanted.github.io/esat/</a></p>
</section>
<section id="installation">
<h3>Installation<a class="headerlink" href="#installation" title="Link to this heading">#</a></h3>
<p>The ESAT python package contains all compiled code and required dependencies and can be installed using pip</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>pip<span class="w"> </span>install<span class="w"> </span>esat-VERSION-OS.whl
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>pip<span class="w"> </span>install<span class="w"> </span>esat
</pre></div>
</div>
<p>where the <i>VERSION</i> is the code version, such as <i>2024.1.0</i>, and <i>OS</i> is operating system targeted
compiled version, such as <i>cp312-cp312-win_amd64</i>. If an error message appears during installation stating that the
package is not supported check that the correct OS and python version are being installed for that system.</p>
<p>When the package becomes available on pypi, the package will be able to be installed with</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>pip<span class="w"> </span>install<span class="w"> </span>esat
<p>which will install the latest version that supports and is available for your python version and OS.</p>
<p>Development versions of ESAT can be found on the GitHub actions page, for logged-in users,
under the ‘Build and Publish Wheel’ workflow. The latest version of the package will be available as an artifact for
download in the ‘Artifacts’ section of the completed workflow. There wheel files can be found for specific versions
of python and supported operating systems.</p>
<p>If an error message appears during installation stating that the
package is not supported check that the correct OS and python version are being installed for that system. The python
wheels can be installed directly using</p>
<div class="highlight-bash notranslate"><div class="highlight"><pre><span></span>pip<span class="w"> </span>install<span class="w"> </span>&lt;wheel<span class="w"> </span>file<span class="w"> </span>name&gt;
</pre></div>
</div>
<p>The esat python package is recommended to be installed in its own dedicated python virtual environment or conda environment.</p>
Expand Down Expand Up @@ -619,7 +625,7 @@ <h2>Disclaimer<a class="headerlink" href="#disclaimer" title="Link to this headi

<p class="copyright">

© Copyright 2024, EPA.
© Copyright 2025, EPA.
<br/>

</p>
Expand Down
16 changes: 8 additions & 8 deletions docs/html/docs/cli.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="viewport" content="width=device-width, initial-scale=1" />

<title>Command Line Interface &#8212; Environmental Source Apportionment Toolkit (ESAT) 2024.0.2 documentation</title>
<title>Command Line Interface &#8212; Environmental Source Apportionment Toolkit (ESAT) 2025.0.2 documentation</title>



Expand All @@ -28,16 +28,16 @@
<link rel="preload" as="font" type="font/woff2" crossorigin href="../_static/vendor/fontawesome/6.5.2/webfonts/fa-brands-400.woff2" />
<link rel="preload" as="font" type="font/woff2" crossorigin href="../_static/vendor/fontawesome/6.5.2/webfonts/fa-regular-400.woff2" />

<link rel="stylesheet" type="text/css" href="../_static/pygments.css?v=a746c00c" />
<link rel="stylesheet" type="text/css" href="../_static/styles/sphinx-book-theme.css?v=a3416100" />
<link rel="stylesheet" type="text/css" href="../_static/pygments.css?v=8f2a1f02" />
<link rel="stylesheet" type="text/css" href="../_static/styles/sphinx-book-theme.css?v=eba8b062" />

<!-- Pre-loaded scripts that we'll load fully later -->
<link rel="preload" as="script" href="../_static/scripts/bootstrap.js?digest=dfe6caa3a7d634c4db9b" />
<link rel="preload" as="script" href="../_static/scripts/pydata-sphinx-theme.js?digest=dfe6caa3a7d634c4db9b" />
<script src="../_static/vendor/fontawesome/6.5.2/js/all.min.js?digest=dfe6caa3a7d634c4db9b"></script>

<script src="../_static/documentation_options.js?v=1300d73e"></script>
<script src="../_static/doctools.js?v=9a2dae69"></script>
<script src="../_static/documentation_options.js?v=b7785327"></script>
<script src="../_static/doctools.js?v=9bcbadda"></script>
<script src="../_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="../_static/scripts/sphinx-book-theme.js?v=887ef09a"></script>
<script>DOCUMENTATION_OPTIONS.pagename = 'docs/cli';</script>
Expand Down Expand Up @@ -131,7 +131,7 @@



<p class="title logo__title">Environmental Source Apportionment Toolkit (ESAT) 2024.0.2 documentation</p>
<p class="title logo__title">Environmental Source Apportionment Toolkit (ESAT) 2025.0.2 documentation</p>

</a></div>
<div class="sidebar-primary-item">
Expand Down Expand Up @@ -629,7 +629,7 @@ <h4>plot-q<a class="headerlink" href="#esat-analysis-constrained-plot-q" title="
<dd><p>Plot the loss value for qtype: True, Robust, Aux</p>
<dl class="field-list simple">
<dt class="field-odd">Default<span class="colon">:</span></dt>
<dd class="field-odd"><p><code class="docutils literal notranslate"><span class="pre">Aux</span></code></p>
<dd class="field-odd"><p><code class="docutils literal notranslate"><span class="pre">'Aux'</span></code></p>
</dd>
</dl>
</dd></dl>
Expand Down Expand Up @@ -1618,7 +1618,7 @@ <h4>setup<a class="headerlink" href="#esat-simulator-setup" title="Link to this

<p class="copyright">

© Copyright 2024, EPA.
© Copyright 2025, EPA.
<br/>

</p>
Expand Down
14 changes: 7 additions & 7 deletions docs/html/docs/esat.cli.html
Original file line number Diff line number Diff line change
Expand Up @@ -8,7 +8,7 @@
<meta charset="utf-8" />
<meta name="viewport" content="width=device-width, initial-scale=1.0" /><meta name="viewport" content="width=device-width, initial-scale=1" />

<title>esat.cli package &#8212; Environmental Source Apportionment Toolkit (ESAT) 2024.0.2 documentation</title>
<title>esat.cli package &#8212; Environmental Source Apportionment Toolkit (ESAT) 2025.0.2 documentation</title>



Expand All @@ -28,16 +28,16 @@
<link rel="preload" as="font" type="font/woff2" crossorigin href="../_static/vendor/fontawesome/6.5.2/webfonts/fa-brands-400.woff2" />
<link rel="preload" as="font" type="font/woff2" crossorigin href="../_static/vendor/fontawesome/6.5.2/webfonts/fa-regular-400.woff2" />

<link rel="stylesheet" type="text/css" href="../_static/pygments.css?v=a746c00c" />
<link rel="stylesheet" type="text/css" href="../_static/styles/sphinx-book-theme.css?v=a3416100" />
<link rel="stylesheet" type="text/css" href="../_static/pygments.css?v=8f2a1f02" />
<link rel="stylesheet" type="text/css" href="../_static/styles/sphinx-book-theme.css?v=eba8b062" />

<!-- Pre-loaded scripts that we'll load fully later -->
<link rel="preload" as="script" href="../_static/scripts/bootstrap.js?digest=dfe6caa3a7d634c4db9b" />
<link rel="preload" as="script" href="../_static/scripts/pydata-sphinx-theme.js?digest=dfe6caa3a7d634c4db9b" />
<script src="../_static/vendor/fontawesome/6.5.2/js/all.min.js?digest=dfe6caa3a7d634c4db9b"></script>

<script src="../_static/documentation_options.js?v=1300d73e"></script>
<script src="../_static/doctools.js?v=9a2dae69"></script>
<script src="../_static/documentation_options.js?v=b7785327"></script>
<script src="../_static/doctools.js?v=9bcbadda"></script>
<script src="../_static/sphinx_highlight.js?v=dc90522c"></script>
<script src="../_static/scripts/sphinx-book-theme.js?v=887ef09a"></script>
<script>DOCUMENTATION_OPTIONS.pagename = 'docs/esat.cli';</script>
Expand Down Expand Up @@ -132,7 +132,7 @@



<p class="title logo__title">Environmental Source Apportionment Toolkit (ESAT) 2024.0.2 documentation</p>
<p class="title logo__title">Environmental Source Apportionment Toolkit (ESAT) 2025.0.2 documentation</p>

</a></div>
<div class="sidebar-primary-item">
Expand Down Expand Up @@ -469,7 +469,7 @@ <h2>Submodules<a class="headerlink" href="#submodules" title="Link to this headi

<p class="copyright">

© Copyright 2024, EPA.
© Copyright 2025, EPA.
<br/>

</p>
Expand Down
Loading
Loading