Skip to content

default jastrow

default jastrow #544

Workflow file for this run

name: build
on: [push]
jobs:
build:
name: build and test
runs-on: ubuntu-latest
strategy:
fail-fast: false
matrix:
version: [3.8]
steps:
- name: Cancel Previous Runs
uses: styfle/cancel-workflow-action@0.12.0
with:
access_token: ${{ github.token }}
- uses: actions/checkout@v4
- name: Setup conda
uses: s-weigand/setup-conda@v1
with:
update-conda: true
python-version: ${{ matrix.version }}
conda-channels: anaconda
- name: Install essential
run: |
sudo apt update
sudo apt install build-essential pandoc
- name: Install conda packages
run: |
conda install -c anaconda cmake
conda install rdkit mpi4py h5py pytorch==2.0.0 torchvision==0.15.0 cpuonly -c pytorch -c conda-forge
conda install -c conda-forge libstdcxx-ng
conda install -c anaconda gxx_linux-64
- name: Install the package
run: python -m pip install .[test,hpc,doc]
env:
CONDA_PREFIX: /usr/share/miniconda
# - name: Test with multithreading
# env:
# CONDA_PREFIX: /usr/share/miniconda
# run: mpirun -np 2 coverage run -m pytest tests_hvd
- name: Test with single thread
env:
CONDA_PREFIX: /usr/share/miniconda
run: coverage run -m pytest tests
- name: Combine all coverage results
run: coverage combine
- run: coverage report
- name: Coveralls Parallel
run: coveralls --service=github
env:
GITHUB_TOKEN: ${{ secrets.github_token }}
COVERALLS_FLAG_NAME: python-${{ matrix.version }}
COVERALLS_PARALLEL: true
# Standard drop-in approach that should work for most people.
- uses: ammaraskar/sphinx-action@master
with:
docs-folder: "docs/"
# Great extra actions to compose with:
# Create an artifact of the html output.
- uses: actions/upload-artifact@v1
with:
name: DocumentationHTML
path: docs/_build/html/
finish:
needs: build
runs-on: ubuntu-latest
steps:
- name: Coveralls Finished
uses: coverallsapp/github-action@master
with:
github-token: ${{ secrets.github_token }}
parallel-finished: true
# Publish built docs to gh-pages branch.
# ===============================
- name: Commit documentation changes
run: |
git clone https://github.com/NLESC-JCER/QMCTorch.git --branch gh-pages --single-branch gh-pages
cp -r docs/_build/html/* gh-pages/
cd gh-pages
touch .nojekyll
git config --local user.email "action@github.com"
git config --local user.name "GitHub Action"
git add .
git commit -m "Update documentation" -a || true
# The above command will fail if no changes were present, so we ignore
# that.
- name: Push changes
uses: ad-m/github-push-action@master
with:
branch: gh-pages
directory: gh-pages
github_token: ${{ secrets.GITHUB_TOKEN }}