Skip to content

Commit

Permalink
Merge pull request #561 from legend-exp/cit
Browse files Browse the repository at this point in the history
Update citation-related documentation
  • Loading branch information
gipert authored Feb 28, 2024
2 parents 69d89b0 + d7d3c81 commit 0a756f2
Show file tree
Hide file tree
Showing 11 changed files with 159 additions and 125 deletions.
49 changes: 27 additions & 22 deletions .github/workflows/distribution.yml
Original file line number Diff line number Diff line change
Expand Up @@ -2,42 +2,47 @@ name: distribute

on:
workflow_dispatch:
pull_request:
push:
tags: "v*"
branches:
- main
release:
types:
- published

jobs:
concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

env:
FORCE_COLOR: 3

jobs:
dist:
name: Distribution build
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Build SDist and wheel
run: pipx run build

- uses: actions/upload-artifact@v4
with:
path: dist/*
steps:
- uses: actions/checkout@v4
with:
fetch-depth: 0

- name: Check metadata
run: pipx run twine check dist/*
- uses: hynek/build-and-inspect-python-package@v2

publish:
needs: [dist]
name: Publish to PyPI
environment: pypi
permissions:
id-token: write
runs-on: ubuntu-latest
if: github.event_name == 'release' && github.event.action == 'published'

steps:
- uses: actions/download-artifact@v4
with:
name: artifact
path: dist

- uses: pypa/gh-action-pypi-publish@v1.8.11
with:
password: ${{ secrets.pypi_password }}
- uses: actions/download-artifact@v4
with:
name: Packages
path: dist

- uses: pypa/gh-action-pypi-publish@release/v1
if: github.event_name == 'release' && github.event.action == 'published'
7 changes: 4 additions & 3 deletions .github/workflows/main.yml
Original file line number Diff line number Diff line change
@@ -1,18 +1,19 @@
name: pygama

on:
workflow_dispatch:
pull_request:
push:
branches:
- main
- 'releases/**'
pull_request:
release:
- "releases/**"

concurrency:
group: ${{ github.workflow }}-${{ github.ref }}
cancel-in-progress: true

env:
FORCE_COLOR: 3
TQDM_MININTERVAL: 100

jobs:
Expand Down
1 change: 1 addition & 0 deletions .pre-commit-config.yaml
Original file line number Diff line number Diff line change
Expand Up @@ -70,6 +70,7 @@ repos:
flake8-print,
pep8-naming
]
args: ["--extend-ignore", "E203,E501"]

- repo: https://github.com/kynan/nbstripout
rev: "0.6.1"
Expand Down
4 changes: 2 additions & 2 deletions CITATION.cff
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
cff-version: 1.2.0
title: pygama
doi: FILLME
date-released: 2024-02-01
doi: https://doi.org/10.5281/zenodo.10614246
date-released: 2024-02-03
url: https://github.com/github-linguist/linguist
message: "If you use this software, please cite it as below."
authors:
Expand Down
14 changes: 11 additions & 3 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -12,6 +12,7 @@
[![GitHub pull requests](https://img.shields.io/github/issues-pr/legend-exp/pygama?logo=github)](https://github.com/legend-exp/pygama/pulls)
[![License](https://img.shields.io/github/license/legend-exp/pygama)](https://github.com/legend-exp/pygama/blob/main/LICENSE)
[![Read the Docs](https://img.shields.io/readthedocs/pygama?logo=readthedocs)](https://pygama.readthedocs.io)
[![DOI](https://zenodo.org/badge/DOI/10.5281/zenodo.10614246.svg)](https://zenodo.org/doi/10.5281/zenodo.10614246)

*pygama* is a Python package for:

Expand All @@ -28,7 +29,14 @@

Check out the [online documentation](https://pygama.readthedocs.io).

If you are using this software, consider
[citing](https://zenodo.org/doi/10.5281/zenodo.10614246)!

## Related repositories
- [legend-exp/legend-pydataobj](https://github.com/legend-exp/legend-pydataobj) → LEGEND Python Data Objects
- [legend-exp/legend-daq2lh5](https://github.com/legend-exp/legend-daq2lh5) → Convert digitizer data to LEGEND HDF5
- [legend-exp/dspeed](https://github.com/legend-exp/dspeed) → Fast Digital Signal Processing for particle detector signals in Python

- [legend-exp/legend-pydataobj](https://github.com/legend-exp/legend-pydataobj)
→ LEGEND Python Data Objects
- [legend-exp/legend-daq2lh5](https://github.com/legend-exp/legend-daq2lh5)
→ Convert digitizer data to LEGEND HDF5
- [legend-exp/dspeed](https://github.com/legend-exp/dspeed)
→ Fast Digital Signal Processing for particle detector signals in Python
1 change: 1 addition & 0 deletions docs/source/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -65,5 +65,6 @@ Next steps

Source Code <https://github.com/legend-exp/pygama>
License <https://github.com/legend-exp/pygama/blob/main/LICENSE>
Citation <https://zenodo.org/doi/10.5281/zenodo.10614246>
Changelog <https://github.com/legend-exp/pygama/releases>
developer
113 changes: 110 additions & 3 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,14 +1,121 @@
[build-system]
requires = [
"setuptools>=42.0.0",
"setuptools_scm[toml]>=3.4",
"setuptools>=61.2",
"setuptools_scm[toml]>=7",
]

build-backend = "setuptools.build_meta"

[project]
name = "pygama"
description = "Python package for data processing and analysis"
authors = [
{ name = "The LEGEND collaboration" },
]
maintainers = [
{ name = "The LEGEND collaboration" },
]
readme = "README.md"
classifiers = [
"Development Status :: 4 - Beta",
"Intended Audience :: Developers",
"Intended Audience :: Science/Research",
"License :: OSI Approved :: GNU General Public License v3 (GPLv3)",
"Operating System :: MacOS",
"Operating System :: POSIX",
"Operating System :: Unix",
"Programming Language :: Python",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3 :: Only",
"Topic :: Scientific/Engineering",
]
requires-python = ">=3.9"
dependencies = [
"colorlog",
"dspeed>=1.3.0a4",
"h5py>=3.2",
"iminuit",
"legend-daq2lh5>=1.2.0a1",
"legend-pydataobj>=1.5.0a5",
"matplotlib",
"numba!=0.53.*,!=0.54.*,!=0.57",
"numpy>=1.21",
"pandas>=1.4.4",
"pint",
"scikit-learn",
"scipy>=1.0.1",
"tables",
"tqdm>=4.27",
]
dynamic = [
"version",
]

[project.urls]
Homepage = "https://github.com/legend-exp/pygama"
"Bug Tracker" = "https://github.com/legend-exp/pygama/issues"
Discussions = "https://github.com/legend-exp/pygama/discussions"
Changelog = "https://github.com/legend-exp/pygama/releases"

[tool.setuptools_scm]
write_to = "src/pygama/_version.py"

[project.optional-dependencies]
all = [
"pygama[docs,test]",
]
docs = [
"furo",
"jupyter",
"myst-parser",
"nbsphinx",
"sphinx",
"sphinx-copybutton",
"sphinx-inline-tabs",
]
test = [
"pre-commit",
"pylegendtestdata",
"pytest>=6.0",
"pytest-cov",
]

[project.scripts]
pygama = "pygama.cli:pygama_cli"

[tool.setuptools]
include-package-data = true
zip-safe = false
license-files = [
"LICENSE",
]

[tool.setuptools.package-dir]
"" = "src"

[tool.setuptools.packages.find]
where = [
"src",
]
namespaces = false

[tool.setuptools.package-data]
"*" = [
"*.json",
]

[tool.coverage]
run.source = ["pygama"]
report.exclude_also = [
'\.\.\.',
'if typing.TYPE_CHECKING:',
]

[tool.flake8]
extend-ignore = "E203, E501"

[tool.codespell]
ignore-words-list = "hist, gaus, nd, ans, crate, nin, puls, spms, fom"

[tool.pytest.ini_options]
minversion = "6.0"
addopts = ["-ra", "--showlocals", "--strict-markers", "--strict-config"]
Expand Down
86 changes: 0 additions & 86 deletions setup.cfg

This file was deleted.

4 changes: 0 additions & 4 deletions setup.py

This file was deleted.

2 changes: 1 addition & 1 deletion src/pygama/math/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,3 @@
"""
Subpackage description
Statistical and mathematical utilities.
"""
3 changes: 2 additions & 1 deletion src/pygama/pargen/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,4 @@
"""
Subpackage description
Utilities to generate and optimize parameters of interest from data (e.g.
calibration routines)
"""

0 comments on commit 0a756f2

Please sign in to comment.