diff --git a/.github/workflows/publish-to-test-pypi.yml b/.github/workflows/publish-to-test-pypi.yml index 4ec3372..c4c7e48 100644 --- a/.github/workflows/publish-to-test-pypi.yml +++ b/.github/workflows/publish-to-test-pypi.yml @@ -35,7 +35,7 @@ jobs: with: password: ${{ secrets.TEST_PYPI_API_TOKEN }} repository_url: https://test.pypi.org/legacy/ - + - name: Publish distribution to PyPI if: startsWith(github.ref, 'refs/tags') uses: pypa/gh-action-pypi-publish@release/v1 diff --git a/.github/workflows/test.yml b/.github/workflows/test.yml index 277b93b..3b5a5df 100644 --- a/.github/workflows/test.yml +++ b/.github/workflows/test.yml @@ -55,4 +55,4 @@ jobs: with: env_vars: OS,PYTHON name: codecov-umbrella - fail_ci_if_error: false \ No newline at end of file + fail_ci_if_error: false diff --git a/.gitignore b/.gitignore index 48bf400..8bce1bd 100644 --- a/.gitignore +++ b/.gitignore @@ -160,3 +160,6 @@ cython_debug/ # and can be added to the global gitignore or merged into this file. For a more nuclear # option (not recommended) you can uncomment the following to ignore the entire idea folder. #.idea/ + +# vscode +.vscode/ diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml new file mode 100644 index 0000000..da409e7 --- /dev/null +++ b/.pre-commit-config.yaml @@ -0,0 +1,22 @@ +repos: + - repo: local + hooks: + - id: black + name: black + entry: black + language: system + types: [python] + files: ^pymc_bart/ + - id: pylint + name: pylint + entry: pylint --rcfile=.pylintrc + language: system + types: [python] + files: ^pymc_bart/ + - repo: https://github.com/pre-commit/pre-commit-hooks + rev: v3.2.0 + hooks: + - id: trailing-whitespace + - id: end-of-file-fixer + - id: check-yaml + - id: check-added-large-files diff --git a/.pylintrc b/.pylintrc index 2ae44fa..de9c879 100644 --- a/.pylintrc +++ b/.pylintrc @@ -68,7 +68,7 @@ disable=missing-docstring, bad-continuation, import-error, protected-access - + # Enable the message, report, category or checker with the given id(s). You can diff --git a/README.md b/README.md index cedeb1f..db566dd 100644 --- a/README.md +++ b/README.md @@ -2,7 +2,7 @@ Bayesian Additive Regression Trees for Probabilistic programming with PyMC -PyMC-BART extends [PyMC](https://github.com/pymc-devs/pymc) probabilistic programming framework to be able to define and solve models including a BART random variable. PyMC-BART also includes a few helpers function to aid with the interpretation of those models and perform variable selection. +PyMC-BART extends [PyMC](https://github.com/pymc-devs/pymc) probabilistic programming framework to be able to define and solve models including a BART random variable. PyMC-BART also includes a few helpers function to aid with the interpretation of those models and perform variable selection. ## Installation diff --git a/docs/Makefile b/docs/Makefile index bbe7ec6..c1877fb 100644 --- a/docs/Makefile +++ b/docs/Makefile @@ -23,4 +23,4 @@ local: # Catch-all target: route all unknown targets to Sphinx using the new # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS). %: Makefile - @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) \ No newline at end of file + @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O) diff --git a/docs/api_reference.rst b/docs/api_reference.rst index 558a611..36e6e7d 100644 --- a/docs/api_reference.rst +++ b/docs/api_reference.rst @@ -14,4 +14,3 @@ methods in the current release of PyMC-BART. .. automodule:: pymc_bart :members: BART, PGBART, plot_dependence, plot_variable_importance, predict - diff --git a/docs/index.rst b/docs/index.rst index ec7c403..85a1665 100644 --- a/docs/index.rst +++ b/docs/index.rst @@ -23,7 +23,7 @@ Overview ============ PyMC-BART extends `PyMC `_ probabilistic programming framework to be able to define and solve models including a BART random variable. PyMC-BART also includes a few helpers function to aid with the -interpretation of those models and perform variable selection. +interpretation of those models and perform variable selection. Installation