Skip to content
This repository has been archived by the owner on Jan 31, 2023. It is now read-only.

numpy 1.23.x #26

Open
dimpase opened this issue Sep 13, 2022 · 16 comments
Open

numpy 1.23.x #26

dimpase opened this issue Sep 13, 2022 · 16 comments
Labels

Comments

@dimpase
Copy link
Member

dimpase commented Sep 13, 2022

Issue created by migration from Trac.

Original creator: @mkoeppe

Original creation time: 2022-07-03 19:41:33

CC: tmonteil

(split out from #34081)

https://numpy.org/doc/stable/release/1.23.0-notes.html# (released)

The upgrade looks harmless.

1.23.x requires GCC >= 6.5. (This has been documented in numpy/numpy#22155 - to be included in 1.23.3.)

We set #34266 as a dependency, which increases our requirement from GCC >= 6.3 to GCC >= 8)

Previous update:

#32423 Update numpy to 1.22.x, scipy 1.8.x, networkx 2.8.x

(changed by @mkoeppe at 2022-08-19 17:21:53)

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by @mkoeppe created at 2022-07-03 19:44:39

Last 10 new commits:

e1998da Merge #32423
507fc2e build/pkgs/numpy: Update to 1.23.0
58d62f4 build/bin/write-dockerfile.sh: ADD src/VERSION.txt
99f3617 Merge #34017
3fab415 build/pkgs/numpy: Switch to using .tar.gz
443b3d3 build/pkgs/numpy/spkg-install.in: Fix 32bit build on x86_64
9cd5ea6 Merge #34017
ee79c2e build/pkgs/numpy/spkg-install.in: Fix 32bit build on x86_64 (fixup)
2534f5a build/pkgs/numpy/patches/21891.patch: New
d87212c Merge #32423

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by @mkoeppe created at 2022-07-03 19:44:39

Changing status from new to needs_review.

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by @mkoeppe created at 2022-07-04 20:14:00

On debian-stretch-standard (https://github.com/mkoeppe/sage/runs/7184259105?check_suite_focus=true):

In file included from numpy/core/src/common/simd/avx512/avx512.h:75:0,
                   from numpy/core/src/common/simd/simd.h:50,
                   from /sage/local/var/lib/sage/venv-python3.10.3/var/tmp/sage/build/numpy-1.23.0/src/numpy/core/src/npysort/x86-qsort.dispatch.cpp:17,
                   from build/src.linux-x86_64-3.10/numpy/core/src/npysort/x86-qsort.dispatch.avx512_skx.cpp:21:
  numpy/core/src/common/simd/avx512/arithmetic.h: In function 'npy_uint32 npyv_reducemax_u32(npyv_u32)':
  numpy/core/src/common/simd/avx512/arithmetic.h:387:89: error: invalid conversion from 'int' to '_MM_PERM_ENUM' [-fpermissive]
           npyv_u32 a3 = _mm512_max_epu32(a2, _mm512_shuffle_epi32(a2, (1<<6 | 0<<4 | 3<<2 | 2)));
                                                                       ~~~~~~~~~~~~~~~~~~~~^~~~
...
 In file included from build/src.linux-x86_64-3.10/numpy/core/src/npysort/x86-qsort.dispatch.avx512_skx.cpp:21:0:
  /sage/local/var/lib/sage/venv-python3.10.3/var/tmp/sage/build/numpy-1.23.0/src/numpy/core/src/npysort/x86-qsort.dispatch.cpp: In function 'npy_int partition_vec(type_t*, npy_intp, npy_intp, zmm_t, zmm_t, zmm_t*, zmm_t*)':
  /sage/local/var/lib/sage/venv-python3.10.3/var/tmp/sage/build/numpy-1.23.0/src/numpy/core/src/npysort/x86-qsort.dispatch.cpp:654:64: error: there are no arguments to '_knot_mask16' that depend on a template parameter, so a declaration of '_knot_mask16' must be available [-fpermissive]
       vtype::mask_compressstoreu(arr + left, _knot_mask16(gt_mask), curr_vec);
                                                                  ^

(regression from numpy 1.22.x). Reported at numpy/numpy#21920

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by @mkoeppe created at 2022-07-06 01:55:00

Changing status from needs_review to needs_work.

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by git created at 2022-07-09 02:33:50

Branch pushed to git repo; I updated commit sha1. New commits:

4cce3ef Merge tag '9.7.beta4' into t/34110/numpy_1_23
8f5860a build/pkgs/numpy: Update to 1.23.1

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by @mkoeppe created at 2022-07-27 16:20:29

ubuntu-trusty-toolchain-gcc_9 (https://github.com/mkoeppe/sage/runs/7532140899?check_suite_focus=true) and other ubuntu releases

sage -t --random-seed=291926986539572225544641036716487640141 src/sage/matrix/matrix_double_dense.pyx
**********************************************************************
File "src/sage/matrix/matrix_double_dense.pyx", line 3642, in sage.matrix.matrix_double_dense.Matrix_double_dense.exp
Failed example:
    A.exp()  # tol 1e-15
Expected:
    [51.968956198705044  74.73656456700327]
    [112.10484685050491 164.07380304920997]
Got:
    [ 51.96895619870499  74.73656456700321]
    [112.10484685050481 164.07380304920983]
Tolerance exceeded in 1 of 4:
    51.968956198705044 vs 51.96895619870499, tolerance 2e-15 > 1e-15
**********************************************************************
File "src/sage/matrix/matrix_double_dense.pyx", line 3655, in sage.matrix.matrix_double_dense.Matrix_double_dense.exp
Failed example:
    A.exp()   # tol 1e-15
Expected:
    [51.968956198705044  74.73656456700327]
    [112.10484685050491 164.07380304920997]
Got:
    [ 51.96895619870499  74.73656456700321]
    [112.10484685050481 164.07380304920983]
Tolerance exceeded in 1 of 4:
    51.968956198705044 vs 51.96895619870499, tolerance 2e-15 > 1e-15
**********************************************************************

sage -t --random-seed=291926986539572225544641036716487640141 src/sage/symbolic/constants_c_impl.pxi
**********************************************************************
File "src/sage/symbolic/constants_c_impl.pxi", line 164, in sage.symbolic.constants_c_impl.E.__pow__
Failed example:
    e^A  # rel tol 1e-15
Expected:
    [51.968956198705044  74.73656456700327]
    [112.10484685050491 164.07380304920997]
Got:
    [ 51.96895619870499  74.73656456700321]
    [112.10484685050481 164.07380304920983]
Tolerance exceeded in 1 of 4:
    51.968956198705044 vs 51.96895619870499, tolerance 2e-15 > 1e-15

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by git created at 2022-07-29 00:36:03

Branch pushed to git repo; I updated commit sha1. New commits:

7aec01a src/sage/matrix/matrix_double_dense.pyx, src/sage/symbolic/constants_c_impl.pxi: Increase tolerances for RDF matrix exp

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by git created at 2022-07-29 21:17:25

Branch pushed to git repo; I updated commit sha1. This was a forced push. New commits:

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by @mkoeppe created at 2022-08-09 20:52:11

Replying to [comment:4 mkoeppe]:

On debian-stretch-standard

This platform is dropped in #34266, I've set it as a dependency

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by @mkoeppe created at 2022-08-09 20:52:11

Changing status from needs_work to needs_review.

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by jhpalmieri created at 2022-08-25 23:21:51

On OS X + various homebrew packages, I am getting two doctest failures:

File "src/sage/modules/vector_double_dense.pyx", line 405, in sage.modules.vector_double_dense.Vector_double_dense.norm
Failed example:
    v.norm(p=6)
Expected:
    8.744039097...
Got:
    doctest:warning
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/bin/sage-runtests", line 154, in <module>
        err = DC.run()
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/control.py", line 1384, in run
        self.run_doctests()
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/control.py", line 1059, in run_doctests
        self.dispatcher.dispatch()
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 2021, in dispatch
        self.parallel_dispatch()
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 1916, in parallel_dispatch
        w.start()  # This might take some time
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 2190, in start
        super().start()
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/process.py", line 121, in start
        self._popen = self._Popen(self)
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/context.py", line 224, in _Popen
        return _default_context.get_context().Process._Popen(process_obj)
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/context.py", line 277, in _Popen
        return Popen(process_obj)
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/popen_fork.py", line 19, in __init__
        self._launch(process_obj)
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/popen_fork.py", line 71, in _launch
        code = process_obj._bootstrap(parent_sentinel=child_r)
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/process.py", line 315, in _bootstrap
        self.run()
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 2162, in run
        task(self.options, self.outtmpfile, msgpipe, self.result_queue)
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 2492, in __call__
        doctests, extras = self._run(runner, options, results)
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 2544, in _run
        result = runner.run(test)
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 866, in run
        return self._run(test, compileflags, out)
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 695, in _run
        self.compile_and_execute(example, compiler, test.globs)
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 1093, in compile_and_execute
        exec(compiled, globs)
      File "<doctest sage.modules.vector_double_dense.Vector_double_dense.norm[3]>", line 1, in <module>
        v.norm(p=Integer(6))
      File "<__array_function__ internals>", line 180, in norm
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/local/var/lib/sage/venv-python3.9/lib/python3.9/site-packages/numpy/linalg/linalg.py", line 2566, in norm
        ret **= reciprocal(ord, dtype=ret.dtype)
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/warnings.py", line 109, in _showwarnmsg
        sw(msg.message, msg.category, msg.filename, msg.lineno,
    :
    RuntimeWarning: invalid value encountered in reciprocal
    8.744039097709175
**********************************************************************
1 item had failures:
   1 of  24 in sage.modules.vector_double_dense.Vector_double_dense.norm
    [103 tests, 1 failure, 1.05 s]
sage -t --random-seed=328052423492298536457904078933829346088 src/sage/modules/free_module_element.pyx
**********************************************************************
File "src/sage/modules/free_module_element.pyx", line 1677, in sage.modules.free_module_element.FreeModuleElement.norm
Failed example:
    v.norm(5)
Expected:
    3.077384885394063
Got:
    doctest:warning
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/bin/sage-runtests", line 154, in <module>
        err = DC.run()
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/control.py", line 1384, in run
        self.run_doctests()
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/control.py", line 1059, in run_doctests
        self.dispatcher.dispatch()
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 2021, in dispatch
        self.parallel_dispatch()
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 1916, in parallel_dispatch
        w.start()  # This might take some time
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 2190, in start
        super().start()
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/process.py", line 121, in start
        self._popen = self._Popen(self)
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/context.py", line 224, in _Popen
        return _default_context.get_context().Process._Popen(process_obj)
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/context.py", line 277, in _Popen
        return Popen(process_obj)
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/popen_fork.py", line 19, in __init__
        self._launch(process_obj)
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/popen_fork.py", line 71, in _launch
        code = process_obj._bootstrap(parent_sentinel=child_r)
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/multiprocessing/process.py", line 315, in _bootstrap
        self.run()
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 2162, in run
        task(self.options, self.outtmpfile, msgpipe, self.result_queue)
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 2492, in __call__
        doctests, extras = self._run(runner, options, results)
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 2544, in _run
        result = runner.run(test)
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 866, in run
        return self._run(test, compileflags, out)
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 695, in _run
        self.compile_and_execute(example, compiler, test.globs)
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/src/sage/doctest/forker.py", line 1093, in compile_and_execute
        exec(compiled, globs)
      File "<doctest sage.modules.free_module_element.FreeModuleElement.norm[7]>", line 1, in <module>
        v.norm(Integer(5))
      File "<__array_function__ internals>", line 180, in norm
      File "/Users/palmieri/Desktop/Sage/sage_builds/TESTING/sage-9.7.beta8/local/var/lib/sage/venv-python3.9/lib/python3.9/site-packages/numpy/linalg/linalg.py", line 2566, in norm
        ret **= reciprocal(ord, dtype=ret.dtype)
      File "/usr/local/Cellar/python`@`3.9/3.9.13_1/Frameworks/Python.framework/Versions/3.9/lib/python3.9/warnings.py", line 109, in _showwarnmsg
        sw(msg.message, msg.category, msg.filename, msg.lineno,
    :
    RuntimeWarning: invalid value encountered in reciprocal
    3.077384885394063
**********************************************************************
1 item had failures:
   1 of  24 in sage.modules.free_module_element.FreeModuleElement.norm
    [1079 tests, 1 failure, 9.35 s]
----------------------------------------------------------------------
sage -t --random-seed=328052423492298536457904078933829346088 src/sage/modules/vector_double_dense.pyx  # 1 doctest failed
sage -t --random-seed=328052423492298536457904078933829346088 src/sage/modules/free_module_element.pyx  # 1 doctest failed

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by git created at 2022-08-26 00:45:45

Branch pushed to git repo; I updated commit sha1. This was a forced push. New commits:

fdb7764 build/pkgs/numpy: Update to 1.23.0
09066c8 build/pkgs/numpy: Switch to using .tar.gz
5b0f244 build/pkgs/numpy: Update to 1.23.1
d4ff77d build/pkgs/numpy: Update to 1.23.2

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by @mkoeppe created at 2022-08-26 00:46:09

Haven't built this in a while, but there's already 1.23.2

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by @mkoeppe created at 2022-08-26 04:32:22

Just built it on my Mac (with openblas from current homebrew), and I see these failures too.

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by git created at 2022-09-13 02:00:29

Branch pushed to git repo; I updated commit sha1. New commits:

ecda67e Merge tag '9.7.rc1' into t/34110/numpy_1_23
bccc17d build/pkgs/numpy: Update to 1.23.3

@dimpase
Copy link
Member Author

dimpase commented Sep 13, 2022

Comment by gh-dimpase created at 2022-09-13 08:59:53

test, please ignore

Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
Projects
None yet
Development

No branches or pull requests

1 participant