BUG: Fix np.einsum errors on Power9 Linux and z/Linux.
See original GitHub issueAn array index fails on Power9 Linux and z/Linux.
PR follows this issue, but not sure that x86 will be happy with the proposed fix
Reproducing code example:
(qdev_venv) [linux1@jwoehr1 Qiskit]$ python
Python 3.6.8 (default, Jun 11 2019, 14:52:20)
[GCC 4.8.5 20150623 (Red Hat 4.8.5-39)] on linux
Type "help", "copyright", "credits" or "license" for more information.
>>> import numpy as np
>>> tensor = np.random.rand(10, 10, 10, 10)
>>> np.einsum('ijij->', tensor)
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "<__array_function__ internals>", line 6, in einsum
File "/home/linux1/work/Qiskit/qdev_venv/lib64/python3.6/site-packages/numpy/core/einsumfunc.py", line 1356, in einsum
return c_einsum(*operands, **kwargs)
ValueError: dimensions in operand 0 for collapsing index 'þ' don't match (-1419377904 != 10)
>>>
Error message:
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "<__array_function__ internals>", line 6, in einsum
File "/home/linux1/work/Qiskit/qdev_venv/lib64/python3.6/site-packages/numpy/core/einsumfunc.py", line 1356, in einsum
return c_einsum(*operands, **kwargs)
ValueError: dimensions in operand 0 for collapsing index 'þ' don't match (-1419377904 != 10)
Numpy/Python version information:
1.17.2 3.6.8 (default, Jun 11 2019, 14:52:20) [GCC 4.8.5 20150623 (Red Hat 4.8.5-39)]
Issue Analytics
- State:
- Created 4 years ago
- Comments:25 (25 by maintainers)
Top Results From Across the Web
EEH errors on IBM POWER9 systems that are enabled with ...
Abstract. On IBM POWER9 systems that are enabled with Virtual Persistent Memory, Enhanced Error Handling (EEH) errors might be observed. Content.
Read more >Bug in tf.einsum - Returns different values from np ... - GitHub
EDIT: The same type of error persists but with slightly different parameters. I am now certain that this is a Tensorflow issue.
Read more >onnx-mlir - GithubHelp
ONNX-MLIR runs natively on Linux, OSX, and Windows. ... What can i do to fix the infer shape warnings and the key error....
Read more >
Top Related Medium Post
No results found
Top Related StackOverflow Question
No results found
Troubleshoot Live Code
Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free
Top Related Reddit Thread
No results found
Top Related Hackernoon Post
No results found
Top Related Tweet
No results found
Top Related Dev.to Post
No results found
Top Related Hashnode Post
No results found
I know that it would run on machines with unsigned characters after we fixed things before, so possibly this problem is fairly newly introduced. See original at #2398. I suspect #11095 might be related and it looks like @mattip has been looking in some of the same places.
Thank you for promising suggestion. I will work on it tomorrow.