summaryrefslogtreecommitdiff
path: root/gnu/packages/machine-learning.scm
diff options
context:
space:
mode:
authorRicardo Wurmus <rekado@elephly.net>2021-11-19 17:11:04 +0100
committerRicardo Wurmus <rekado@elephly.net>2021-11-20 12:02:19 +0100
commit1e13f736057046232943ffde31a1b547f29152ea (patch)
treeba5db1768a7cdca13261c18c97e560afac65cacf /gnu/packages/machine-learning.scm
parent5f6558792fe2f190907189d0a8db3c300eb79236 (diff)
gnu: python-pytorch: Use ADD-INSTALLED-PYTHONPATH.
* gnu/packages/machine-learning.scm (python-pytorch)[arguments]: Do not set PYTHONPATH; use add-installed-pythonpath instead.
Diffstat (limited to 'gnu/packages/machine-learning.scm')
-rw-r--r--gnu/packages/machine-learning.scm9
1 files changed, 3 insertions, 6 deletions
diff --git a/gnu/packages/machine-learning.scm b/gnu/packages/machine-learning.scm
index 324d22a12f..ed79044f3b 100644
--- a/gnu/packages/machine-learning.scm
+++ b/gnu/packages/machine-learning.scm
@@ -2811,13 +2811,10 @@ TensorFlow.js, PyTorch, and MediaPipe.")
(lambda* (#:key inputs outputs tests? #:allow-other-keys)
;; Run the test suite following the instructions in
;; 'CONTRIBUTING.md'. XXX: Unfortunately this doesn't
- ;; work, unless you set PYTHONPATH presumably.
+ ;; work, unless you set GUIX_PYTHONPATH presumably.
(when tests?
- (let ((python-site (site-packages inputs outputs)))
- (setenv "PYTHONPATH"
- (string-append python-site ":"
- (getenv "PYTHONPATH")))
- (invoke "python" "test/run_test.py")))))
+ (add-installed-pythonpath inputs outputs)
+ (invoke "python" "test/run_test.py"))))
(add-after 'install 'remove-test-executables
(lambda* (#:key inputs outputs #:allow-other-keys)
;; Remove test executables, but keep other executables