-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
- Loading branch information
Showing
13 changed files
with
695 additions
and
108 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,131 @@ | ||
name: package | ||
|
||
on: | ||
push: | ||
branches: | ||
- master | ||
- develop | ||
tags: | ||
- 'v*.*' | ||
pull_request: | ||
branches: | ||
- master | ||
- develop | ||
|
||
jobs: | ||
test: | ||
runs-on: ubuntu-latest | ||
container: python:3.7 | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Install | ||
run: python -m pip install .[test] | ||
- name: Test | ||
run: python -m unittest -v | ||
|
||
sphinx: | ||
runs-on: ubuntu-latest | ||
container: sphinxdoc/sphinx-latexpdf | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
persist-credentials: false | ||
- name: Install | ||
run: python -m pip install .[docs] | ||
- name: Build HTML | ||
run: make html | ||
working-directory: docs | ||
- name: Upload HTML | ||
uses: actions/upload-artifact@v1 | ||
with: | ||
name: pages | ||
path: docs/build/html | ||
- name: Build latex | ||
run: make latexpdf | ||
working-directory: docs | ||
- name: Upload pdf | ||
uses: actions/upload-artifact@v1 | ||
with: | ||
name: manual | ||
path: docs/build/latex/spectralanalysisformodalparameterlinearestimate.pdf | ||
|
||
release-create: | ||
if: ${{ startsWith( github.ref , 'refs/tags/' ) }} | ||
runs-on: ubuntu-latest | ||
needs: [test, sphinx] | ||
outputs: | ||
upload_url: ${{ steps.create_release.outputs.upload_url }} | ||
version: ${{ steps.get_version.outputs.VERSION }} | ||
steps: | ||
- name: Create Release | ||
id: create_release | ||
uses: actions/create-release@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
tag_name: ${{ github.ref }} | ||
release_name: ${{ github.ref }} | ||
draft: false | ||
prerelease: ${{ contains( github.ref , 'dev' ) }} | ||
- name: Get the version | ||
id: get_version | ||
run: echo ::set-output name=VERSION::${GITHUB_REF/refs\/tags\//} | ||
|
||
manual-upload: | ||
runs-on: ubuntu-latest | ||
needs: [sphinx, release-create] | ||
steps: | ||
- name: Download artifact | ||
uses: actions/download-artifact@v2 | ||
with: | ||
name: manual | ||
path: manual | ||
- name: Upload artifact | ||
id: upload-manual | ||
uses: actions/upload-release-asset@v1 | ||
env: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
with: | ||
upload_url: ${{ needs.release-create.outputs.upload_url }} | ||
asset_path: ./manual/spectralanalysisformodalparameterlinearestimate.pdf | ||
asset_name: SAMPLE_${{ needs.release-create.outputs.version }}.pdf | ||
asset_content_type: application/pdf | ||
|
||
pages-deploy: | ||
runs-on: ubuntu-latest | ||
needs: [sphinx, release-create] | ||
steps: | ||
- uses: actions/checkout@v2 | ||
with: | ||
persist-credentials: false | ||
- name: Download artifacts | ||
uses: actions/download-artifact@v2 | ||
with: | ||
name: pages | ||
path: pages | ||
- name: No Jekyll in pages | ||
run: touch pages/.nojekyll | ||
- name: Deploy pages | ||
uses: JamesIves/github-pages-deploy-action@releases/v3 | ||
with: | ||
GITHUB_TOKEN: ${{ secrets.GITHUB_TOKEN }} | ||
BRANCH: gh-pages | ||
FOLDER: pages | ||
|
||
pypi-upload: | ||
runs-on: ubuntu-latest | ||
container: python:3.7 | ||
needs: release-create | ||
steps: | ||
- uses: actions/checkout@v2 | ||
- name: Build | ||
run: python setup.py sdist | ||
- name: Install Twine | ||
run: python -m pip install twine | ||
- name: Upload | ||
run: python -m twine upload --verbose dist/* | ||
env: | ||
TWINE_USERNAME: ${{ secrets.TWINE_USERNAME }} | ||
TWINE_PASSWORD: ${{ secrets.TWINE_PASSWORD }} | ||
TWINE_REPOSITORY: ${{ secrets.TWINE_REPOSITORY }} | ||
TWINE_NON_INTERACTIVE: 1 |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -0,0 +1,7 @@ | ||
# Interactive notebooks | ||
Interactive notebooks to demonstrate SAMPLE | ||
|
||
- [SAMPLE](https://colab.research.google.com/github/LIMUNIMI/SAMPLE/blob/master/notebooks/SAMPLE.ipynb): | ||
a walkthrough to explain the method's concept | ||
- [SDT](https://colab.research.google.com/github/LIMUNIMI/SAMPLE/blob/master/notebooks/SDT.ipynb): | ||
a step-by-step guide to using SAMPLE for estimating parameters of SDT's `modal` objects |
Oops, something went wrong.