[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
Skip to the cpython primitive definition of the function/operation.
From: |
Hongyi Zhao |
Subject: |
Skip to the cpython primitive definition of the function/operation. |
Date: |
Tue, 12 Oct 2021 19:53:29 +0800 |
See the following testing in ipython:
$ ipython
In [1]: import numpy as np
In [2]: a=np.array([1] ,dtype=bool)
In [3]: a
Out[3]: array([ True])
In [4]: ~a
Out[4]: array([False])
In [5]: np.invert(a)
Out[5]: array([False])
In [6]:
So, I want to confirm the equivalence of the np.invert and ~ operators
by inspecting the corresponding cpython primitive definition. Is there
a way for me to skip to them from the python script opened in Emacs?
Regards
--
Assoc. Prof. Hongyi Zhao <hongyi.zhao@gmail.com>
Theory and Simulation of Materials
Hebei Vocational University of Technology and Engineering
No. 473, Quannan West Street, Xindu District, Xingtai, Hebei province
- Skip to the cpython primitive definition of the function/operation.,
Hongyi Zhao <=