Skip to content

Deal with the issue of 'No module named numpy' in the workflow#31

Closed
stever178 wants to merge 4 commits into
InfiniTensor:masterfrom
stever178:master
Closed

Deal with the issue of 'No module named numpy' in the workflow#31
stever178 wants to merge 4 commits into
InfiniTensor:masterfrom
stever178:master

Conversation

@stever178
Copy link
Copy Markdown
Contributor

@stever178 stever178 commented Jun 14, 2025

pytest output:

=============================== test session starts ================================
platform linux -- Python 3.12.11, pytest-8.4.0, pluggy-1.6.0
rootdir: /home/lsj/projects/ntops
configfile: pyproject.toml
plugins: cov-6.2.1
collected 238 items

tests/test_abs.py ........                                                   [  3%]
tests/test_add.py ........                                                   [  6%]
tests/test_addmm.py ..                                                       [  7%]
tests/test_bitwise_and.py ................                                   [ 14%]
tests/test_bitwise_not.py ................                                   [ 21%]
tests/test_bitwise_or.py ................                                    [ 27%]
tests/test_bmm.py ..                                                         [ 28%]
tests/test_clamp.py ........                                                 [ 31%]
tests/test_cos.py ........                                                   [ 35%]
tests/test_div.py ........                                                   [ 38%]
tests/test_eq.py ........                                                    [ 42%]
tests/test_exp.py ........                                                   [ 45%]
tests/test_ge.py ........                                                    [ 48%]
tests/test_gelu.py ........                                                  [ 52%]
tests/test_gt.py ........                                                    [ 55%]
tests/test_isinf.py ........                                                 [ 58%]
tests/test_isnan.py ........                                                 [ 62%]
tests/test_le.py ........                                                    [ 65%]
tests/test_lt.py ........                                                    [ 68%]
tests/test_mm.py ..                                                          [ 69%]
tests/test_mul.py ........                                                   [ 73%]
tests/test_ne.py ........                                                    [ 76%]
tests/test_neg.py ........                                                   [ 79%]
tests/test_relu.py ........                                                  [ 83%]
tests/test_rsqrt.py ........                                                 [ 86%]
tests/test_sigmoid.py ........                                               [ 89%]
tests/test_sin.py ........                                                   [ 93%]
tests/test_softmax.py ........                                               [ 96%]
tests/test_tanh.py ........                                                  [100%]

========================= 238 passed in 178.24s (0:02:58) ==========================

@stever178 stever178 marked this pull request as ready for review June 14, 2025 17:03
@voltjia
Copy link
Copy Markdown
Collaborator

voltjia commented Jun 17, 2025

什么时候会遇到这个问题?

@stever178
Copy link
Copy Markdown
Contributor Author

回溯至 #1pytest 工作流的 Test with pytest ,就已经出现UserWarning: Failed to initialize NumPy: No module named 'numpy' .

@voltjia
Copy link
Copy Markdown
Collaborator

voltjia commented Jun 19, 2025

原来是这个 warning,但是目前还没观察到实际影响,就是 workflow 直接失败,或者影响实际运行。我们先观察一下,如果之后有实际影响我们就进行合入,依赖尽量最小化。

@voltjia
Copy link
Copy Markdown
Collaborator

voltjia commented Oct 13, 2025

由于 ntops 的依赖 ninetoothed 已经numpy 引入为了依赖,所以不再需要在 ntops 中引入。

@voltjia voltjia closed this Oct 13, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

2 participants