Skip to content

Commit f75325c

Browse files
authored
python312Packages.x-transformers: 1.44.4 -> 2.1.36 (NixOS#390900)
2 parents 7cea7ba + 2c5cfe6 commit f75325c

File tree

1 file changed

+21
-12
lines changed
  • pkgs/development/python-modules/x-transformers

1 file changed

+21
-12
lines changed

pkgs/development/python-modules/x-transformers/default.nix

Lines changed: 21 additions & 12 deletions
Original file line numberDiff line numberDiff line change
@@ -1,32 +1,41 @@
11
{
22
lib,
33
buildPythonPackage,
4-
fetchPypi,
5-
setuptools,
4+
fetchFromGitHub,
5+
6+
# build-system
7+
hatchling,
8+
9+
# dependencies
10+
einx,
611
einops,
12+
loguru,
13+
packaging,
714
torch,
15+
16+
# tests
817
pytestCheckHook,
918
}:
1019

1120
buildPythonPackage rec {
1221
pname = "x-transformers";
13-
version = "1.44.4";
22+
version = "2.1.36";
1423
pyproject = true;
1524

16-
src = fetchPypi {
17-
pname = "x_transformers";
18-
inherit version;
19-
hash = "sha256-m6Vx/D4rTur4n/DqWEAjD7jK43wEgwhdrQi8+ndsN+E=";
25+
src = fetchFromGitHub {
26+
owner = "lucidrains";
27+
repo = "x-transformers";
28+
tag = version;
29+
hash = "sha256-/L0nzpOG6kbBiujaHsZvb6iakA22BIccvnTvYy1NAa8=";
2030
};
2131

22-
postPatch = ''
23-
sed -i '/setup_requires=\[/,/\],/d' setup.py
24-
'';
25-
26-
build-system = [ setuptools ];
32+
build-system = [ hatchling ];
2733

2834
dependencies = [
35+
einx
2936
einops
37+
loguru
38+
packaging
3039
torch
3140
];
3241

0 commit comments

Comments
 (0)