Skip to content

Commit a60f0ad

Browse files
authored
build: pixi environment setup (#780)
1 parent 0f7be70 commit a60f0ad

File tree

5 files changed

+73
-1
lines changed

5 files changed

+73
-1
lines changed

.gitattributes

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -1 +1,3 @@
11
sparse/_version.py export-subst
2+
# GitHub syntax highlighting
3+
pixi.lock linguist-language=YAML linguist-generated=true

.gitignore

Lines changed: 4 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -82,3 +82,7 @@ results/
8282

8383
# Notebooks converted to scripts.
8484
docs/examples_ipynb/
85+
86+
# Pixi envs
87+
.pixi/
88+
pixi.lock

ci/environment.yml

Lines changed: 1 addition & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -4,6 +4,7 @@ channels:
44
- nodefaults
55
dependencies:
66
- python
7+
- pip
78
- numpy
89
- numba
910
- scipy

pixi.toml

Lines changed: 66 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,66 @@
1+
[project]
2+
authors = ["Hameer Abbasi <[email protected]>"]
3+
channels = ["conda-forge"]
4+
name = "sparse"
5+
platforms = ["osx-arm64", "osx-64", "linux-64", "win-64"]
6+
7+
[pypi-dependencies]
8+
sparse = { path = ".", editable = true }
9+
10+
[dependencies]
11+
python = ">=3.10"
12+
numpy = ">=1.17"
13+
numba = ">=0.49"
14+
15+
[feature.extras.dependencies]
16+
dask = ">=2024"
17+
scipy = ">=0.19"
18+
scikit-learn = "*"
19+
20+
[feature.docs.pypi-dependencies]
21+
mkdocs-material = "*"
22+
mkdocstrings = { version = "*", extras = ["python"] }
23+
mkdocs-gen-files = "*"
24+
mkdocs-literate-nav = "*"
25+
mkdocs-section-index = "*"
26+
mkdocs-jupyter = "*"
27+
28+
[feature.tests.tasks]
29+
test = "pytest --pyargs sparse -n auto"
30+
test-mlir = { cmd = "pytest --pyargs sparse/mlir_backend -vvv", env = { SPARSE_BACKEND = "MLIR" } }
31+
test-finch = { cmd = "pytest --pyargs sparse/tests -n auto", env = { SPARSE_BACKEND = "Finch" }, depends-on = ["precompile"] }
32+
33+
[feature.tests.dependencies]
34+
pytest = ">=3.5"
35+
pytest-cov = "*"
36+
pytest-xdist = "*"
37+
pre-commit = "*"
38+
pytest-codspeed = "*"
39+
40+
[feature.notebooks.dependencies]
41+
nbmake = "*"
42+
matplotlib = "*"
43+
44+
[feature.matrepr.dependencies]
45+
matrepr = "*"
46+
47+
[feature.finch.tasks]
48+
precompile = "python -c 'import finch'"
49+
50+
[feature.finch.pypi-dependencies]
51+
scipy = ">=0.19"
52+
finch-tensor = ">=0.1.31"
53+
54+
[feature.mlir]
55+
channel-priority = "disabled"
56+
channels = ["conda-forge", "conda-forge/label/llvm_rc"]
57+
58+
[feature.mlir.dependencies]
59+
scipy = ">=0.19"
60+
mlir-python-bindings = "19.*"
61+
62+
[environments]
63+
tests = ["tests", "extras"]
64+
docs = ["docs", "extras"]
65+
mlir-dev = ["tests", "mlir"]
66+
finch-dev = ["tests", "finch"]

pyproject.toml

Lines changed: 0 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -29,7 +29,6 @@ classifiers = [
2929
[project.optional-dependencies]
3030
docs = [
3131
"mkdocs-material",
32-
"mkdocstrings",
3332
"mkdocstrings[python]",
3433
"mkdocs-gen-files",
3534
"mkdocs-literate-nav",

0 commit comments

Comments
 (0)