Skip to content

Commit

Permalink
Move options from setup.cfg to pyproject.toml
Browse files Browse the repository at this point in the history
  • Loading branch information
maxnoe committed Feb 21, 2024
1 parent daf12f0 commit ac56396
Show file tree
Hide file tree
Showing 2 changed files with 125 additions and 147 deletions.
125 changes: 125 additions & 0 deletions pyproject.toml
Original file line number Diff line number Diff line change
Expand Up @@ -2,6 +2,128 @@
requires = ["setuptools>=64", "setuptools_scm[toml]>=8"]
build-backend = "setuptools.build_meta"

[project]
name = "ctapipe"
description = "Event reconstruction framework for Imaging Atmospheric Cherenkov Telescopes developed for CTAO."
readme = "README.rst"
authors = [
{name = "ctapipe developers"},
]
maintainers = [
{name = "Karl Kosack", email = "[email protected]"},
{name = "Maximilian Linhoff", email = "[email protected]"},
]
license = {text = "BSD-3-Clause"}
classifiers = [
"Intended Audience :: Science/Research",
"License :: OSI Approved :: BSD License",
"Programming Language :: Python :: 3",
"Programming Language :: Python :: 3.9",
"Programming Language :: Python :: 3.10",
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: Implementation :: CPython",
"Topic :: Scientific/Engineering :: Astronomy",
"Development Status :: 3 - Alpha",
]

dynamic = ["version"]
requires-python = ">=3.9"

dependencies = [
"astropy >=5.3,<7.0.0a0",
"bokeh ~=2.0",
"docutils",
"eventio >=1.9.1, <2.0.0a0",
"iminuit >=2",
"importlib_metadata; python_version < '3.10'",
"joblib",
"matplotlib ~=3.0",
"numba >=0.56",
"numpy ~=1.16",
"psutil",
"pyyaml >=5.1",
"requests",
"scikit-learn <1.4",
"scipy ~=1.2",
"tables ~=3.4",
"tqdm >=4.32",
"traitlets ~=5.6",
"zstandard",
]

[project.optional-dependencies]
tests = [
"h5py",
"pandas",
"pytest >= 7.0",
"pytest-cov",
"pytest-xdist",
"pytest_astropy_header",
"tomli",
]

docs = [
"sphinx",
"pydata_sphinx_theme",
"sphinx_automodapi",
"nbsphinx",
"numpydoc",
"sphinx-design",
"sphinx-gallery",
"jupyter",
"notebook",
"graphviz",
"pandas",
"ipython",
"ffmpeg-python",
"pypandoc",
]

dev = [
"pre-commit",
"setuptools_scm[toml]",
]

all = [
# self-reference with all extras to simplify
"ctapipe[tests,docs,dev]",
]

[project.scripts]
ctapipe-info = "ctapipe.tools.info:main"
ctapipe-dump-instrument = "ctapipe.tools.dump_instrument:main"
ctapipe-display-dl1 = "ctapipe.tools.display_dl1:main"
ctapipe-process = "ctapipe.tools.process:main"
ctapipe-merge = "ctapipe.tools.merge:main"
ctapipe-fileinfo = "ctapipe.tools.fileinfo:main"
ctapipe-quickstart = "ctapipe.tools.quickstart:main"
ctapipe-train-energy-regressor = "ctapipe.tools.train_energy_regressor:main"
ctapipe-train-particle-classifier = "ctapipe.tools.train_particle_classifier:main"
ctapipe-train-disp-reconstructor = "ctapipe.tools.train_disp_reconstructor:main"
ctapipe-apply-models = "ctapipe.tools.apply_models:main"

[project.entry-points.ctapipe_io]
HDF5EventSource = "ctapipe.io.hdf5eventsource:HDF5EventSource"
SimTelEventSource = "ctapipe.io.simteleventsource:SimTelEventSource"


[project.entry-points.ctapipe_reco]
DispReconstructor = "ctapipe.reco.sklearn.DispReconstructor"
HillasIntersection = "ctapipe.reco.hillas_intersection.HillasIntersection"
HillasReconstructor = "ctapipe.reco.hillas_reconstructor.HillasReconstructor"
EnergyRegressor = "ctapipe.reco.sklearn.EnergyRegressor"
ParticleClassifier = "ctapipe.reco.sklearn.ParticleClassifier"

[project.urls]
repository = "https://github.com/cta-observatory/ctapipe/"
documentation = "https://ctapipe.readthedocs.io/"


[tool.setuptools.packages.find]
where = ["src"]
exclude = ["ctapipe._dev_version"]

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

Expand All @@ -28,18 +150,21 @@ minversion = "7"
testpaths = ["src"]
log_cli_level = "INFO"
xfail_strict = true
astropy_header = true

# print summar of failed tests, force errors if settings are misspelled
addopts = ["-ra", "--strict-config", "--strict-markers"]

filterwarnings = [
"error::astropy.utils.exceptions.AstropyDeprecationWarning",
"error::ctapipe.utils.deprecation.CTAPipeDeprecationWarning",
"ignore:`np.MachAr` is deprecated:DeprecationWarning",
]
norecursedirs = [
".git",
"_build",
"auto_examples",
"build",
]

[tool.towncrier]
Expand Down
147 changes: 0 additions & 147 deletions setup.cfg

This file was deleted.

0 comments on commit ac56396

Please sign in to comment.