Skip to content

Commit 5d0d3ae

Browse files
Merge pull request #1 from gsd-authors/hatch
Switch hatch
2 parents 5d776a3 + 5b332ca commit 5d0d3ae

File tree

2 files changed

+31
-21
lines changed

2 files changed

+31
-21
lines changed

pyproject.toml

Lines changed: 27 additions & 14 deletions
Original file line numberDiff line numberDiff line change
@@ -1,9 +1,13 @@
1-
[tool.poetry]
1+
[build-system]
2+
requires = ["hatchling"]
3+
build-backend = "hatchling.build"
4+
5+
[project]
26
name = "ref_gsd"
3-
version = "0.0.2"
7+
dynamic = ["version"]
48
description = "Reference implementation of generalised score distribution in python"
5-
authors = ["Krzysztof Rusek <krusek@agh.edu.pl>"]
6-
license = "Apache License 2.0"
9+
authors = [{ name = "Krzysztof Rusek", email = "krussek@gmail.com" }]
10+
license = {file = "LICENSE"}
711
readme = "README.md"
812

913
keywords = ["jax", "distribution", "QoE", "test"]
@@ -20,17 +24,26 @@ classifiers = [
2024
"Topic :: Scientific/Engineering :: Information Analysis",
2125
"Topic :: Scientific/Engineering :: Mathematics",
2226
]
27+
requires-python = ">=3.9"
28+
dependencies=["jax>=0.4.6"]
2329

24-
packages=[{include="gsd", from="src"}]
30+
[project.urls]
31+
Homepage = "https://github.com/krzysztofrusek/queuinx"
2532

26-
[tool.poetry.dependencies]
27-
python = "^3.9"
28-
jax = "^0.4.6"
33+
[tool.hatch.version]
34+
path = "src/gsd/__init__.py"
2935

30-
[tool.poetry.group.dev.dependencies]
31-
pytest = "^7.1.3"
32-
jaxlib = "^0.4.6"
36+
[tool.hatch.build]
37+
sources = ["src"]
38+
39+
[tool.hatch.build.targets]
40+
include = [
41+
"/src/*",
42+
]
43+
44+
[tool.hatch.envs.default]
45+
dependencies=["pytest","jaxlib>=0.4.6"]
46+
47+
[tool.hatch.envs.default.scripts]
48+
test = "pytest {args:tests}"
3349

34-
[build-system]
35-
requires = ["poetry-core"]
36-
build-backend = "poetry.core.masonry.api"

src/gsd/__init__.py

Lines changed: 4 additions & 7 deletions
Original file line numberDiff line numberDiff line change
@@ -1,7 +1,4 @@
1-
from gsd.gsd import (
2-
log_prob,
3-
sample,
4-
mean,
5-
variance
6-
)
7-
from gsd.ref_prob import gsd_prob
1+
__version__ = '0.0.3'
2+
3+
from gsd.gsd import (log_prob, sample, mean, variance)
4+
from gsd.ref_prob import gsd_prob

0 commit comments

Comments
 (0)